diff options
author | Cristian RodrÃguez <crrodriguez@opensuse.org> | 2015-01-23 14:35:20 -0300 |
---|---|---|
committer | Lennart Poettering <lennart@poettering.net> | 2015-01-23 19:09:37 +0100 |
commit | 66b0e0e0e3652227fe107ab9d09fa14fd4bc4dfa (patch) | |
tree | b3051c79cf14f973b40ed895d8058e4027b3100d | |
parent | 36a03ca2a8952ca1acb29fbe796210c27ff71aff (diff) |
build-sys: lookup for sulogin, it might not be in /sbin
-rw-r--r-- | Makefile.am | 1 | ||||
-rw-r--r-- | configure.ac | 2 | ||||
-rw-r--r-- | units/console-shell.service.m4.in | 2 | ||||
-rw-r--r-- | units/emergency.service.in | 2 | ||||
-rw-r--r-- | units/rescue.service.in | 2 |
5 files changed, 6 insertions, 3 deletions
diff --git a/Makefile.am b/Makefile.am index 45d7a349fd..c463f2353e 100644 --- a/Makefile.am +++ b/Makefile.am @@ -6220,6 +6220,7 @@ substitutions = \ '|rootprefix=$(rootprefix)|' \ '|udevlibexecdir=$(udevlibexecdir)|' \ '|SUSHELL=$(SUSHELL)|' \ + '|SULOGIN=$(SULOGIN)|' \ '|DEBUGTTY=$(DEBUGTTY)|' \ '|KILL=$(KILL)|' \ '|KMOD=$(KMOD)|' \ diff --git a/configure.ac b/configure.ac index 6bd095cf33..12e4ab2175 100644 --- a/configure.ac +++ b/configure.ac @@ -98,6 +98,8 @@ AC_PATH_PROG([KMOD], [kmod], [/usr/bin/kmod], [$PATH:/usr/sbin:/sbin]) AC_PATH_PROG([KEXEC], [kexec], [/usr/sbin/kexec], [$PATH:/usr/sbin:/sbin]) +AC_PATH_PROG([SULOGIN], [sulogin], [/usr/sbin/sulogin], [$PATH:/usr/sbin:/sbin]) + AS_IF([! ln --relative --help > /dev/null 2>&1], [AC_MSG_ERROR([*** ln doesn't support --relative ***])]) M4_DEFINES= diff --git a/units/console-shell.service.m4.in b/units/console-shell.service.m4.in index 3f4904a0ee..5c80722829 100644 --- a/units/console-shell.service.m4.in +++ b/units/console-shell.service.m4.in @@ -17,7 +17,7 @@ Before=getty.target [Service] Environment=HOME=/root WorkingDirectory=/root -ExecStart=-/sbin/sulogin +ExecStart=-@SULOGIN@ ExecStopPost=-@SYSTEMCTL@ poweroff Type=idle StandardInput=tty-force diff --git a/units/emergency.service.in b/units/emergency.service.in index 18973e78fa..2695d7b7c9 100644 --- a/units/emergency.service.in +++ b/units/emergency.service.in @@ -18,7 +18,7 @@ Environment=HOME=/root WorkingDirectory=/root ExecStartPre=-/bin/plymouth quit ExecStartPre=-/bin/echo -e 'Welcome to emergency mode! After logging in, type "journalctl -xb" to view\\nsystem logs, "systemctl reboot" to reboot, "systemctl default" or ^D to\\ntry again to boot into default mode.' -ExecStart=-/bin/sh -c "/sbin/sulogin; @SYSTEMCTL@ --fail --no-block default" +ExecStart=-/bin/sh -c "@SULOGIN@; @SYSTEMCTL@ --fail --no-block default" Type=idle StandardInput=tty-force StandardOutput=inherit diff --git a/units/rescue.service.in b/units/rescue.service.in index fc93f1e160..de73fee654 100644 --- a/units/rescue.service.in +++ b/units/rescue.service.in @@ -18,7 +18,7 @@ Environment=HOME=/root WorkingDirectory=/root ExecStartPre=-/bin/plymouth quit ExecStartPre=-/bin/echo -e 'Welcome to emergency mode! After logging in, type "journalctl -xb" to view\\nsystem logs, "systemctl reboot" to reboot, "systemctl default" or ^D to\\nboot into default mode.' -ExecStart=-/bin/sh -c "/sbin/sulogin; @SYSTEMCTL@ --fail --no-block default" +ExecStart=-/bin/sh -c "@SULOGIN@; @SYSTEMCTL@ --fail --no-block default" Type=idle StandardInput=tty-force StandardOutput=inherit |