[systemd-commits] configure.ac src/systemctl

Lennart Poettering lennart at kemper.freedesktop.org
Fri Mar 22 17:53:22 PDT 2013


 configure.ac              |   10 ++++++++++
 src/systemctl/systemctl.c |    2 +-
 2 files changed, 11 insertions(+), 1 deletion(-)

New commits:
commit 4ad61fd1806dde23d2c99043b4bed91a196d2c82
Author: Cristian Rodríguez <crrodriguez at opensuse.org>
Date:   Fri Mar 22 21:04:53 2013 -0300

    add --with-telinit=PATH configure option
    
    Distributions that never shipped upstart do not have
    "telinit" in /lib/upstart/..
    
    Defaults to /lib/upstart/telinit so there is no change
    for systems existing installs.

diff --git a/configure.ac b/configure.ac
index 79a4ec4..f1bf758 100644
--- a/configure.ac
+++ b/configure.ac
@@ -683,6 +683,16 @@ AC_DEFINE_UNQUOTED(KBD_SETFONT, ["$KBD_SETFONT"], [Path of setfont])
 AC_SUBST(KBD_LOADKEYS)
 AC_SUBST(KBD_SETFONT)
 
+AC_ARG_WITH(telinit,
+        AS_HELP_STRING([--with-telinit=PATH],
+                [Path to telinit]),
+        [TELINIT="$withval"],
+        [TELINIT="/lib/upstart/telinit"])
+
+AC_DEFINE_UNQUOTED(TELINIT, ["$TELINIT"], [Path to telinit])
+
+AC_SUBST(TELINIT)
+
 # ------------------------------------------------------------------------------
 have_myhostname=no
 AC_ARG_ENABLE(myhostname, AS_HELP_STRING([--disable-myhostname], [disable nss-myhostname support]))
diff --git a/src/systemctl/systemctl.c b/src/systemctl/systemctl.c
index 1ea0e4e..edd136a 100644
--- a/src/systemctl/systemctl.c
+++ b/src/systemctl/systemctl.c
@@ -4918,7 +4918,7 @@ static int parse_argv(int argc, char *argv[]) {
                                  * request to it. For now we simply
                                  * guess that it is Upstart. */
 
-                                execv("/lib/upstart/telinit", argv);
+                                execv(TELINIT, argv);
 
                                 log_error("Couldn't find an alternative telinit implementation to spawn.");
                                 return -EIO;



More information about the systemd-commits mailing list