From d1a132e5b28680602a64f5d6f9fcfa4072f75cc4 Mon Sep 17 00:00:00 2001 From: Sebastien Estienne Date: Thu, 30 Jun 2005 11:27:33 +0000 Subject: [PATCH] New gentoo initscript using libdaemon features git-svn-id: file:///home/lennart/svn/public/avahi/trunk@155 941a03a8-eaeb-0310-b9a0-b1bbd8fe43fe --- initscript/Gentoo/avahi.in | 26 +++++++++++++++++--------- 1 file changed, 17 insertions(+), 9 deletions(-) diff --git a/initscript/Gentoo/avahi.in b/initscript/Gentoo/avahi.in index af26512..a37c965 100644 --- a/initscript/Gentoo/avahi.in +++ b/initscript/Gentoo/avahi.in @@ -1,20 +1,28 @@ +#!/sbin/runscript +# Avahi ZeroConf Daemon init script +# Many thanks to the Avahi developer's and Sebastien Estienne + DAEMON=/usr/bin/avahi +depend () { + need dbus +} + start() { - ebegin "Starting avahi" - start-stop-daemon --start --quiet --exec $DAEMON - eend $? + ebegin "Starting avahi" + $DAEMON -D + eend $? } stop() { - ebegin "Stopping avahi" - start-stop-daemon --stop --quiet --exec $DAEMON - eend $? + ebegin "Stopping avahi" + $DAEMON -k || /bin/true + eend $? } reload() { - ebegin "Reloading avahi configuration" - start-stop-daemon --stop --signal 1 --quiet --exec $DAEMON - eend $? + ebegin "Reloading avahi configuration" + $DAEMON -r + eend $? } -- 2.39.5