diff -ruN sysvinit-2.84-orig/debian/changelog sysvinit-2.84/debian/changelog
--- sysvinit-2.84-orig/debian/changelog	Tue Sep 10 20:00:00 2002
+++ sysvinit-2.84/debian/changelog	Tue Sep 10 20:00:00 2002
@@ -1,3 +1,9 @@
+sysvinit (2.84-2.fbsd.1) unstable; urgency=low
+
+  * freebsd-i386 changes.
+
+ -- Nathan P. Hawkins III <utsl@quic.net>  Wed, 15 May 2002 14:33:30 -0400
+
 sysvinit (2.84-2) unstable; urgency=low
 
   * modernized inittab manpage.
diff -ruN sysvinit-2.84-orig/debian/control sysvinit-2.84/debian/control
--- sysvinit-2.84-orig/debian/control	Tue Sep 10 20:00:00 2002
+++ sysvinit-2.84/debian/control	Tue Sep 10 20:00:00 2002
@@ -9,7 +9,7 @@
 Architecture: any
 Pre-depends: ${shlibs:Depends}
 Conflicts: last, file-rc (<= 0.5.7), kbd (<< 0.95-2), mdutils (<< 0.35-9)
-Depends: dpkg (>= 1.4.0.21), mount (>= 2.7i-1), util-linux (>= 2.9t-2), e2fsprogs (>= 1.15-1)
+Depends: dpkg (>= 1.4.0.21)
 Replaces: last, bsdutils (<=2.0-2), dpkg (<< 1.9.17)
 Description: System-V like init.
  Init is the first program to run after your system is booted, and
diff -ruN sysvinit-2.84-orig/debian/etc/init.d/bootmisc.sh sysvinit-2.84/debian/etc/init.d/bootmisc.sh
--- sysvinit-2.84-orig/debian/etc/init.d/bootmisc.sh	Tue Sep 10 20:00:00 2002
+++ sysvinit-2.84/debian/etc/init.d/bootmisc.sh	Tue Sep 10 20:00:00 2002
@@ -83,7 +83,7 @@
 #
 # Save kernel messages in /var/log/dmesg
 #
-dmesg -s 65536 > /var/log/dmesg
+dmesg > /var/log/dmesg
 
 : exit 0
 
diff -ruN sysvinit-2.84-orig/debian/etc/init.d/checkfs.sh sysvinit-2.84/debian/etc/init.d/checkfs.sh
--- sysvinit-2.84-orig/debian/etc/init.d/checkfs.sh	Tue Sep 10 20:00:00 2002
+++ sysvinit-2.84/debian/etc/init.d/checkfs.sh	Tue Sep 10 20:00:00 2002
@@ -28,8 +28,15 @@
 	dumb|network|unknown|"") spinner="" ;;
     esac
     [ `uname -m` = s390 ] && spinner="" # This should go away
+    if [ `uname -s` = FreeBSD ]; then
+    	spinner=""
+	fsckargs="-p"
+	[ "$FSCKFIX" = yes -a "$fix" = "-a" ] && fix=""
+    else
+    	fsckargs="-R -A"
+    fi
     echo "Checking all file systems..."
-    fsck $spinner -R -A $fix $force
+    fsck $spinner $fsckargs $fix $force
     if [ $? -gt 1 ]
     then
       echo
diff -ruN sysvinit-2.84-orig/debian/etc/init.d/checkroot.sh sysvinit-2.84/debian/etc/init.d/checkroot.sh
--- sysvinit-2.84-orig/debian/etc/init.d/checkroot.sh	Tue Sep 10 20:00:00 2002
+++ sysvinit-2.84/debian/etc/init.d/checkroot.sh	Tue Sep 10 20:00:00 2002
@@ -61,7 +61,7 @@
 # before fsck, since fsck can be quite memory-hungry.
 #
 doswap=no
-[ -d /proc/1 ] || mount -n /proc
+[ -d /proc/1 ] || mount /proc
 case "`uname -r`" in
 	2.[0123].*)
 		if [ $swap_on_md = yes ] && grep -qs resync /proc/mdstat
@@ -92,7 +92,7 @@
   #
   # Ensure that root is quiescent and read-only before fsck'ing.
   #
