Skip to content

Commit

Permalink
gstgl: Fix build when Meson >= 0.58.0rc1
Browse files Browse the repository at this point in the history
"implicit_include_directories: false" now also means that current build
directory is not added to include paths by default any more. We have to
add it manually because we have some custom_target() that generate
headers in current build directory.

See mesonbuild/meson#8700.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/1125>
  • Loading branch information
xclaesse authored and GStreamer Marge Bot committed Apr 27, 2021
1 parent b14c2e6 commit 4ef5c91
Showing 1 changed file with 12 additions and 3 deletions.
15 changes: 12 additions & 3 deletions gst-libs/gst/gl/meson.build
Expand Up @@ -1004,11 +1004,20 @@ if build_gstgl
command : [mkenums, glib_mkenums, '@OUTPUT@', '@INPUT@'])
gen_sources = [gl_enumtypes_h]

common_args = gst_plugins_base_args + gl_cpp_args + ['-DBUILDING_GST_GL']

# We have custom_target() that generate headers in the current build dir,
# but with implicit_include_directories: false, meson >= 0.58.0 won't include
# it by default. We cannot use include_directories('.') here because it would
# also include current source dir which is what we want to avoid because
# case-insensitive FS would include gst-libs/gl/egl/egl.h as EGL/egl.h.
common_args += '-I@0@'.format(meson.current_build_dir())

gstgl = library('gstgl-' + api_version,
gl_sources, gl_egl_sources, gl_x11_sources, gl_wayland_sources, gl_priv_sources, gl_enumtypes_c, gl_enumtypes_h,
c_args : gst_plugins_base_args + gl_cpp_args + ['-DBUILDING_GST_GL'],
cpp_args : gst_plugins_base_args + gl_cpp_args + ['-DBUILDING_GST_GL'],
objc_args : gst_plugins_base_args + gl_cpp_args + gl_objc_args + ['-DBUILDING_GST_GL'],
c_args : common_args,
cpp_args : common_args,
objc_args : common_args + gl_objc_args,
include_directories : [configinc, libsinc, gl_includes],
version : libversion,
soversion : soversion,
Expand Down

0 comments on commit 4ef5c91

Please sign in to comment.