From 48e7952aab2e5be8c0dbff683352b09d0b32c96b Mon Sep 17 00:00:00 2001 From: Maintainers of GStreamer packages Date: Sat, 18 Jan 2025 10:57:51 +0000 Subject: [PATCH] fix-build-without-wayland commit 5cc93d5002f1f3f22738eddc28724191e28cbfb3 Author: Samuel Thibault Date: Mon Dec 30 21:59:03 2024 +0100 meson: Fix build with gtk3 but not wayland Gbp-Pq: Name 0001-fix-build-without-wayland.patch --- ext/gtk/meson.build | 6 ++++-- tests/examples/gtk/meson.build | 2 +- tests/examples/meson.build | 4 +++- 3 files changed, 8 insertions(+), 4 deletions(-) diff --git a/ext/gtk/meson.build b/ext/gtk/meson.build index 0c94a71..ad98880 100644 --- a/ext/gtk/meson.build +++ b/ext/gtk/meson.build @@ -7,9 +7,11 @@ gtkwayland_sources = [ ] gtk_dep = dependency('gtk+-3.0', required : get_option('gtk3')) -gtk_wayland_dep = dependency('gtk+-wayland-3.0', required : get_option('gtk3')) +if use_wayland + gtk_wayland_dep = dependency('gtk+-wayland-3.0', required : get_option('gtk3')) +endif -if gtk_dep.found() and gtk_wayland_dep.found() and use_wayland +if use_wayland and gtk_dep.found() and gtk_wayland_dep.found() and use_wayland gstgtkwayland = library('gstgtkwayland', gtkwayland_sources, c_args : gst_plugins_bad_args + ['-DGST_USE_UNSTABLE_API'], diff --git a/tests/examples/gtk/meson.build b/tests/examples/gtk/meson.build index 1ed0dee..97a29d5 100644 --- a/tests/examples/gtk/meson.build +++ b/tests/examples/gtk/meson.build @@ -1,4 +1,4 @@ -if gtk_dep.found() and gtk_wayland_dep.found() and use_wayland +if use_wayland and gtk_dep.found() and gtk_wayland_dep.found() executable('gtkwaylandsink', 'gtkwaylandsink.c', extra_files: ['window.ui'], diff --git a/tests/examples/meson.build b/tests/examples/meson.build index aec685b..ba82a1e 100644 --- a/tests/examples/meson.build +++ b/tests/examples/meson.build @@ -18,7 +18,9 @@ subdir('qsv') subdir('qt6d3d11') subdir('uvch264') subdir('va') -subdir('waylandsink') +if use_wayland + subdir('waylandsink') +endif subdir('webrtc') subdir('wpe') -- 2.30.2