* Move backends into their own packages.
* No longer symlink docs from dbg package (this simplifies
- packaging)
+ packaging).
+ * Manage the ossp slave via update-alternatives.
-- Ralf Jung <post@ralfj.de> Mon, 09 Sep 2013 18:29:12 +0200
--- /dev/null
+#!/bin/sh
+set -e
+
+update-alternatives --install /usr/lib/osspd/ossp-slave \
+ ossp-slave /usr/lib/osspd/ossp-alsap 60
+
+#DEBHELPER#
+
+exit 0
--- /dev/null
+#!/bin/sh
+set -e
+
+if [ "$1" = "remove" ]; then
+ update-alternatives --remove ossp-slave /usr/lib/osspd/ossp-alsap
+fi
+
+#DEBHELPER#
+
+exit 0
--- /dev/null
+#!/bin/sh
+set -e
+
+update-alternatives --install /usr/lib/osspd/ossp-slave \
+ ossp-slave /usr/lib/osspd/ossp-padsp 70
+
+#DEBHELPER#
+
+exit 0
--- /dev/null
+#!/bin/sh
+set -e
+
+if [ "$1" = "remove" ]; then
+ update-alternatives --remove ossp-slave /usr/lib/osspd/ossp-padsp
+fi
+
+#DEBHELPER#
+
+exit 0
DESC="OSS Proxy Daemon"
NAME=osspd
DAEMON=/usr/sbin/$NAME
-DAEMON_ARGS="-f" # run in foreground, start-stop-daemon does the forking: required to let start-stop-daemon handle the pidfile
+DAEMON_ARGS="--dsp-slave=/usr/lib/osspd/ossp-slave"
PIDFILE=/var/run/$NAME.pid
SCRIPTNAME=/etc/init.d/$NAME
# 2 if daemon could not be started
start-stop-daemon --start --background --quiet --pidfile $PIDFILE --make-pidfile --exec $DAEMON --test > /dev/null \
|| return 1
+ # -f: run in foreground, start-stop-daemon does the forking - this is required to let start-stop-daemon handle the pidfile
start-stop-daemon --start --background --quiet --pidfile $PIDFILE --make-pidfile --exec $DAEMON -- -f \
$DAEMON_ARGS \
|| return 2