mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-12-23 08:46:40 +00:00
meson: fix build with GstGL from gst-plugins-base as subproject
- use right fallback variable - get platform/winsys variables from subproject instead of pkg-config With contributions from Thibault Saunier.
This commit is contained in:
parent
cd2d5c140d
commit
b7bfcc32d1
1 changed files with 22 additions and 11 deletions
21
meson.build
21
meson.build
|
@ -325,20 +325,31 @@ endif
|
||||||
|
|
||||||
# GStreamer OpenGL
|
# GStreamer OpenGL
|
||||||
gstgl_dep = dependency('gstreamer-gl-1.0', version : gst_req,
|
gstgl_dep = dependency('gstreamer-gl-1.0', version : gst_req,
|
||||||
fallback : ['gst-plugins-base', 'gl_dep'], required: false)
|
fallback : ['gst-plugins-base', 'gstgl_dep'], required: false)
|
||||||
|
|
||||||
build_gstgl = gstgl_dep.found() # FIXME: add option?
|
build_gstgl = gstgl_dep.found() # FIXME: add option?
|
||||||
|
|
||||||
|
if build_gstgl
|
||||||
|
if gstgl_dep.type_name() == 'pkg'
|
||||||
gst_gl_winsys = gstgl_dep.get_pkgconfig_variable('gl_winsys')
|
gst_gl_winsys = gstgl_dep.get_pkgconfig_variable('gl_winsys')
|
||||||
|
gst_gl_platforms = gstgl_dep.get_pkgconfig_variable('gl_platforms')
|
||||||
|
else
|
||||||
|
gstbase = subproject('gst-plugins-base')
|
||||||
|
gst_gl_winsys = ' '.join(gstbase.get_variable('enabled_gl_winsys'))
|
||||||
|
gst_gl_platforms = ' '.join(gstbase.get_variable('enabled_gl_platforms'))
|
||||||
|
endif
|
||||||
|
|
||||||
message('GStreamer OpenGL window systems: ' + gst_gl_winsys)
|
message('GStreamer OpenGL window systems: ' + gst_gl_winsys)
|
||||||
foreach ws : ['x11', 'wayland', 'android', 'cocoa', 'eagl']
|
message('GStreamer OpenGL platforms: ' + gst_gl_platforms)
|
||||||
|
|
||||||
|
foreach ws : ['x11', 'wayland', 'android', 'cocoa', 'eagl', 'win32', 'dispmanx', 'viv_fb']
|
||||||
set_variable('gst_gl_have_window_@0@'.format(ws), gst_gl_winsys.contains(ws))
|
set_variable('gst_gl_have_window_@0@'.format(ws), gst_gl_winsys.contains(ws))
|
||||||
endforeach
|
endforeach
|
||||||
|
|
||||||
gst_gl_platforms = gstgl_dep.get_pkgconfig_variable('gl_platforms')
|
foreach p : ['glx', 'egl', 'cgl', 'eagl', 'wgl']
|
||||||
message('GStreamer OpenGL platforms: ' + gst_gl_platforms)
|
|
||||||
foreach p : ['glx', 'egl', 'cgl', 'eagl']
|
|
||||||
set_variable('gst_gl_have_platform_@0@'.format(p), gst_gl_platforms.contains(p))
|
set_variable('gst_gl_have_platform_@0@'.format(p), gst_gl_platforms.contains(p))
|
||||||
endforeach
|
endforeach
|
||||||
|
endif
|
||||||
|
|
||||||
libm = cc.find_library('m', required : false)
|
libm = cc.find_library('m', required : false)
|
||||||
glib_dep = dependency('glib-2.0', version : glib_req,
|
glib_dep = dependency('glib-2.0', version : glib_req,
|
||||||
|
|
Loading…
Reference in a new issue