Meson: Override wayland-scanner if it can be run

This allows projects to use Wayland as a Meson subproject and get the
wayland-scanner executable when doing find_program('wayland-scanner').

Signed-off-by: Xavier Claessens <xavier.claessens@collabora.com>
This commit is contained in:
Xavier Claessens 2022-04-04 09:34:33 -04:00 committed by Pekka Paalanen
parent 5e4253ed50
commit 24244f26bf

View file

@ -71,6 +71,10 @@ if get_option('scanner')
],
filebase: 'wayland-scanner'
)
if meson.can_run_host_binaries()
meson.override_find_program('wayland-scanner', wayland_scanner)
endif
endif
if meson.is_cross_build() or not get_option('scanner')