From 5ef69fc591e2fbad2b399e765d697150c97a95a6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Daniel=20Ekl=C3=B6f?= Date: Sun, 8 Sep 2024 10:42:24 +0200 Subject: [PATCH] meson: detect wayland-protocols >= 1.37, and conditionally enable xdg-toplevel-icon-v1 --- meson.build | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/meson.build b/meson.build index 1b3b01aa..91e745bf 100644 --- a/meson.build +++ b/meson.build @@ -171,6 +171,14 @@ wl_proto_xml = [ wayland_protocols_datadir / 'staging/single-pixel-buffer/single-pixel-buffer-v1.xml', ] +if wayland_protocols.version().version_compare('>=1.37') + add_project_arguments('-DHAVE_XDG_TOPLEVEL_ICON', language: 'c') + wl_proto_xml += [wayland_protocols_datadir / 'staging/xdg-toplevel-icon/xdg-toplevel-icon-v1.xml'] + xdg_toplevel_icon = true +else + xdg_toplevel_icon = false +endif + foreach prot : wl_proto_xml wl_proto_headers += custom_target( prot.underscorify() + '-client-header', @@ -401,6 +409,7 @@ summary( 'Themes': get_option('themes'), 'IME': get_option('ime'), 'Grapheme clustering': utf8proc.found(), + 'Wayland: xdg-toplevel-icon-v1': xdg_toplevel_icon, 'utmp backend': utmp_backend, 'utmp helper default path': utmp_default_helper_path, 'Build terminfo': tic.found(),