Package: sysvinit
Version: 2.86-1
Author: Guillem Jover <guillem@debian.org>
Status: not-sent
Description:
 Port to GNU/Hurd.

diff -Naur sysvinit-2.86/debian/changelog sysvinit-2.86.new/debian/changelog
--- sysvinit-2.86/debian/changelog	2004-08-11 03:49:29.000000000 +0200
+++ sysvinit-2.86.new/debian/changelog	2004-08-09 23:40:58.000000000 +0200
@@ -1,3 +1,10 @@
+sysvinit (2.86-1+hurd) unreleased; urgency=low
+
+  * Check for pid == 1 || ppid == 1.
+  * Reenable halt and reboot on the Hurd.
+
+ -- Guillem Jover <guillem@debian.org>  Mon,  9 Aug 2004 23:16:54 +0200
+
 sysvinit (2.86-1) unstable; urgency=medium
 
   * Better algorithm for pidof (closes: #248210)
diff -Naur sysvinit-2.86/debian/rules sysvinit-2.86.new/debian/rules
--- sysvinit-2.86/debian/rules	2004-08-11 03:49:29.000000000 +0200
+++ sysvinit-2.86.new/debian/rules	2004-08-10 00:16:08.000000000 +0200
@@ -72,13 +72,6 @@
 	install -d -g root -m 755 -o root $(tmp)/usr/share/man
 	install -d -g root -m 755 -o root $(tmp)/usr/share/man/man{1,5,8}
 	(cd src; make ROOT=$(tmp) DISTRO=Debian install )
-ifeq ($(DEB_HOST_ARCH), hurd-i386)
-	# The Hurd has its own halt and reboot commands.
-	rm -f $(tmp)/usr/share/man/man8/halt.8
-	rm -f $(tmp)/usr/share/man/man8/reboot.8
-	rm -f $(tmp)/sbin/halt
-	rm -f $(tmp)/sbin/reboot
-endif
 	rm -f $(tmp)/usr/share/man/man1/mountpoint.1
 	rm -f $(tmp)/bin/mountpoint
 	gzip -9f $(tmp)/usr/share/man/man*/*.[0-9]
diff -Naur sysvinit-2.86/src/init.c sysvinit-2.86.new/src/init.c
--- sysvinit-2.86/src/init.c	2004-07-30 14:16:20.000000000 +0200
+++ sysvinit-2.86.new/src/init.c	2004-08-09 23:40:58.000000000 +0200
@@ -2616,7 +2616,7 @@
 	/*
 	 *	Is this telinit or init ?
 	 */
-	isinit = (getpid() == 1);
+	isinit = (getpid() == 1) || (getppid() == 1);
 	for (f = 1; f < argc; f++) {
 		if (!strcmp(argv[f], "-i") || !strcmp(argv[f], "--init"))
 			isinit = 1;
