summaryrefslogtreecommitdiff
path: root/meson.build
diff options
context:
space:
mode:
authorZbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl>2017-11-28 20:00:10 +0100
committerZbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl>2017-11-28 20:02:53 +0100
commit74344a1702316845fadad0eb0c8f5d4a8c1dd5c4 (patch)
treeec32734fb036e57b64d66a729d473a24a7345148 /meson.build
parentfbdb6605b5f01bd7f386cc743b2521ec1acafc14 (diff)
downloadsystemd-74344a1702316845fadad0eb0c8f5d4a8c1dd5c4.tar.gz
Revert "meson: drop rootprefix option"
This reverts commit ee4bfa21f62dbf4d8f2be27d3c763c3c16743bfd. Also add comment so that this doesn't get deleted again by mistake. Replaces #7461.
Diffstat (limited to 'meson.build')
-rw-r--r--meson.build10
1 files changed, 9 insertions, 1 deletions
diff --git a/meson.build b/meson.build
index 6ca506c41f..052474895d 100644
--- a/meson.build
+++ b/meson.build
@@ -54,8 +54,15 @@ endif
#####################################################################
+rootprefixdir = get_option('rootprefix')
conf.set10('HAVE_SPLIT_USR', get_option('split-usr'))
-rootprefixdir = get_option('split-usr') ? '/' : '/usr'
+# Unusual rootprefixdir values are used by some distros
+# (see https://github.com/systemd/systemd/pull/7461).
+if get_option('split-usr')
+ rootprefixdir = rootprefixdir != '' ? rootprefixdir : '/'
+else
+ rootprefixdir = rootprefixdir != '' ? rootprefixdir : '/usr'
+endif
sysvinit_path = get_option('sysvinit-path')
sysvrcnd_path = get_option('sysvrcnd-path')
@@ -179,6 +186,7 @@ conf.set_quoted('SYSTEMD_SLEEP_BINARY_PATH', join_paths(rootlib
conf.set_quoted('SYSTEMCTL_BINARY_PATH', join_paths(rootbindir, 'systemctl'))
conf.set_quoted('SYSTEMD_TTY_ASK_PASSWORD_AGENT_BINARY_PATH', join_paths(rootbindir, 'systemd-tty-ask-password-agent'))
conf.set_quoted('SYSTEMD_STDIO_BRIDGE_BINARY_PATH', join_paths(bindir, 'systemd-stdio-bridge'))
+conf.set_quoted('ROOTPREFIX', rootprefixdir)
conf.set_quoted('RANDOM_SEED_DIR', randomseeddir)
conf.set_quoted('RANDOM_SEED', join_paths(randomseeddir, 'random-seed'))
conf.set_quoted('SYSTEMD_CRYPTSETUP_PATH', join_paths(rootlibexecdir, 'systemd-cryptsetup'))