-  mount -n -o remount,ro /
+  mount -o update,ro /
   if [ $? = 0 ]
   then
     if [ -f /forcefsck ]
@@ -105,15 +105,15 @@
     then
 	fix="-y"
     else
-	fix="-a"
+	fix=""
     fi
-    spinner="-C"
+#    spinner="-C"
     case "$TERM" in
         dumb|network|unknown|"") spinner="" ;;
     esac
     [ `uname -m` = s390 ] && spinner="" # This should go away
-    echo "Checking root file system..."
-    fsck $spinner $force $fix /
+    echo "Checking file systems..."
+    fsck $spinner -p $force $fix /
     #
     # If there was a failure, drop into single-user mode.
     #
@@ -130,7 +130,7 @@
       echo "that the root file system is currently mounted read-only.  To"
       echo "remount it read-write:"
       echo
-      echo "   # mount -n -o remount,rw /"
+      echo "   # mount -uw /"
       echo
       echo "CONTROL-D will exit from this shell and REBOOT the system."
       echo
@@ -150,13 +150,14 @@
 #	is on a ro fs until the remount succeeded. Then clean up old mtabs
 #	and finally write the new mtab.
 #
-mount -n -o remount,$rootmode /
+mount -o update,$rootmode /
 if [ "$rootmode" = rw ]
 then
 	rm -f /etc/mtab~ /etc/nologin
-	: > /etc/mtab
-	mount -f -o remount /
-	mount -f /proc
+#	: > /etc/mtab
+	mount -f -o update,$rootmode /
+	# why was this here. mounts proc twice...
+#	mount -o update /proc
 	[ "$devfs" ] && grep -q '^devfs /dev' /proc/mounts && mount -f "$devfs"
 fi
 
diff -ruN sysvinit-2.84-orig/debian/etc/init.d/halt sysvinit-2.84/debian/etc/init.d/halt
--- sysvinit-2.84-orig/debian/etc/init.d/halt	Tue Sep 10 20:00:00 2002
+++ sysvinit-2.84/debian/etc/init.d/halt	Tue Sep 10 20:00:00 2002
@@ -20,6 +20,6 @@
 	hddown=""
 fi
 
-halt -d -f -i -p $hddown
+halt -d -f -p $hddown
 
 : exit 0
diff -ruN sysvinit-2.84-orig/debian/etc/init.d/mountall.sh sysvinit-2.84/debian/etc/init.d/mountall.sh
--- sysvinit-2.84-orig/debian/etc/init.d/mountall.sh	Tue Sep 10 20:00:00 2002
+++ sysvinit-2.84/debian/etc/init.d/mountall.sh	Tue Sep 10 20:00:00 2002
@@ -11,8 +11,8 @@
 # about this. So we mount "proc" filesystems without -v.
 #
 [ "$VERBOSE" != no ] && echo "Mounting local filesystems..."
-mount -avt nonfs,nosmbfs,noncpfs,noproc
-mount -at proc
+mount -avt nonfs,nosmbfs,noncpfs,noprocfs
+mount -at procfs
 
 #
 # We might have mounted something over /dev, see if /dev/initctl is there.
diff -ruN sysvinit-2.84-orig/debian/etc/init.d/reboot sysvinit-2.84/debian/etc/init.d/reboot
--- sysvinit-2.84-orig/debian/etc/init.d/reboot	Tue Sep 10 20:00:00 2002
+++ sysvinit-2.84/debian/etc/init.d/reboot	Tue Sep 10 20:00:00 2002
@@ -8,4 +8,4 @@
 PATH=/sbin:/bin:/usr/sbin:/usr/bin
 
 echo -n "Rebooting... "
-reboot -d -f -i
+reboot -d -f 
diff -ruN sysvinit-2.84-orig/debian/etc/init.d/umountfs sysvinit-2.84/debian/etc/init.d/umountfs
--- sysvinit-2.84-orig/debian/etc/init.d/umountfs	Tue Sep 10 20:00:00 2002
+++ sysvinit-2.84/debian/etc/init.d/umountfs	Tue Sep 10 20:00:00 2002
@@ -12,17 +12,17 @@
   *)            FORCE="-f" ;;
 esac
 
