[Glibc-bsd-commits] r3833 - trunk/freebsd-utils/debian

Robert Millan rmh at alioth.debian.org
Tue Nov 8 20:32:12 UTC 2011


Author: rmh
Date: 2011-11-08 20:32:12 +0000 (Tue, 08 Nov 2011)
New Revision: 3833

Added:
   trunk/freebsd-utils/debian/devd.init
   trunk/freebsd-utils/debian/devd.install
   trunk/freebsd-utils/debian/devd.manpages
Removed:
   trunk/freebsd-utils/debian/freebsd-utils.devd.init
Modified:
   trunk/freebsd-utils/debian/changelog
   trunk/freebsd-utils/debian/control
   trunk/freebsd-utils/debian/freebsd-utils.install
   trunk/freebsd-utils/debian/freebsd-utils.manpages
   trunk/freebsd-utils/debian/rules
Log:
Split devd into its own package.

Modified: trunk/freebsd-utils/debian/changelog
===================================================================
--- trunk/freebsd-utils/debian/changelog	2011-11-08 20:20:42 UTC (rev 3832)
+++ trunk/freebsd-utils/debian/changelog	2011-11-08 20:32:12 UTC (rev 3833)
@@ -1,8 +1,9 @@
 freebsd-utils (8.2+ds2-9) UNRELEASED; urgency=low
 
   * Add freebsd-ppp package.  Thanks Antoine Beaupré.  (Closes: #574789)
+  * Split devd into its own package.
 
- -- Robert Millan <rmh at debian.org>  Tue, 08 Nov 2011 20:02:08 +0100
+ -- Robert Millan <rmh at debian.org>  Tue, 08 Nov 2011 21:32:02 +0100
 
 freebsd-utils (8.2+ds2-8) unstable; urgency=low
 

Modified: trunk/freebsd-utils/debian/control
===================================================================
--- trunk/freebsd-utils/debian/control	2011-11-08 20:20:42 UTC (rev 3832)
+++ trunk/freebsd-utils/debian/control	2011-11-08 20:32:12 UTC (rev 3833)
@@ -195,6 +195,16 @@
  This package provides both a server and a client PPP daemon that runs
  in userland.
 
+Package: devd
+Section: admin
+Priority: important
+Architecture: kfreebsd-any
+Depends: ${shlibs:Depends}, ${misc:Depends}
+Replaces: freebsd-utils (<< 8.2+ds2-9)
+Description: Device state change daemon
+ The devd daemon provides a way to have userland programs run when certain
+ kernel events happen.
+
 # FIXME:
 # - add pf (pfctl + authpf + /etc stuff + init.d script)
 # - add ipfw (???)

Copied: trunk/freebsd-utils/debian/devd.init (from rev 3829, trunk/freebsd-utils/debian/freebsd-utils.devd.init)
===================================================================
--- trunk/freebsd-utils/debian/devd.init	                        (rev 0)
+++ trunk/freebsd-utils/debian/devd.init	2011-11-08 20:32:12 UTC (rev 3833)
@@ -0,0 +1,127 @@
+#!/bin/sh
+### BEGIN INIT INFO
+# Provides:		devd
+# Required-Start:	$local_fs
+# Required-Stop:	$local_fs
+# Should-Start:		$syslog
+# Should-Stop:		$syslog
+# Default-Start:	S
+# Default-Stop:		0 1 6
+# Short-Description:	device state change daemon
+### END INIT INFO
+
+PATH=/sbin:/bin
+DESC="device state change daemon"
+NAME=devd
+DAEMON=/sbin/devd
+DAEMON_ARGS=""
+PIDFILE=/var/run/$NAME.pid
+SCRIPTNAME=/etc/init.d/$NAME
+
+# Exit if the package is not installed
+[ -x $DAEMON ] || exit 0
+
+# Read configuration variable file if it is present
+[ -r /etc/default/$NAME ] && . /etc/default/$NAME
+
+# Load the VERBOSE setting and other rcS variables
+. /lib/init/vars.sh
+
+# Define LSB log_* functions.
+# Depend on lsb-base (>= 3.0-6) to ensure that this file is present.
+. /lib/lsb/init-functions
+
+#
+# Function that starts the daemon/service
+#
+do_start()
+{
+	# Return
+	#   0 if daemon has been started
+	#   1 if daemon was already running
+	#   2 if daemon could not be started
+	start-stop-daemon --start --quiet --pidfile $PIDFILE --exec $DAEMON --test > /dev/null \
+		|| return 1
+	start-stop-daemon --start --quiet --pidfile $PIDFILE --exec $DAEMON -- \
+		$DAEMON_ARGS \
+		|| return 2
+	# Add code here, if necessary, that waits for the process to be ready
+	# to handle requests from services started subsequently which depend
+	# on this one.  As a last resort, sleep for some time.
+}
+
+#
+# Function that stops the daemon/service
+#
+do_stop()
+{
+	# Return
+	#   0 if daemon has been stopped
+	#   1 if daemon was already stopped
+	#   2 if daemon could not be stopped
+	#   other if a failure occurred
+	start-stop-daemon --stop --quiet --retry=TERM/30/KILL/5 --pidfile $PIDFILE --name $NAME
+	RETVAL="$?"
+	[ "$RETVAL" = 2 ] && return 2
+	# Wait for children to finish too if this is a daemon that forks
+	# and if the daemon is only ever run from this initscript.
+	# If the above conditions are not satisfied then add some other code
+	# that waits for the process to drop all resources that could be
+	# needed by services started subsequently.  A last resort is to
+	# sleep for some time.
+	start-stop-daemon --stop --quiet --oknodo --retry=0/30/KILL/5 --exec $DAEMON
+	[ "$?" = 2 ] && return 2
+	# Many daemons don't delete their pidfiles when they exit.
+	rm -f $PIDFILE
+	return "$RETVAL"
+}
+
+case "$1" in
+  start)
+    log_daemon_msg "Starting $DESC " "$NAME"
+    do_start
+    case "$?" in
+		0|1) log_end_msg 0 ;;
+		2) log_end_msg 1 ;;
+	esac
+  ;;
+  stop)
+	log_daemon_msg "Stopping $DESC" "$NAME"
+	do_stop
+	case "$?" in
+		0|1) log_end_msg 0 ;;
+		2) log_end_msg 1 ;;
+	esac
+	;;
+  status)
+       status_of_proc "$DAEMON" "$NAME" && exit 0 || exit $?
+       ;;
+  restart|force-reload)
+	#
+	# If the "reload" option is implemented then remove the
+	# 'force-reload' alias
+	#
+	log_daemon_msg "Restarting $DESC" "$NAME"
+	do_stop
+	case "$?" in
+	  0|1)
+		do_start
+		case "$?" in
+			0) log_end_msg 0 ;;
+			1) log_end_msg 1 ;; # Old process is still running
+			*) log_end_msg 1 ;; # Failed to start
+		esac
+		;;
+	  *)
+	  	# Failed to stop
+		log_end_msg 1
+		;;
+	esac
+	;;
+  *)
+	echo "Usage: $SCRIPTNAME {start|stop|status|restart|force-reload}" >&2
+	exit 3
+	;;
+esac
+
+:

