From 2ff95e5c970b3653a5154cbb2351487a6643d177 Mon Sep 17 00:00:00 2001 From: Kirill Primak Date: Sat, 16 Nov 2024 20:04:58 +0300 Subject: [PATCH] meson: use kwargs for wayland deps --- backend/wayland/meson.build | 3 +-- meson.build | 13 +++++++++---- protocol/meson.build | 5 ++++- 3 files changed, 14 insertions(+), 7 deletions(-) diff --git a/backend/wayland/meson.build b/backend/wayland/meson.build index 9235b7fe3..b606a9bb9 100644 --- a/backend/wayland/meson.build +++ b/backend/wayland/meson.build @@ -1,6 +1,5 @@ wayland_client = dependency('wayland-client', - fallback: 'wayland', - default_options: wayland_project_options, + kwargs: wayland_kwargs, ) wlr_deps += wayland_client diff --git a/meson.build b/meson.build index caee73a46..453969507 100644 --- a/meson.build +++ b/meson.build @@ -83,11 +83,16 @@ internal_features = { } internal_config = configuration_data() -wayland_project_options = ['tests=false', 'documentation=false'] +wayland_kwargs = { + 'version': '>=1.23', + 'fallback': 'wayland', + 'default_options': [ + 'tests=false', + 'documentation=false', + ], +} wayland_server = dependency('wayland-server', - version: '>=1.23', - fallback: 'wayland', - default_options: wayland_project_options, + kwargs: wayland_kwargs, ) drm = dependency('libdrm', diff --git a/protocol/meson.build b/protocol/meson.build index f4aafaf57..2889fb033 100644 --- a/protocol/meson.build +++ b/protocol/meson.build @@ -5,7 +5,10 @@ wayland_protos = dependency('wayland-protocols', ) wl_protocol_dir = wayland_protos.get_variable('pkgdatadir') -wayland_scanner_dep = dependency('wayland-scanner', native: true) +wayland_scanner_dep = dependency('wayland-scanner', + kwargs: wayland_kwargs, + native: true, +) wayland_scanner = find_program( wayland_scanner_dep.get_variable('wayland_scanner'), native: true,