aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSimon Ser <contact@emersion.fr>2021-04-10 09:05:05 +0200
committerKenny Levinsen <kl@kl.wtf>2021-04-10 15:16:26 +0200
commit5884a6003ab77109050df11af0c06956257df910 (patch)
tree5e578f3792e3084d92b2f696e3e1d78387cab916
parent753c5276cf800ae1fb1c7747bfcdaeff5e45d6de (diff)
build: disable logind on -Dauto_features=disabled -Dlogind=auto
Setting auto_features=disabled is supposed to disable all optional dependencies. Since we aren't using a feature option here, we need to manually add logic to disable logind in this case.
-rw-r--r--meson.build4
1 files changed, 3 insertions, 1 deletions
diff --git a/meson.build b/meson.build
index 722735a..a7e4734 100644
--- a/meson.build
+++ b/meson.build
@@ -114,7 +114,9 @@ endif
logind = disabler()
logind_provider = ''
if get_option('logind') != 'disabled'
- if get_option('logind') == 'auto'
+ if get_option('logind') == 'auto' and get_option('auto_features').disabled()
+ # Disable logind
+ elif get_option('logind') == 'auto'
assert(get_option('auto_features').auto(), '-Dlogind must be set to systemd or elogind since auto_features != auto')
foreach logind_provider : ['elogind', 'systemd']
logind = dependency('lib@0@'.format(logind_provider), required: false)