[blfs-book] r9328 - in trunk/bootscripts: . blfs/init.d

wblaszcz at linuxfromscratch.org wblaszcz at linuxfromscratch.org
Thu Feb 9 00:32:11 PST 2012


Author: wblaszcz
Date: 2012-02-09 01:32:00 -0700 (Thu, 09 Feb 2012)
New Revision: 9328

Added:
   trunk/bootscripts/blfs/init.d/avahi
Modified:
   trunk/bootscripts/ChangeLog
   trunk/bootscripts/Makefile
Log:
Added avahi script.

Modified: trunk/bootscripts/ChangeLog
===================================================================
--- trunk/bootscripts/ChangeLog	2012-02-09 02:05:54 UTC (rev 9327)
+++ trunk/bootscripts/ChangeLog	2012-02-09 08:32:00 UTC (rev 9328)
@@ -1,3 +1,6 @@
+2012-02-09 Wayne Blaszczyk <wblaszcz at linuxfromscratch.org>
+   * Added avahi script and modified the Makefile accordingly
+
 2011-12-12 Bruce Dubbs <bdubbs at linuxfromscratch.org>
    * Fix Makefile for httpd for consistency
 

Modified: trunk/bootscripts/Makefile
===================================================================
--- trunk/bootscripts/Makefile	2012-02-09 02:05:54 UTC (rev 9327)
+++ trunk/bootscripts/Makefile	2012-02-09 08:32:00 UTC (rev 9328)
@@ -57,6 +57,16 @@
 	install -m $(CONFMODE) blfs/sysconfig/autofs.conf $(EXTDIR)/sysconfig/
 	ln -sf  ../init.d/autofs $(EXTDIR)/rc.d/rcS.d/S52autofs
 
+install-avahi: create-dirs
+	install -m ${MODE} blfs/init.d/avahi     ${EXTDIR}/rc.d/init.d/
+	ln -sf  ../init.d/avahi ${EXTDIR}/rc.d/rc0.d/K28avahi
+	ln -sf  ../init.d/avahi ${EXTDIR}/rc.d/rc1.d/K28avahi
+	ln -sf  ../init.d/avahi ${EXTDIR}/rc.d/rc2.d/K49avahi
+	ln -sf  ../init.d/avahi ${EXTDIR}/rc.d/rc3.d/S21avahi
+	ln -sf  ../init.d/avahi ${EXTDIR}/rc.d/rc4.d/S21avahi
+	ln -sf  ../init.d/avahi ${EXTDIR}/rc.d/rc5.d/S21avahi
+	ln -sf  ../init.d/avahi ${EXTDIR}/rc.d/rc6.d/K28avahi
+
 install-bind: create-dirs
 	install -m ${MODE} blfs/init.d/bind       ${EXTDIR}/rc.d/init.d/
 	ln -sf  ../init.d/bind ${EXTDIR}/rc.d/rc0.d/K49bind
@@ -514,6 +524,16 @@
 	rm -f $(EXTDIR)/rc.d/init.d/autofs
 	rm -f $(EXTDIR)/rc.d/rcS.d/S52autofs
 
+uninstall-avahi:
+	rm -f ${EXTDIR}/rc.d/init.d/avahi
+	rm -f ${EXTDIR}/rc.d/rc0.d/K28avahi
+	rm -f ${EXTDIR}/rc.d/rc1.d/K28avahi
+	rm -f ${EXTDIR}/rc.d/rc2.d/K49avahi
+	rm -f ${EXTDIR}/rc.d/rc3.d/S21avahi
+	rm -f ${EXTDIR}/rc.d/rc4.d/S21avahi
+	rm -f ${EXTDIR}/rc.d/rc5.d/S21avahi
+	rm -f ${EXTDIR}/rc.d/rc6.d/K28avahi
+
 uninstall-bind:
 	rm -f ${EXTDIR}/rc.d/init.d/bind
 	rm -f ${EXTDIR}/rc.d/rc0.d/K49bind
@@ -890,6 +910,7 @@
 	install-service-ipx \
 	install-service-pppoe \
 	install-alsa \
+	install-avahi \
 	install-httpd \
 	install-bind \
 	install-cups \
@@ -930,6 +951,7 @@
 	install-winbind \
 	install-xinetd \
 	uninstall-alsa \
+	uninstall-avahi \
 	uninstall-httpd \
 	uninstall-bind \
 	uninstall-cups \

Added: trunk/bootscripts/blfs/init.d/avahi
===================================================================
--- trunk/bootscripts/blfs/init.d/avahi	                        (rev 0)
+++ trunk/bootscripts/blfs/init.d/avahi	2012-02-09 08:32:00 UTC (rev 9328)
@@ -0,0 +1,60 @@
+#!/bin/sh
+########################################################################
+# Begin $rc_base/init.d/avahi
+#
+# Description : Avahi daemon loader
+#
+# Authors     : William Immendorf - will.immendorf at gmail.com, with some fixes by BLFS Trac user Ringlis.
+#
+# Version     : 00.00
+#
+# Notes       : Based off of the LFS 6.4 sysklogd script. This controlls all but the AutoIP daemon (I haven't been able to start that).
+#
+########################################################################
+
+. /etc/sysconfig/rc
+. ${rc_functions}
+
+case "${1}" in
+	start)
+		boot_mesg "Starting the Avahi daemon..."
+		loadproc avahi-daemon -D
+
+		boot_mesg "Starting the Avahi mDNS/DNS-SD Server Conf. Daemon..."
+		loadproc avahi-dnsconfd -D
+		;;
+
+	stop)
+		boot_mesg "Stopping the Avahi mDNS/DNS-SD Server Conf. Daemon..."
+		avahi-dnsconfd -k
+		evaluate_retval
+
+		boot_mesg "Stopping the Avahi daemon..."
+		avahi-daemon -k
+		evaluate_retval
+		;;
+
+	reload)
+		boot_mesg "Reloading the Avahi mDNS/DNS-SD Server Conf. Daemon..."
+		reloadproc avahi-dnsconfd -r
+
+		boot_mesg "Reloading the Avahi daemon..."
+		reloadproc avahi-daemon -r
+		;;
+	restart)
+		${0} stop
+		sleep 1
+		${0} start
+		;;
+
+	status)
+		statusproc avahi-daemon
+		statusproc avahi-dnsconfd
+		;;
+	*)
+		echo "Usage: ${0} {start|stop|reload|restart|status}"
+		exit 1
+		;;
+esac
+
+# End $rc_base/init.d/avahi


Property changes on: trunk/bootscripts/blfs/init.d/avahi
___________________________________________________________________
Added: svn:keywords
   + LastChangedBy Date




More information about the blfs-book mailing list