[gnome-initial-setup/wjt/ci-fedora-31: 11/13] meson: Query systemd unit dir using pkg-config



commit c135b5efebe990fbef503c4fde3a607fd98b5914
Author: Benjamin Berg <bberg redhat com>
Date:   Sat Dec 14 10:16:37 2019 +0100

    meson: Query systemd unit dir using pkg-config

 meson.build | 9 +++------
 1 file changed, 3 insertions(+), 6 deletions(-)
---
diff --git a/meson.build b/meson.build
index 9af4cee..1f99918 100644
--- a/meson.build
+++ b/meson.build
@@ -32,14 +32,11 @@ conf.set_quoted('G_LOG_DOMAIN', 'InitialSetup')
 
 enable_systemd = get_option('systemd')
 if enable_systemd
-    systemd_dep = dependency('systemd', required: false)
+    systemd_dep = dependency('systemd', version: '>= 242', required: false)
     assert(systemd_dep.found(), 'Systemd support explicitly required, but systemd not found')
 
-    # XXX: Once https://github.com/systemd/systemd/issues/9595 is fixed and we can
-    # depend on this version, replace with something like:
-    #  systemduserunitdir = systemd_dep.get_pkgconfig_variable('systemduserunitdir')
-    # and uncomment systemd_dep below
-    systemd_userunitdir = join_paths(prefix, 'lib', 'systemd', 'user')
+    systemd_userunitdir = systemd_dep.get_pkgconfig_variable('systemduserunitdir',
+                                                             define_variable: ['prefix', prefix])
 endif
 
 # Needed for the 'account' page


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]