-umount -ttmpfs $FORCE -a -r
+# umount -ttmpfs $FORCE -a -r
 
-echo -n "Deactivating swap... "
-swapoff -a
-echo "done."
+#echo -n "Deactivating swap... "
+#swapoff -a
+#echo "done."
 
 # We leave /proc mounted.
 echo -n "Unmounting local filesystems... "
-umount -tnoproc $FORCE -a -r
+umount -tnoprocfs $FORCE -A 
 echo "done."
 
-mount -n -o remount,ro /
+mount -o update,ro /
 
 : exit 0
diff -ruN sysvinit-2.84-orig/debian/etc/init.d/umountnfs.sh sysvinit-2.84/debian/etc/init.d/umountnfs.sh
--- sysvinit-2.84-orig/debian/etc/init.d/umountnfs.sh	Tue Sep 10 20:00:00 2002
+++ sysvinit-2.84/debian/etc/init.d/umountnfs.sh	Tue Sep 10 20:00:00 2002
@@ -16,7 +16,7 @@
 halt -w
 
 echo -n "Unmounting remote filesystems... "
-umount -tnfs,smbfs,ncpfs $FORCE -a -r
+umount -tnfs,smbfs,ncpfs $FORCE -a
 echo "done."
 
 : exit 0
diff -ruN sysvinit-2.84-orig/debian/etc/inittab sysvinit-2.84/debian/etc/inittab
--- sysvinit-2.84-orig/debian/etc/inittab	Tue Sep 10 20:00:00 2002
+++ sysvinit-2.84/debian/etc/inittab	Tue Sep 10 20:00:00 2002
@@ -51,12 +51,12 @@
 # Note that on most Debian systems tty7 is used by the X Window System,
 # so if you want to add more getty's go ahead but skip tty7 if you run X.
 #
-1:2345:respawn:/sbin/getty 38400 tty1
-2:23:respawn:/sbin/getty 38400 tty2
-3:23:respawn:/sbin/getty 38400 tty3
-4:23:respawn:/sbin/getty 38400 tty4
-5:23:respawn:/sbin/getty 38400 tty5
-6:23:respawn:/sbin/getty 38400 tty6
+1:2345:respawn:/sbin/getty 38400 ttyv0
+2:23:respawn:/sbin/getty 38400 ttyv1
+3:23:respawn:/sbin/getty 38400 ttyv2
+4:23:respawn:/sbin/getty 38400 ttyv3
+5:23:respawn:/sbin/getty 38400 ttyv4
+6:23:respawn:/sbin/getty 38400 ttyv5
 
 # Example how to put a getty on a serial line (for a terminal)
 #
