aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--meson.build12
-rw-r--r--meson_options.txt6
2 files changed, 9 insertions, 9 deletions
diff --git a/meson.build b/meson.build
index a2f08446..43af94a8 100644
--- a/meson.build
+++ b/meson.build
@@ -65,24 +65,24 @@ xcb_image = dependency('xcb-image')
xcb_render = dependency('xcb-render')
xcb_icccm = dependency('xcb-icccm', required: false)
x11_xcb = dependency('x11-xcb')
-libcap = dependency('libcap', required: false)
-systemd = dependency('libsystemd', required: false)
-elogind = dependency('libelogind', required: false)
+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')
math = cc.find_library('m', required: false)
if xcb_icccm.found()
conf_data.set('WLR_HAS_XCB_ICCCM', true)
endif
-if libcap.found() and get_option('enable_libcap')
+if libcap.found() and get_option('enable_libcap') != 'false'
conf_data.set('WLR_HAS_LIBCAP', true)
endif
-if systemd.found() and get_option('enable_systemd')
+if systemd.found() and get_option('enable_systemd') != 'false'
conf_data.set('WLR_HAS_SYSTEMD', true)
endif
-if elogind.found() and get_option('enable_elogind')
+if elogind.found() and get_option('enable_elogind') != 'false'
conf_data.set('WLR_HAS_ELOGIND', true)
endif
diff --git a/meson_options.txt b/meson_options.txt
index b1e64bd9..6434b43d 100644
--- a/meson_options.txt
+++ b/meson_options.txt
@@ -1,4 +1,4 @@
-option('enable_libcap', type: 'boolean', value: true, description: 'Enable support for capabilities')
-option('enable_systemd', type: 'boolean', value: true, description: 'Enable support for logind')
-option('enable_elogind', type: 'boolean', value: true, description: 'Enable support for logind')
+option('enable_libcap', type: 'combo', choices: ['auto', 'true', 'false'], value: 'auto', description: 'Enable support for capabilities')
+option('enable_systemd', type: 'combo', choices: ['auto', 'true', 'false'], value: 'auto', description: 'Enable support for logind')
+option('enable_elogind', type: 'combo', choices: ['auto', 'true', 'false'], value: 'auto', description: 'Enable support for logind')
option('enable_xwayland', type: 'boolean', value: true, description: 'Enable support X11 applications')