#!/sbin/runscript # Copyright 1999-2004 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 # $Header: /var/cvsroot/gentoo-x86/app-accessibility/speechd-up/files/speechd-up.rc,v 1.7 2008/04/24 13:31:49 williamh Exp $ SPEAKUPDEV=/dev/softsynth SPEAKUPDIR=/sys/module/speakup/parameters depend() { use eflite festival need speech-dispatcher } check_speakup() { if [ ! -d ${SPEAKUPDIR} ]; then eerror "Speakup is not currently running." eerror "Please correct this before using speechd-up." return 1 fi if [ ! -c ${SPEAKUPDEV} ]; then mknod ${SPEAKUPDEV} c 10 26 fi echo soft > ${SPEAKUPDIR}/synth sleep 1 } start() { check_speakup || return 1 ebegin "Starting speechd-up" start-stop-daemon --start --quiet --nicelevel ${NICELEVEL} --exec /usr/bin/speechd-up -- -d -t eend $? } stop() { ebegin "Stopping speechd-up" start-stop-daemon --stop --quiet --pidfile /var/run/speechd-up.pid eend $? }