diff -ruN sysvinit-2.84-orig/debian/etc/inittab.freebsd-i386 sysvinit-2.84/debian/etc/inittab.freebsd-i386
--- sysvinit-2.84-orig/debian/etc/inittab.freebsd-i386	Wed Dec 31 19:00:00 1969
+++ sysvinit-2.84/debian/etc/inittab.freebsd-i386	Tue Sep 10 20:00:00 2002
@@ -0,0 +1,69 @@
+# /etc/inittab: init(8) configuration.
+# $Id: inittab,v 1.91 2002/01/25 13:35:21 miquels Exp $
+
+# The default runlevel.
+id:2:initdefault:
+
+# Boot-time system configuration/initialization script.
+# This is run first except when booting in emergency (-b) mode.
+si::sysinit:/etc/init.d/rcS
+
+# What to do in single-user mode.
+~~:S:wait:/sbin/sulogin
+
+# /etc/init.d executes the S and K scripts upon change
+# of runlevel.
+#
+# Runlevel 0 is halt.
+# Runlevel 1 is single-user.
+# Runlevels 2-5 are multi-user.
+# Runlevel 6 is reboot.
+
+l0:0:wait:/etc/init.d/rc 0
+l1:1:wait:/etc/init.d/rc 1
+l2:2:wait:/etc/init.d/rc 2
+l3:3:wait:/etc/init.d/rc 3
+l4:4:wait:/etc/init.d/rc 4
+l5:5:wait:/etc/init.d/rc 5
+l6:6:wait:/etc/init.d/rc 6
+# Normally not reached, but fallthrough in case of emergency.
+z6:6:respawn:/sbin/sulogin
+
+# What to do when CTRL-ALT-DEL is pressed.
+ca:12345:ctrlaltdel:/sbin/shutdown -t1 -a -r now
+
+# Action on special keypress (ALT-UpArrow).
+#kb::kbrequest:/bin/echo "Keyboard Request--edit /etc/inittab to let this work."
+
+# What to do when the power fails/returns.
+pf::powerwait:/etc/init.d/powerfail start
+pn::powerfailnow:/etc/init.d/powerfail now
+po::powerokwait:/etc/init.d/powerfail stop
+
+# /sbin/getty invocations for the runlevels.
+#
+# The "id" field MUST be the same as the last
+# characters of the device (after "tty").
+#
+# Format:
+#  <id>:<runlevels>:<action>:<process>
+#
+# Note that on most Debian systems tty7 is used by the X Window System,
+# so if you want to add more getty's go ahead but skip tty7 if you run X.
+#
+1:2345:respawn:/sbin/getty 38400 ttyv0
+2:23:respawn:/sbin/getty 38400 ttyv1
+3:23:respawn:/sbin/getty 38400 ttyv2
+4:23:respawn:/sbin/getty 38400 ttyv3
+5:23:respawn:/sbin/getty 38400 ttyv4
+6:23:respawn:/sbin/getty 38400 ttyv5
+
+# Example how to put a getty on a serial line (for a terminal)
+#
+#T0:23:respawn:/sbin/getty -L ttyS0 9600 vt100
+#T1:23:respawn:/sbin/getty -L ttyS1 9600 vt100
+
+# Example how to put a getty on a modem line.
+#
+#T3:23:respawn:/sbin/mgetty -x0 -s 57600 ttyS3
+
diff -ruN sysvinit-2.84-orig/src/halt.c sysvinit-2.84/src/halt.c
--- sysvinit-2.84-orig/src/halt.c	Tue Nov 27 07:12:03 2001
+++ sysvinit-2.84/src/halt.c	Wed Sep 11 18:51:33 2002
@@ -46,6 +46,7 @@
 #include <stdio.h>
 #include <getopt.h>
 #include "reboot.h"
+#include "init.h"
 
 char *Version = "@(#)halt  2.84  27-Nov-2001 miquels@cistron.nl";
 char *progname;
@@ -54,7 +55,9 @@
 #define RUNLVL_PICKY	0 /* Be picky about the runlevel */
 
 extern int ifdown(void);
+#ifndef __FreeBSD__
 extern int hddown(void);
+#endif
 extern void write_wtmp(char *user, char *id, int pid, int type, char *line);
 
 /*
@@ -246,8 +249,10 @@
 	if (do_ifdown)
 		(void)ifdown();
 
+#ifndef __FreeBSD__
 	if (do_hddown)
 		(void)hddown();
+#endif
 
 	if (do_reboot) {
 		init_reboot(BMAGIC_REBOOT);
@@ -255,7 +260,9 @@
 		/*
 		 *	Turn on hard reboot, CTRL-ALT-DEL will reboot now
 		 */
+#ifndef __FreeBSD__
 		init_reboot(BMAGIC_HARD);
+#endif
 
 		/*
 		 *	Stop init; it is insensitive to the signals sent
@@ -277,7 +284,9 @@
 	/*
 	 *	If we return, we (c)ontinued from the kernel monitor.
 	 */
+#ifndef __FreeBSD__
 	init_reboot(BMAGIC_SOFT);
+#endif
 	kill(1, SIGCONT);
 
 	exit(0);
diff -ruN sysvinit-2.84-orig/src/hddown.c sysvinit-2.84/src/hddown.c
--- sysvinit-2.84-orig/src/hddown.c	Wed Nov  7 10:11:21 2001
+++ sysvinit-2.84/src/hddown.c	Wed Sep 11 18:51:33 2002
@@ -15,6 +15,7 @@
 
 #include <sys/ioctl.h>
 
+#ifndef __FreeBSD__
 #include <linux/hdreg.h>
 
 #define MAX_DISKS	64
