From 287010aacbe123c28ec9c787524ffe541a445147 Mon Sep 17 00:00:00 2001 From: Mike Frysinger Date: Sun, 20 Aug 2006 04:16:45 +0000 Subject: spruce up the init.d and default config files Package-Manager: portage-2.1.1_pre5-r2 --- sys-power/acpid/files/acpid-1.0.4-init.d | 19 +++++++++---------- sys-power/acpid/files/acpid.conf.d | 6 ++++++ 2 files changed, 15 insertions(+), 10 deletions(-) create mode 100644 sys-power/acpid/files/acpid.conf.d (limited to 'sys-power/acpid') diff --git a/sys-power/acpid/files/acpid-1.0.4-init.d b/sys-power/acpid/files/acpid-1.0.4-init.d index af33dd55ead2..a6272987f9c8 100644 --- a/sys-power/acpid/files/acpid-1.0.4-init.d +++ b/sys-power/acpid/files/acpid-1.0.4-init.d @@ -1,16 +1,16 @@ #!/sbin/runscript -# Copyright 1999-2005 Gentoo Foundation +# Copyright 1999-2006 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/sys-power/acpid/files/acpid-1.0.4-init.d,v 1.3 2006/01/09 16:58:33 brix Exp $ +# $Header: /var/cvsroot/gentoo-x86/sys-power/acpid/files/acpid-1.0.4-init.d,v 1.4 2006/08/20 04:16:44 vapier Exp $ -opts="${opts} reload" +opts="reload" depend() { need localmount } checkconfig() { - if [ ! -e /proc/acpi ]; then + if [[ ! -e /proc/acpi ]] ; then eerror "ACPI support has not been compiled into the kernel" return 1 fi @@ -20,19 +20,18 @@ start() { checkconfig || return 1 ebegin "Starting acpid" - start-stop-daemon --start --exec /usr/sbin/acpid -- \ - -c /etc/acpi/events - eend ${?} + acpid ${ACPID_OPTIONS} + eend $? } stop() { ebegin "Stopping acpid" start-stop-daemon --stop --exec /usr/sbin/acpid - eend ${?} + eend $? } reload() { ebegin "Reloading acpid configuration" - kill -HUP $(pidof /usr/sbin/acpid) > /dev/null 2>&1 - eend ${?} + killall -HUP acpid + eend $? } diff --git a/sys-power/acpid/files/acpid.conf.d b/sys-power/acpid/files/acpid.conf.d new file mode 100644 index 000000000000..0e394e67f295 --- /dev/null +++ b/sys-power/acpid/files/acpid.conf.d @@ -0,0 +1,6 @@ +# /etc/conf.d/acpid + +# Options to pass to the acpid daemon. +# See the acpid(8) man page for more info. + +ACPID_OPTIONS="" -- cgit v1.2.3-65-gdbad