From 1ace2a5daf1d25020182fb17459443ff882df015 Mon Sep 17 00:00:00 2001 From: Wim Taymans Date: Thu, 14 Dec 2017 09:30:34 +0100 Subject: [PATCH] make systemd dependency optional Don't recurse into the directory of systemd when it was not found. There are still some issues because libudev is actually provided by systemd these days and we still need that for building the v4l2 and alsa monitors. --- src/daemon/meson.build | 6 +++++- src/daemon/systemd/user/meson.build | 5 +---- 2 files changed, 6 insertions(+), 5 deletions(-) diff --git a/src/daemon/meson.build b/src/daemon/meson.build index 35591ae4e..27eb1f009 100644 --- a/src/daemon/meson.build +++ b/src/daemon/meson.build @@ -30,4 +30,8 @@ executable('pipewire', dependencies : [pipewire_dep], ) -subdir('systemd') +systemd = dependency('systemd', required: false) + +if systemd.found() + subdir('systemd') +endif diff --git a/src/daemon/systemd/user/meson.build b/src/daemon/systemd/user/meson.build index 53ee32ef6..a3970a824 100644 --- a/src/daemon/systemd/user/meson.build +++ b/src/daemon/systemd/user/meson.build @@ -1,7 +1,4 @@ -systemd = dependency('systemd', required: true) -if systemd.found() - systemd_user_services_dir = systemd.get_pkgconfig_variable('systemduserunitdir') -endif +systemd_user_services_dir = systemd.get_pkgconfig_variable('systemduserunitdir') install_data(sources : 'pipewire.socket', install_dir : systemd_user_services_dir)