#!/bin/sh
# description: OSS to Jack daemon
#
# (c) 2006, Eko M. Budi, for Vector Linux
# Released under GNU GPL
#
# Include the functions declared in the /etc/rc.d/functions file
source /etc/rc.d/functions

# path to binary
ROOT="/usr/bin"
# name of binary to run
APP="oss2jack"
#runtime options
OPT="-d"
#server name & description
SERVER="OSS to Jack"

load_modules() {
   modprobe kfusd
}

case "$1" in
    start)
	load_modules
	echon "Starting $SERVER ..."
	loadproc $ROOT/$APP $OPT
	;;
    stop)
	echon "Stopping $SERVER ..."
        killproc $ROOT/$APP
        ;;
    reload)
        echon "Reloading $SERVER..........."
        reloadproc $ROOT/$APP
        ;;
    restart)
        $0 stop
	sleep 1
	$0 start
        ;;
    status)
        statusproc $ROOT/$APP
        ;;
    *)
        echo "Usage: $0 {start|stop|reload|restart|status}"        
    ;;
esac

# End /etc/init.d/