Added: trunk/freebsd-utils/debian/devd.install
===================================================================
--- trunk/freebsd-utils/debian/devd.install	                        (rev 0)
+++ trunk/freebsd-utils/debian/devd.install	2011-11-08 20:32:12 UTC (rev 3833)
@@ -0,0 +1,4 @@
+sbin/devd/devd				/sbin
+etc/devd.conf				/etc
+etc/devd/*.conf				/etc/devd
+debian/local/devd/*.conf		/etc/devd

Added: trunk/freebsd-utils/debian/devd.manpages
===================================================================
--- trunk/freebsd-utils/debian/devd.manpages	                        (rev 0)
+++ trunk/freebsd-utils/debian/devd.manpages	2011-11-08 20:32:12 UTC (rev 3833)
@@ -0,0 +1,2 @@
+sbin/devd/devd.8
+sbin/devd/devd.conf.5

Deleted: trunk/freebsd-utils/debian/freebsd-utils.devd.init
===================================================================
--- trunk/freebsd-utils/debian/freebsd-utils.devd.init	2011-11-08 20:20:42 UTC (rev 3832)
+++ trunk/freebsd-utils/debian/freebsd-utils.devd.init	2011-11-08 20:32:12 UTC (rev 3833)
@@ -1,127 +0,0 @@
-#!/bin/sh
-### BEGIN INIT INFO
-# Provides:		devd
-# Required-Start:	$local_fs
-# Required-Stop:	$local_fs
-# Should-Start:		$syslog
-# Should-Stop:		$syslog
-# Default-Start:	S
-# Default-Stop:		0 1 6
-# Short-Description:	device state change daemon
-### END INIT INFO
-
-PATH=/sbin:/bin
-DESC="device state change daemon"
-NAME=devd
-DAEMON=/sbin/devd
-DAEMON_ARGS=""
-PIDFILE=/var/run/$NAME.pid
-SCRIPTNAME=/etc/init.d/$NAME
-
-# Exit if the package is not installed
-[ -x $DAEMON ] || exit 0
-
-# Read configuration variable file if it is present
-[ -r /etc/default/$NAME ] && . /etc/default/$NAME
-
-# Load the VERBOSE setting and other rcS variables
-. /lib/init/vars.sh
-
-# Define LSB log_* functions.
-# Depend on lsb-base (>= 3.0-6) to ensure that this file is present.
-. /lib/lsb/init-functions
-
-#
-# Function that starts the daemon/service
-#
-do_start()
-{
-	# Return
-	#   0 if daemon has been started
-	#   1 if daemon was already running
-	#   2 if daemon could not be started
-	start-stop-daemon --start --quiet --pidfile $PIDFILE --exec $DAEMON --test > /dev/null \
-		|| return 1
-	start-stop-daemon --start --quiet --pidfile $PIDFILE --exec $DAEMON -- \
-		$DAEMON_ARGS \
-		|| return 2
-	# Add code here, if necessary, that waits for the process to be ready
-	# to handle requests from services started subsequently which depend
-	# on this one.  As a last resort, sleep for some time.
-}
-
-#
-# Function that stops the daemon/service
-#
-do_stop()
-{
-	# Return
-	#   0 if daemon has been stopped
-	#   1 if daemon was already stopped
-	#   2 if daemon could not be stopped
-	#   other if a failure occurred
-	start-stop-daemon --stop --quiet --retry=TERM/30/KILL/5 --pidfile $PIDFILE --name $NAME
-	RETVAL="$?"
-	[ "$RETVAL" = 2 ] && return 2
-	# Wait for children to finish too if this is a daemon that forks
-	# and if the daemon is only ever run from this initscript.
-	# If the above conditions are not satisfied then add some other code
-	# that waits for the process to drop all resources that could be
-	# needed by services started subsequently.  A last resort is to
-	# sleep for some time.
-	start-stop-daemon --stop --quiet --oknodo --retry=0/30/KILL/5 --exec $DAEMON
-	[ "$?" = 2 ] && return 2
-	# Many daemons don't delete their pidfiles when they exit.
-	rm -f $PIDFILE
-	return "$RETVAL"
-}
-
-case "$1" in
-  start)
-    log_daemon_msg "Starting $DESC " "$NAME"
-    do_start
-    case "$?" in
-		0|1) log_end_msg 0 ;;
-		2) log_end_msg 1 ;;
-	esac
-  ;;
-  stop)
-	log_daemon_msg "Stopping $DESC" "$NAME"
-	do_stop
-	case "$?" in
-		0|1) log_end_msg 0 ;;
-		2) log_end_msg 1 ;;
-	esac
-	;;
-  status)
-       status_of_proc "$DAEMON" "$NAME" && exit 0 || exit $?
-       ;;
-  restart|force-reload)
-	#
-	# If the "reload" option is implemented then remove the
-	# 'force-reload' alias
-	#
-	log_daemon_msg "Restarting $DESC" "$NAME"
-	do_stop
-	case "$?" in
-	  0|1)
-		do_start
-		case "$?" in
-			0) log_end_msg 0 ;;
-			1) log_end_msg 1 ;; # Old process is still running
-			*) log_end_msg 1 ;; # Failed to start
-		esac
-		;;
-	  *)
-	  	# Failed to stop
-		log_end_msg 1
-		;;
-	esac
-	;;
-  *)
-	echo "Usage: $SCRIPTNAME {start|stop|status|restart|force-reload}" >&2
-	exit 3
-	;;
-esac
-
-:

Modified: trunk/freebsd-utils/debian/freebsd-utils.install
===================================================================
--- trunk/freebsd-utils/debian/freebsd-utils.install	2011-11-08 20:20:42 UTC (rev 3832)
+++ trunk/freebsd-utils/debian/freebsd-utils.install	2011-11-08 20:32:12 UTC (rev 3833)
@@ -33,10 +33,6 @@
 sbin/mount_reiserfs/mount_reiserfs	/sbin
 sbin/mount_udf/mount_udf		/sbin
 sbin/mount_unionfs/mount_unionfs	/sbin
-sbin/devd/devd				/sbin
-etc/devd.conf				/etc
-etc/devd/*.conf				/etc/devd
-debian/local/devd/*.conf		/etc/devd
 sbin/devfs/devfs			/sbin
 
 usr.sbin/acpi/acpiconf/acpiconf		/usr/sbin

Modified: trunk/freebsd-utils/debian/freebsd-utils.manpages
===================================================================
--- trunk/freebsd-utils/debian/freebsd-utils.manpages	2011-11-08 20:20:42 UTC (rev 3832)
+++ trunk/freebsd-utils/debian/freebsd-utils.manpages	2011-11-08 20:32:12 UTC (rev 3833)
@@ -5,8 +5,6 @@
 sbin/atacontrol/atacontrol.8
 sbin/camcontrol/camcontrol.8
 sbin/ccdconfig/ccdconfig.8
-sbin/devd/devd.8
-sbin/devd/devd.conf.5
 sbin/devfs/devfs.8
 sbin/dmesg/dmesg.8
 sbin/dumpon/dumpon.8

Modified: trunk/freebsd-utils/debian/rules
===================================================================
--- trunk/freebsd-utils/debian/rules	2011-11-08 20:20:42 UTC (rev 3832)
+++ trunk/freebsd-utils/debian/rules	2011-11-08 20:32:12 UTC (rev 3833)
@@ -304,7 +304,7 @@
 #	dh_installpam
 #	dh_installmime
 	dh_installinit -pfreebsd-utils -- start 03 S .
-	dh_installinit -pfreebsd-utils --name=devd -- start 03 S . stop 01 0 1 6 .
+	dh_installinit -pdevd -- start 03 S . stop 01 0 1 6 .
 	dh_installinit -pkldutils --no-start -- start 12 S .
 	dh_installinit -pkbdcontrol -- start 20 S .
 	dh_installinit -pfreebsd-ppp -- start 20 2 3 4 5 . stop 80 0 1 6 .




More information about the Glibc-bsd-commits mailing list