From 1529edc4324141ea2c13047b80e1d0ba91dcd650 Mon Sep 17 00:00:00 2001 From: jwinterm Date: Sun, 21 Jun 2026 07:54:52 -0400 Subject: [PATCH] depends(wayland): expose native wayland-scanner to cross meson MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Target wayland (-Dscanner=false) resolves the host scanner via dependency(..., native: true), which uses meson's BUILD-machine pkg-config — not pointed at build_prefix. Add PKG_CONFIG_PATH_FOR_BUILD=build_prefix + a [binaries] wayland-scanner in the cross-file. Fixes 'Dependency wayland-scanner not found' on aarch64/riscv64. --- contrib/depends/packages/wayland.mk | 2 +- contrib/depends/patches/wayland/toolchain.txt | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/contrib/depends/packages/wayland.mk b/contrib/depends/packages/wayland.mk index f40093e4..b64c3d8f 100644 --- a/contrib/depends/packages/wayland.mk +++ b/contrib/depends/packages/wayland.mk @@ -19,7 +19,7 @@ define $(package)_preprocess_cmds endef define $(package)_config_cmds - PKG_CONFIG_LIBDIR="$(host_prefix)/lib/pkgconfig:$(build_prefix)/lib/pkgconfig" PKG_CONFIG_PATH="$(build_prefix)/lib/pkgconfig" meson setup --cross-file toolchain.txt build -Ddtd_validation=false -Ddocumentation=false -Dprefer_static=true -Ddefault_library=static -Dtests=false -Dscanner=false + PKG_CONFIG_LIBDIR="$(host_prefix)/lib/pkgconfig:$(build_prefix)/lib/pkgconfig" PKG_CONFIG_PATH="$(build_prefix)/lib/pkgconfig" PKG_CONFIG_PATH_FOR_BUILD="$(build_prefix)/lib/pkgconfig" meson setup --cross-file toolchain.txt build -Ddtd_validation=false -Ddocumentation=false -Dprefer_static=true -Ddefault_library=static -Dtests=false -Dscanner=false endef define $(package)_build_cmds diff --git a/contrib/depends/patches/wayland/toolchain.txt b/contrib/depends/patches/wayland/toolchain.txt index ab8da460..3f08d708 100644 --- a/contrib/depends/patches/wayland/toolchain.txt +++ b/contrib/depends/patches/wayland/toolchain.txt @@ -4,6 +4,7 @@ cpp = '@cxx@' ar = '@ar@' strip = '@strip@' pkgconfig = 'pkg-config' +wayland-scanner = '@build_prefix@/bin/wayland-scanner' [host_machine] system = 'linux'