summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMatthew Waters <matthew@centricular.com>2020-07-24 17:31:36 +1000
committerMatthew Waters <matthew@centricular.com>2020-08-07 20:22:41 +1000
commitd1667da0c3f1865a50c3d0c99561fcd57d891bd7 (patch)
tree27649c820ecd09c06b40f9f085d5e3fbd9bdb441
parentfbbacdb856a1ace6917cd5a35c0d6a06b25ad06b (diff)
build: update for gl pkg-config file split
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1462>
-rw-r--r--meson.build26
-rw-r--r--sys/applemedia/meson.build2
-rw-r--r--sys/nvcodec/meson.build2
3 files changed, 24 insertions, 6 deletions
diff --git a/meson.build b/meson.build
index 4a7468442..fdbae8556 100644
--- a/meson.build
+++ b/meson.build
@@ -300,6 +300,11 @@ gstcheck_dep = dependency('gstreamer-check-1.0', version : gst_req,
# GStreamer OpenGL
gstgl_dep = dependency('gstreamer-gl-1.0', version : gst_req,
fallback : ['gst-plugins-base', 'gstgl_dep'], required: get_option('gl'))
+gstglproto_dep = dependency('gstreamer-gl-prototypes-1.0', version : gst_req,
+ fallback : ['gst-plugins-base', 'gstglproto_dep'], required: get_option('gl'))
+gstglx11_dep = dependency('', required : false)
+gstglwayland_dep = dependency('', required : false)
+gstglegl_dep = dependency('', required : false)
if gstgl_dep.found()
if gstgl_dep.type_name() == 'pkgconfig'
@@ -327,11 +332,24 @@ if gstgl_dep.found()
foreach api : ['gl', 'gles2']
set_variable('gst_gl_have_api_@0@'.format(api), gst_gl_apis.contains(api))
- # temporary backwards compat for older meson-generated .pc file with 'opengl' instead of 'gl'
- if gst_gl_apis.contains('opengl')
- gst_gl_have_api_gl = true
- endif
endforeach
+
+ # Behind specific checks because meson fails at optional dependencies with a
+ # fallback to the same subproject. On the first failure, meson will never
+ # check the system again even if the fallback never existed.
+ # Last checked with meson 0.54.3
+ if gst_gl_have_window_x11
+ gstglx11_dep = dependency('gstreamer-gl-x11-1.0', version : gst_req,
+ fallback : ['gst-plugins-base', 'gstglx11_dep'], required: true)
+ endif
+ if gst_gl_have_window_wayland
+ gstglwayland_dep = dependency('gstreamer-gl-wayland-1.0', version : gst_req,
+ fallback : ['gst-plugins-base', 'gstglwayland_dep'], required: true)
+ endif
+ if gst_gl_have_platform_egl
+ gstglegl_dep = dependency('gstreamer-gl-egl-1.0', version : gst_req,
+ fallback : ['gst-plugins-base', 'gstglegl_dep'], required: true)
+ endif
endif
libm = cc.find_library('m', required : false)
diff --git a/sys/applemedia/meson.build b/sys/applemedia/meson.build
index 23290d5fc..b77c37be0 100644
--- a/sys/applemedia/meson.build
+++ b/sys/applemedia/meson.build
@@ -108,7 +108,7 @@ if applemedia_found_deps
objcpp_args : gst_plugins_bad_args + applemedia_args + applemedia_objc_args,
link_args : noseh_link_args,
include_directories : [configinc, libsinc],
- dependencies : [gstvideo_dep, gstaudio_dep, gstpbutils_dep, gst_dep, gstbase_dep, gstgl_dep] + applemedia_frameworks,
+ dependencies : [gstvideo_dep, gstaudio_dep, gstpbutils_dep, gst_dep, gstbase_dep, gstgl_dep, gstglproto_dep] + applemedia_frameworks,
install : true,
install_dir : plugins_install_dir,
)
diff --git a/sys/nvcodec/meson.build b/sys/nvcodec/meson.build
index bc153b360..d77cc6d29 100644
--- a/sys/nvcodec/meson.build
+++ b/sys/nvcodec/meson.build
@@ -29,7 +29,7 @@ gstnvcodec = library('gstnvcodec',
nvcodec_sources,
c_args : gst_plugins_bad_args + extra_c_args,
include_directories : plugin_incdirs,
- dependencies : [gstbase_dep, gstvideo_dep, gstpbutils_dep, gstgl_dep, gmodule_dep, gstcodecs_dep],
+ dependencies : [gstbase_dep, gstvideo_dep, gstpbutils_dep, gstgl_dep, gstglproto_dep, gmodule_dep, gstcodecs_dep],
install : true,
install_dir : plugins_install_dir,
)