Sign Up
Log In
Log In
or
Sign Up
Places
All Projects
Status Monitor
Collapse sidebar
DISCONTINUED:openSUSE:11.1:Update
bayonne2
bayonne2-1.5.19.dif
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
File bayonne2-1.5.19.dif of Package bayonne2
diff -wruN ../orig-bayonne2-1.5.19/config/bayonne.init.in ./config/bayonne.init.in --- ../orig-bayonne2-1.5.19/config/bayonne.init.in 2006-05-03 22:53:18.000000000 +0200 +++ ./config/bayonne.init.in 2006-07-18 21:00:50.000000000 +0200 @@ -15,6 +15,17 @@ # chkconfig: 2345 98 10 # description: Bayonne is the telephony server of the GNU \ # project and offers interactive voice response. +# +# For LSB compatibility: +# +### BEGIN INIT INFO +# Provides: bayonne +# Required-Start: $remote_fs +# Required-Stop: $remote_fs +# Default-Start: 3 5 +# Default-Stop: 0 1 2 6 +# Description: Bayonne is the telephony server of the GNU project and offers interactive voice response. +### END INIT INFO PATH=/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin DAEMON="@config_sbindir@/bayonne" @@ -31,6 +42,7 @@ DAEMON_OPTS="-p" set -e +. /etc/rc.status case "$1" in start) @@ -51,7 +63,9 @@ DAEMON_PRELOAD="" if test -f /usr/dialogic/lib/libgc.so ; then - DAEMON_PRELOAD=/usr/lib/libLiS.so:/usr/dialogic/lib/libgc.so:/usr/dialogic/lib/libdevmap.so + DAEMON_PRELOAD=/usr/lib64/libLiS.so:/usr/lib/libLiS.so:/usr/dialogic/lib/libgc.so:/usr/dialogic/lib/libdevmap.so + elif test -f /usr/lib64/libLiS.so ; then + DAEMON_PRELOAD=/usr/lib64/libLiS.so elif test -f /usr/lib/libLiS.so ; then DAEMON_PRELOAD=/usr/lib/libLiS.so fi @@ -68,11 +82,6 @@ export LD_PRELOAD fi - if test -p $FIFO ; then - echo "already started" - exit -1 - fi - if test ! -z "$DRIVER" ; then export DRIVER ; fi @@ -85,40 +94,98 @@ if test ! -z "$OPTIONS" ; then DAEMON_OPTS="$OPTIONS" ; fi - $DAEMON $DAEMON_OPTS - echo "$NAME." + startproc $DAEMON $DAEMON_OPTS + RETVAL=$? + [ $RETVAL -eq 0 ] && touch /var/lock/subsys/bayonne + echo + + # Remember status and be verbose + rc_status -v ;; stop) - if test ! -p $FIFO ; then - exit 0 ; fi + echo -n "Shutting down service bayonne: " + ## Stop daemon with killproc(8) and if this fails + ## set echo the echo return value. + + killproc -TERM $bayonne_BIN + RETVAL=$? + [ $RETVAL -eq 0 ] && rm -f /var/lock/subsys/bayonne + + # Remember status and be verbose + rc_status -v + ;; + restart) + ## Stop the service and regardless of whether it was + ## running or not, start it again. + $0 stop + $0 start - echo -n "Stopping $DESC: " - echo "down" >$FIFO - echo "$NAME." + # Remember status and be quiet + rc_status + ;; + force-reload) + ## Signal the daemon to reload its config. Most daemons + ## do this on signal 1 (SIGHUP). + ## If it does not support it, restart. + + echo -n "Reload service bayonne" + ## if it supports it: + killproc -HUP $bayonne_BIN + #touch /var/run/bayonne.pid + rc_status -v + + ## Otherwise: + #$0 stop && $0 start + #rc_status ;; reload) - if test ! -p $FIFO ; then - exit 0 ; fi - echo -n "Reloading $DESC: " - echo "reload" >$FIFO - echo "$NAME." + ## Like force-reload, but if daemon does not support + ## signalling, do nothing (!) + + # If it supports signalling: + echo -n "Reload service bayonne" + killproc -HUP $bayonne_BIN + #touch /var/run/bayonne.pid + rc_status -v + + ## Otherwise if it does not support reload: + #rc_failed 3 + #rc_status -v ;; - restart|force-reload) - # - # If the "reload" option is implemented, move the "force-reload" - # option to the "reload" entry above. If not, "force-reload" is - # just the same as "restart". - # - echo -n "Restarting $DESC: " - start-stop-daemon --stop --quiet --exec $DAEMON - sleep 3 - start-stop-daemon --start --quiet --exec $DAEMON -- $DAEMON_OPTS - echo "$NAME." + try-restart) + ## Stop the service and if this succeeds (i.e. the + ## service was running before), start it again. + ## Note: try-restart is not (yet) part of LSB (as of 0.7.5) + $0 status >/dev/null && $0 restart + + # Remember status and be quiet + rc_status + ;; + status) + echo -n "Checking for bayonne: " + ## Check status with checkproc(8), if process is running + ## checkproc will return with exit status 0. + + # Status has a slightly different for the status command: + # 0 - service running + # 1 - service dead, but /var/run/ pid file exists + # 2 - service dead, but /var/lock/ lock file exists + # 3 - service not running + + # NOTE: checkproc returns LSB compliant status values. + checkproc $bayonne_BIN + rc_status -v + ;; + probe) + ## Optional: Probe for the necessity of a reload, + ## give out the argument which is required for a reload. + + test /etc/bayonne.conf -nt /var/run/bayonne.pid && echo reload ;; *) N=/etc/init.d/$NAME # echo "Usage: $N {start|stop|restart|reload|force-reload}" >&2 - echo "Usage: $N {start|stop|restart|force-reload}" >&2 + echo "Usage: $0 {start|stop|status|try-restart|restart|force-reload|reload|probe}" exit 1 ;; esac diff -wruN ../orig-bayonne2-1.5.19/config/Makefile.am ./config/Makefile.am --- ../orig-bayonne2-1.5.19/config/Makefile.am 2006-05-14 19:44:05.000000000 +0200 +++ ./config/Makefile.am 2006-07-18 20:20:25.000000000 +0200 @@ -12,10 +12,10 @@ EXTRA_DIST = *.conf bayonne.init* instconfig bayonne.log RELEASE = -version-info @LT_VERSION@ -release @LT_RELEASE@ -ETC=$(sysconfdir) -CONF=$(sysconfdir)/bayonne -INIT=$(sysconfdir)/init.d -LOGD=$(sysconfdir)/logrotate.d +ETC=$(DESTDIR)$(sysconfdir) +CONF=$(DESTDIR)$(sysconfdir)/bayonne +INIT=$(DESTDIR)$(sysconfdir)/init.d +LOGD=$(DESTDIR)$(sysconfdir)/logrotate.d all:
Locations
Projects
Search
Status Monitor
Help
OpenBuildService.org
Documentation
API Documentation
Code of Conduct
Contact
Support
@OBShq
Terms
openSUSE Build Service is sponsored by
The Open Build Service is an
openSUSE project
.
Sign Up
Log In
Places
Places
All Projects
Status Monitor