[PATCH BlueZ v9 03/15] build: Separate systemd and libsystemd dependencies

Bastien Nocera
2026-04-24T09:13:41Z

One is to install systemd service files, the other to enable deeper
logind integration into obexd.
---
meson.build | 3 ++-
meson_options.txt | 3 ++-
2 files changed, 4 insertions(+), 2 deletions(-)

diff --git a/meson.build b/meson.build
index d3c43d79141f..0b5cc0b7ce69 100644
--- a/meson.build
+++ b/meson.build
@@ -138,7 +138,8 @@ readline_dep = dependency('readline',
required: get_option('client').enabled() or
get_option('mesh').enabled())
systemd_dep = dependency('systemd', required: get_option('systemd'))
-libsystemd_dep = dependency('libsystemd', required: get_option('systemd'))
+libsystemd_dep = dependency('libsystemd',
+ required: get_option('obex').enabled() and get_option('logind').enabled())

ell_args = {
'version': '>= 0.39',
diff --git a/meson_options.txt b/meson_options.txt
index 4a0c726c2098..54cfdbb0d7c1 100644
--- a/meson_options.txt
+++ b/meson_options.txt
@@ -6,7 +6,8 @@ option('tests', type: 'feature', value: 'auto', description: 'Enable testing too
option('tools', type: 'feature', value: 'enabled', description: 'Enable Bluetooth tools')
option('monitor', type: 'feature', value: 'enabled', description: 'Enable Bluetooth monitor')
option('client', type: 'feature', value: 'enabled', description: 'Enable command line client')
-option('systemd', type: 'feature', value: 'enabled', description: 'Enable systemd integration')
+option('systemd', type: 'feature', value: 'enabled', description: 'Install systemd service files')
+option('logind', type: 'feature', value: 'enabled', description: 'Enable logind integration in obexd')
option('udev', type: 'feature', value: 'enabled', description: 'Enable udev device support in tools')
option('datafiles', type: 'feature', value: 'enabled', description: 'Install configuration and data files')
option('manpages', type: 'feature', value: 'auto', description: 'Enable building of manual pages')
--
2.53.0