diff options
Diffstat (limited to 'sys-power/acpid/files/acpid.rc6')
-rwxr-xr-x | sys-power/acpid/files/acpid.rc6 | 28 |
1 files changed, 28 insertions, 0 deletions
diff --git a/sys-power/acpid/files/acpid.rc6 b/sys-power/acpid/files/acpid.rc6 new file mode 100755 index 000000000000..29a8629774ff --- /dev/null +++ b/sys-power/acpid/files/acpid.rc6 @@ -0,0 +1,28 @@ +#!/sbin/runscript +# Copyright 1999-2004 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/sys-power/acpid/files/acpid.rc6,v 1.1 2005/03/15 19:15:53 ciaranm Exp $ + +depend() { + need localmount +} + +checkconfig() { + if [ ! -e /proc/acpi ] ; then + eerror "ACPI support has not been compiled into the kernel" + return 1 + fi +} + +start() { + checkconfig || return 1 + ebegin "Starting acpid" + start-stop-daemon --start --quiet --exec /usr/sbin/acpid -- -c /etc/acpi/events + eend $? +} + +stop() { + ebegin "Stopping acpid" + start-stop-daemon --stop --quiet --exec /usr/sbin/acpid + eend $? +} |