#!/sbin/runscript # Copyright 1999-2004 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 # $Header: /var/cvsroot/gentoo-x86/media-tv/mythtv/files/mythbackend-0.18.2.rc,v 1.7 2007/05/15 17:57:20 cardoe Exp $ depend() { # future note for me, backend doesn't have to run on # same machine as MySQL so should be use need net use mysql lircd LCDd } start() { [[ -z "${MYTH_VERBOSE}" ]] && MYTH_VERBOSE="important,general" export QTDIR=/usr/qt/3 export HOME=/etc/mythtv #fixes for bug #101308 unset DISPLAY unset SESSION_MANAGER # Work around any strange permissions that may be on these files. chown -R mythtv /var/log/mythtv/ chown -R mythtv /etc/mythtv/ rm -rf /etc/mythtv/.qt ebegin "Starting MythTV Backend" start-stop-daemon --start --quiet --chuid mythtv \ --exec /usr/bin/mythbackend \ --make-pidfile --pidfile /var/run/mythbackend.pid \ --background -- --verbose ${MYTH_VERBOSE} \ --logfile /var/log/mythtv/mythbackend.log eend $? } stop () { ebegin "Stopping MythTV Backend" start-stop-daemon --stop --quiet --pidfile=/var/run/mythbackend.pid eend $? }