Make libinput optional

Only really useful for wlroots compiled without the libinput backend.
This commit is contained in:
Keith Bowes 2024-07-16 03:14:50 -04:00
parent 0f9461c4c0
commit 4cf3ee8a05
2 changed files with 15 additions and 1 deletions

View file

@ -33,13 +33,17 @@ else
endif
libevdev = dependency('libevdev')
libinput = dependency('libinput', version: '>=1.21.0')
libinput = dependency('libinput', version: '>=1.21.0', required: false)
libxml2 = dependency('libxml-2.0')
wayland_protos = dependency('wayland-protocols', version: '>=1.27')
wayland_server = dependency('wayland-server', version: '>=1.15')
wlroots = dependency(wlroots_version, version: '>=0.17.0')
xkbcommon = dependency('xkbcommon')
if libinput.found()
add_project_arguments('-DHAS_LIBINPUT', language: 'c')
endif
msgfmt = find_program('msgfmt', required: false)
if msgfmt.found()
source_root = meson.current_source_dir()