From 6c1dc1b129dcc1353899be4091f463907aa91eeb Mon Sep 17 00:00:00 2001 From: Philippe Normand Date: Thu, 27 Dec 2018 14:55:28 +0100 Subject: [PATCH] examples/gl/gtk: Fix build on macOS The gdkquartz.h include pulls into Apple Obj-C frameworks so the compiler needs to handle the gstgtkhelper library as such. Fixes #518 --- tests/examples/gl/gtk/meson.build | 8 +++++++- tests/examples/gl/meson.build | 4 ---- 2 files changed, 7 insertions(+), 5 deletions(-) diff --git a/tests/examples/gl/gtk/meson.build b/tests/examples/gl/gtk/meson.build index d019136..22db40a 100644 --- a/tests/examples/gl/gtk/meson.build +++ b/tests/examples/gl/gtk/meson.build @@ -3,9 +3,15 @@ if cc.has_argument ('-Wno-parentheses') extra_args += '-Wno-parentheses' endif +if host_system == 'darwin' + extra_c_args = ['-xobjective-c'] +else + extra_c_args = [] +endif + gstgtkhelper = static_library ('gstgtkhelper', ['gstgtk.c'], - c_args : gst_plugins_base_args, + c_args : gst_plugins_base_args + extra_c_args, include_directories : [configinc, libsinc], dependencies : [gst_base_dep, video_dep, gtk_dep], install : false) diff --git a/tests/examples/gl/meson.build b/tests/examples/gl/meson.build index d092d46..086758f 100644 --- a/tests/examples/gl/meson.build +++ b/tests/examples/gl/meson.build @@ -1,9 +1,5 @@ subdir('cocoa') subdir('generic') -# FIXME: gtk is temporarily disabled. -# See. https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/issues/518 -if host_system != 'darwin' subdir('gtk', if_found : gtk_dep) -endif # FIXME: subdir('qt') subdir('sdl') -- 2.7.4