[systemd-devel] [PATCH] build-sys: Lookup for the location of agetty
Cristian RodrÃguez
crrodriguez at opensuse.org
Mon Feb 16 07:42:14 PST 2015
May be in /sbin or /usr/sbin
---
Makefile.am | 1 +
configure.ac | 2 ++
units/console-getty.service.m4.in | 2 +-
units/container-getty at .service.m4.in | 2 +-
units/getty at .service.m4 | 2 +-
units/serial-getty at .service.m4 | 2 +-
6 files changed, 7 insertions(+), 4 deletions(-)
diff --git a/Makefile.am b/Makefile.am
index bf04d31..50da86c 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -6240,6 +6240,7 @@ substitutions = \
'|udevlibexecdir=$(udevlibexecdir)|' \
'|SUSHELL=$(SUSHELL)|' \
'|SULOGIN=$(SULOGIN)|' \
+ '|AGETTY=$(AGETTY)|' \
'|DEBUGTTY=$(DEBUGTTY)|' \
'|KILL=$(KILL)|' \
'|KMOD=$(KMOD)|' \
diff --git a/configure.ac b/configure.ac
index 97a29d6..8d434cf 100644
--- a/configure.ac
+++ b/configure.ac
@@ -100,6 +100,8 @@ AC_PATH_PROG([KEXEC], [kexec], [/usr/sbin/kexec], [$PATH:/usr/sbin:/sbin])
AC_PATH_PROG([SULOGIN], [sulogin], [/usr/sbin/sulogin], [$PATH:/usr/sbin:/sbin])
+AC_PATH_PROG([AGETTY], [agetty], [/usr/sbin/agetty], [$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-getty.service.m4.in b/units/console-getty.service.m4.in
index 8ac51a4..b12810e 100644
--- a/units/console-getty.service.m4.in
+++ b/units/console-getty.service.m4.in
@@ -15,7 +15,7 @@ After=rc-local.service
Before=getty.target
[Service]
-ExecStart=-/sbin/agetty --noclear --keep-baud console 115200,38400,9600 $TERM
+ExecStart=- at AGETTY@ --noclear --keep-baud console 115200,38400,9600 $TERM
Type=idle
Restart=always
RestartSec=0
diff --git a/units/container-getty at .service.m4.in b/units/container-getty at .service.m4.in
index e126f3a..127abaf 100644
--- a/units/container-getty at .service.m4.in
+++ b/units/container-getty at .service.m4.in
@@ -17,7 +17,7 @@ IgnoreOnIsolate=yes
ConditionPathExists=/dev/pts/%I
[Service]
-ExecStart=-/sbin/agetty --noclear --keep-baud pts/%I 115200,38400,9600 $TERM
+ExecStart=- at AGETTY@ --noclear --keep-baud pts/%I 115200,38400,9600 $TERM
Type=idle
Restart=always
RestartSec=0
diff --git a/units/getty at .service.m4 b/units/getty at .service.m4
index 46164ab..e1a418a 100644
--- a/units/getty at .service.m4
+++ b/units/getty at .service.m4
@@ -27,7 +27,7 @@ ConditionPathExists=/dev/tty0
[Service]
# the VT is cleared by TTYVTDisallocate
-ExecStart=-/sbin/agetty --noclear %I $TERM
+ExecStart=- at AGETTY@ --noclear %I $TERM
Type=idle
Restart=always
RestartSec=0
diff --git a/units/serial-getty at .service.m4 b/units/serial-getty at .service.m4
index 4522d0d..bafbbb2 100644
--- a/units/serial-getty at .service.m4
+++ b/units/serial-getty at .service.m4
@@ -22,7 +22,7 @@ Before=getty.target
IgnoreOnIsolate=yes
[Service]
-ExecStart=-/sbin/agetty --keep-baud 115200,38400,9600 %I $TERM
+ExecStart=- at AGETTY@ --keep-baud 115200,38400,9600 %I $TERM
Type=idle
Restart=always
UtmpIdentifier=%I
--
2.2.2
More information about the systemd-devel
mailing list