From 3bdf702b1de8b0d0e0fb700b234b0fc69e04a630 Mon Sep 17 00:00:00 2001 From: Jan Beich Date: Tue, 15 Nov 2022 12:18:56 +0000 Subject: [PATCH] meson: look for linux/input-event-codes.h with libwayland flags On DragonFly and FreeBSD native evdev headers are not not be used outside of base system. Linux-compatible headers are provided by evdev-proto package but require extra flags. As evdev-proto lacks pkg-config support use libwayland prefix as approximation. meson.build:974:0: ERROR: C header 'linux/input-event-codes.h' not usable --- meson.build | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/meson.build b/meson.build index 5a82220b38..a584ec15f1 100644 --- a/meson.build +++ b/meson.build @@ -988,7 +988,9 @@ wayland = { dependency('wayland-cursor', version: '>= 1.20.0', required: get_option('wayland')), dependency('wayland-protocols', version: '>= 1.25', required: get_option('wayland')), dependency('xkbcommon', version: '>= 0.3.0', required: get_option('wayland'))], - 'header': cc.has_header('linux/input-event-codes.h', required: get_option('wayland')), + 'header': cc.has_header('linux/input-event-codes.h', required: get_option('wayland'), + # Pass CFLAGS from a related package as a hint for non-Linux + dependencies: dependency('wayland-client', required: get_option('wayland'))), 'scanner': find_program('wayland-scanner', required: get_option('wayland')), } wayland_deps = true