mirror of
https://gitlab.freedesktop.org/wlroots/wlroots.git
synced 2025-10-31 22:25:21 -04:00
xwayland: add dependency on xwayland
Check that the pkg-config file is available. This will be required in the future to check whether xwayland supports features such as -listenfd, -initfd or -verbose. If there's no pkg-config file, check that the Xwayland executable is available. This effectively makes our relationship with xwayland closer to what a dynamic library is: checked at build-time, but can be overridden at run-time.
This commit is contained in:
parent
73137ace84
commit
3504bb587d
5 changed files with 17 additions and 0 deletions
|
|
@ -18,6 +18,19 @@ if not get_option('xwayland').disabled()
|
|||
msg += 'Required for Xwayland support.'
|
||||
endif
|
||||
|
||||
xwayland = dependency('xwayland', required: false)
|
||||
if not xwayland.found()
|
||||
# There's no Xwayland release with the pkg-config file shipped yet.
|
||||
xwayland_prog = find_program('Xwayland', required: false)
|
||||
if not xwayland_prog.found()
|
||||
if get_option('xwayland').enabled()
|
||||
error('\n'.join(msg).format('xwayland'))
|
||||
else
|
||||
subdir_done()
|
||||
endif
|
||||
endif
|
||||
endif
|
||||
|
||||
foreach lib : xwayland_required
|
||||
dep = dependency(lib,
|
||||
required: get_option('xwayland'),
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue