diff options
Diffstat (limited to 'meson.build')
-rw-r--r-- | meson.build | 17 |
1 files changed, 6 insertions, 11 deletions
diff --git a/meson.build b/meson.build index 502616ca..7d5266d2 100644 --- a/meson.build +++ b/meson.build @@ -62,27 +62,22 @@ libinput = dependency('libinput', version: '>=1.7.0') xkbcommon = dependency('xkbcommon') udev = dependency('libudev') pixman = dependency('pixman-1') -libcap = dependency('libcap', required: get_option('enable-libcap') == 'true') -systemd = dependency('libsystemd', required: get_option('enable-systemd') == 'true') -elogind = dependency('libelogind', required: get_option('enable-elogind') == 'true') +libcap = dependency('libcap', required: get_option('libcap')) +logind = dependency('lib' + get_option('logind-provider'), required: get_option('logind')) math = cc.find_library('m', required: false) exclude_headers = [] wlr_parts = [] wlr_deps = [] -if libcap.found() and get_option('enable-libcap') != 'false' +if libcap.found() conf_data.set('WLR_HAS_LIBCAP', true) wlr_deps += libcap endif -if systemd.found() and get_option('enable-systemd') != 'false' - conf_data.set('WLR_HAS_SYSTEMD', true) - wlr_deps += systemd -endif - -if elogind.found() and get_option('enable-elogind') != 'false' - conf_data.set('WLR_HAS_ELOGIND', true) +if logind.found() + conf_data.set('WLR_HAS_' + get_option('logind-provider').to_upper(), true) + wlr_deps += logind endif if get_option('enable-x11_backend') or get_option('enable-xwayland') |