From 13c8a680f9685baba470123aa7bee015cb890438 Mon Sep 17 00:00:00 2001 From: Trent Lloyd Date: Thu, 28 Dec 2006 16:54:26 +0000 Subject: [PATCH] * Import debian init script changes from debian git-svn-id: file:///home/lennart/svn/public/avahi/trunk@1350 941a03a8-eaeb-0310-b9a0-b1bbd8fe43fe --- initscript/debian/avahi-daemon.in | 9 +++++++++ initscript/debian/avahi-dnsconfd.in | 9 +++++++++ 2 files changed, 18 insertions(+) diff --git a/initscript/debian/avahi-daemon.in b/initscript/debian/avahi-daemon.in index 3a68781..553db78 100755 --- a/initscript/debian/avahi-daemon.in +++ b/initscript/debian/avahi-daemon.in @@ -83,10 +83,19 @@ PATH=/sbin:/bin:/usr/sbin:/usr/bin DESC="Avahi mDNS/DNS-SD Daemon" NAME="avahi-daemon" DAEMON="@sbindir@/$NAME" +SCRIPTNAME=/etc/init.d/$NAME # Gracefully exit if the package has been removed. test -x $DAEMON || exit 0 +# don't start if /etc/default/avahi-daemon says so. +AVAHI_DAEMON_START=1 +test -f /etc/default/avahi-daemon && . /etc/default/avahi-daemon + +if [ "$AVAHI_DAEMON_START" != "1" -a "$1" != "stop" ]; then + exit 0 +fi + # # Function that starts the daemon/service. # diff --git a/initscript/debian/avahi-dnsconfd.in b/initscript/debian/avahi-dnsconfd.in index c7cbf05..ee63e06 100755 --- a/initscript/debian/avahi-dnsconfd.in +++ b/initscript/debian/avahi-dnsconfd.in @@ -83,10 +83,19 @@ PATH=/sbin:/bin:/usr/sbin:/usr/bin DESC="Avahi Unicast DNS Configuration Daemon" NAME="avahi-dnsconfd" DAEMON="@sbindir@/$NAME" +SCRIPTNAME=/etc/init.d/$NAME # Gracefully exit if the package has been removed. test -x $DAEMON || exit 0 +# don't start if /etc/default/avahi-dnsconfd says so. +AVAHI_DNSCONFD_START=1 +test -f /etc/default/avahi-dnsconfd && . /etc/default/avahi-dnsconfd + +if [ "$AVAHI_DNSCONFD_START" != "1" -a "$1" != "stop" ]; then + exit 0 +fi + # # Function that starts the daemon/service. # -- 2.39.5