Sophie

Sophie

distrib > Fedora > 15 > i386 > by-pkgid > 6f83fddc4ec0fc4b0e035c057298835b > files > 1

audio-entropyd-2.0.1-3.fc15.i686.rpm

#! /bin/sh
#
# audio-entropyd:       Starts the Audio Entropy Daemon
#
# chkconfig: - 98 02
# description: This is a daemon which runs on client machines to generate entropy
#              from the system soundcard (if present and active).
# processname: audio-entropyd
# config: /etc/sysconfig/audio-entropyd

confdir=/etc/sysconfig

# Source function library.
. /etc/init.d/functions

AED_BIN=/usr/sbin/audio-entropyd
test -x $AED_BIN || exit 5

LOCKFILE=/var/lock/subsys/audio-entropyd

if [ -r $confdir/audio-entropyd ]; then
    . $confdir/audio-entropyd
fi

case "$1" in
   start)
       echo -n $"Starting Audio Entropy daemon... "
       daemon $AED_BIN $OPTIONS
       RETVAL=$?
       echo
       [ $RETVAL -eq 0 ] && touch $LOCKFILE
       ;;
   stop)
       echo -n $"Shutting down Audio Entropy daemon: "
       killproc $AED_BIN
       RETVAL=$?
       echo
       [ $RETVAL -eq 0 ] && rm -f $LOCKFILE
       ;;
   restart|reload)
       $0 stop
       $0 start
       ;;
   condrestart)
       [ -f $LOCKFILE ] && restart || :
       ;;
   status)
       status audio-entropyd
       RETVAL=$?
       ;;
   *)
       echo $"Usage: $0 {start|stop|status|reload|restart|condrestart}"
       RETVAL=1
       ;;
esac

exit $RETVAL