build-sys: meson: Make module-console-kit optional

Default build configuration would fail to run on a system without systemd-logind
(or elogind) and without ConsoleKit daemon responding on dbus interface. Here,
module-console-kit would fail to initialize, preventing daemon from starting.

Make module-console-kit an optional build feature to allow opt-out.

Part-of: <https://gitlab.freedesktop.org/pulseaudio/pulseaudio/-/merge_requests/719>
This commit is contained in:
Igor V. Kovalenko 2022-06-12 21:49:32 +03:00 committed by PulseAudio Marge Bot
parent 9f32b7d7ee
commit 823e46fba0
3 changed files with 14 additions and 1 deletions

View file

@ -130,7 +130,6 @@ endif
if dbus_dep.found()
all_modules += [
[ 'module-console-kit', 'module-console-kit.c', [], [], [dbus_dep] ],
[ 'module-dbus-protocol',
[ 'dbus/iface-card.c', 'dbus/iface-card.h',
'dbus/iface-card-profile.c', 'dbus/iface-card-profile.h',
@ -147,6 +146,12 @@ if dbus_dep.found()
[], [], [dbus_dep] ],
[ 'module-rygel-media-server', 'module-rygel-media-server.c', [], [], [dbus_dep], libprotocol_http ],
]
if not get_option('consolekit').disabled()
all_modules += [
[ 'module-console-kit', 'module-console-kit.c', [], [], [dbus_dep] ],
]
endif
endif
if fftw_dep.found()