@@ -111,3 +112,4 @@
 }
 #endif
 
+#endif
diff -ruN sysvinit-2.84-orig/src/init.c sysvinit-2.84/src/init.c
--- sysvinit-2.84-orig/src/init.c	Wed Sep 11 18:51:11 2002
+++ sysvinit-2.84/src/init.c	Wed Sep 11 18:51:33 2002
@@ -25,14 +25,16 @@
  *		24 Feb 1998, AV:
  *		did_boot made global and added to state - thanks, Miquel.
  *		Yet another file descriptors leak - close state pipe if 
  *		re_exec fails.
  */
 
 #include <sys/types.h>
 #include <sys/stat.h>
 #include <sys/ioctl.h>
 #include <sys/wait.h>
+#ifndef __FreeBSD__
 #include <sys/kd.h>
+#endif
 #include <sys/resource.h>
 #include <stdlib.h>
 #include <unistd.h>
@@ -43,6 +45,10 @@
 #include <string.h>
 #include <signal.h>
 #include <termios.h>
+#ifdef __FreeBSD__
+#define CBAUD	0010017
+#define CBAUDEX	0010000
+#endif
 #include <utmp.h>
 #include <ctype.h>
 #include <stdarg.h>
@@ -2319,13 +2327,14 @@
 	 *	Tell the kernel to send us SIGINT when CTRL-ALT-DEL
 	 *	is pressed, and that we want to handle keyboard signals.
 	 */
+#ifndef __FreeBSD__
 	init_reboot(BMAGIC_SOFT);
 	if ((f = open(VT_MASTER, O_RDWR | O_NOCTTY)) >= 0) {
 		(void) ioctl(f, KDSIGACCEPT, SIGWINCH);
 		close(f);
 	} else
 		(void) ioctl(0, KDSIGACCEPT, SIGWINCH);
-
+#endif
 	/*
 	 *	Ignore all signals.
 	 */
diff -ruN sysvinit-2.84-orig/src/reboot.h sysvinit-2.84/src/reboot.h
--- sysvinit-2.84-orig/src/reboot.h	Wed Sep 24 04:55:52 1997
+++ sysvinit-2.84/src/reboot.h	Wed Sep 11 18:51:33 2002
@@ -10,14 +10,21 @@
 #  include <sys/reboot.h>
 #endif
 
+#ifdef __FreeBSD__
+#include <sys/reboot.h>
+#define BMAGIC_REBOOT	RB_AUTOBOOT
+#define BMAGIC_HALT	RB_HALT
+#define BMAGIC_POWEROFF	RB_POWEROFF
+#define init_reboot(magic) reboot(magic)
+#else
 #define BMAGIC_HARD	0x89ABCDEF
 #define BMAGIC_SOFT	0
 #define BMAGIC_REBOOT	0x01234567
 #define BMAGIC_HALT	0xCDEF0123
 #define BMAGIC_POWEROFF	0x4321FEDC
-
-#if defined(__GLIBC__)
-  #define init_reboot(magic) reboot(magic)
-#else
-  #define init_reboot(magic) reboot(0xfee1dead, 672274793, magic)
+# if defined(__GLIBC__)
+   #define init_reboot(magic) reboot(magic)
+# else
+   #define init_reboot(magic) reboot(0xfee1dead, 672274793, magic)
+# endif
 #endif
diff -ruN sysvinit-2.84-orig/src/sulogin.c sysvinit-2.84/src/sulogin.c
--- sysvinit-2.84-orig/src/sulogin.c	Tue Jul 31 10:22:07 2001
+++ sysvinit-2.84/src/sulogin.c	Wed Sep 11 18:51:33 2002
@@ -254,7 +254,11 @@
 
 	tcgetattr(0, &old);
 	tcgetattr(0, &tty);
+#ifdef __FreeBSD__
+	tty.c_iflag &= ~(IXON|IXOFF|IXANY);
+#else
 	tty.c_iflag &= ~(IUCLC|IXON|IXOFF|IXANY);
+#endif
 	tty.c_lflag &= ~(ECHO|ECHOE|ECHOK|ECHONL|TOSTOP);
 	tcsetattr(0, TCSANOW, &tty);
 
