systemd/support-sysvinit.patch
Cristian Rodríguez 5c11ee24a0 Accepting request 139371 from openSUSE:Factory:Staging:Systemd
- Create and own more systemd drop-in directories.

- Improve mini packages for bootstrapping.
- do not mount /tmp as tmpfs by default.

- Fix install script when there is no inittab

- Create a systemd-mini specfile to prevent cycle in bootstrapping

OBS-URL: https://build.opensuse.org/request/show/139371
OBS-URL: https://build.opensuse.org/package/show/Base:System/systemd?expand=0&rev=300
2012-10-26 12:34:44 +00:00

22 lines
1019 B
Diff

Index: systemd-36/src/systemctl.c
===================================================================
--- systemd-36.orig/src/systemctl/systemctl.c
+++ systemd-36/src/systemctl/systemctl.c
@@ -4672,10 +4672,13 @@ static int parse_argv(int argc, char *ar
/* Hmm, so some other init system is
* running, we need to forward this
* request to it. For now we simply
- * guess that it is Upstart. */
-
- execv("/lib/upstart/telinit", argv);
+ * guess that it is Sysvinit or Upstart. */
+ if (!access("/lib/sysvinit/telinit", X_OK)) {
+ execv("/lib/sysvinit/telinit", argv);
+ } else {
+ execv("/lib/upstart/telinit", argv);
+ }
log_error("Couldn't find an alternative telinit implementation to spawn.");
return -EIO;
}