]> git.proxmox.com Git - mirror_lxcfs.git/commitdiff
Query systemd system unit dir.
authorThomas Moschny <thomas.moschny@gmx.de>
Sun, 13 Mar 2022 12:00:56 +0000 (13:00 +0100)
committerThomas Moschny <thomas.moschny@gmx.de>
Sun, 13 Mar 2022 12:20:41 +0000 (13:20 +0100)
Signed-off-by: Thomas Moschny <thomas.moschny@gmx.de>
config/init/meson.build

index 38b6a923cbe8a51723b7556f4d4f2e6c853fdf61..e39c2abde0090b3e8ab71d09d52201f9001e43f1 100644 (file)
@@ -1,6 +1,8 @@
 # SPDX-License-Identifier: LGPL-2.1-or-later
 
 if init_script == 'systemd'
+    systemd = dependency('systemd')
+    systemd_system_unit_dir = systemd.get_pkgconfig_variable('systemdsystemunitdir')
     systemd_service = custom_target(
         'lxcfs.service',
         input: 'systemd/lxcfs.service.in',
@@ -12,7 +14,7 @@ if init_script == 'systemd'
             '@OUTPUT@',
         ],
         install: true,
-        install_dir: join_paths(libdir, 'systemd/system'))
+        install_dir: systemd_system_unit_dir)
 
 elif init_script == 'upstart'
         install_data('upstart/lxcfs.conf', install_dir: join_paths(sysconfdir, 'init'))