X-Git-Url: http://gitweb.hugovil.com/?a=blobdiff_plain;f=stage2%2Fpkg%2Facpid;h=aff49604732bcd53074c654575d77c34d4f85c65;hb=3a7685561df0a4d80e727e5b26fbf413ad0586f2;hp=8eabe5a70f00f7e055383a367af763c96a55d2f7;hpb=785f43b4dd400fff43b9fa169fded7fef7c9025e;p=hvlinux.git diff --git a/stage2/pkg/acpid b/stage2/pkg/acpid index 8eabe5a..aff4960 100644 --- a/stage2/pkg/acpid +++ b/stage2/pkg/acpid @@ -4,14 +4,20 @@ hvbuild_post() { install -d -m755 /etc/acpi/events - cat > /etc/acpi/events/s2ram << EOF -# When a button/power event is received, the hvs2ram script is run. + cat > /etc/acpi/events/button-lid << EOF +# When the lid is closed, go into suspend to ram +event=button/lid +action=/etc/acpi/suspend2ram.sh +EOF + cat > /etc/acpi/events/button-power << EOF +# When the power button is pressed, shutdown the system. event=button/power -action=/usr/local/bin/hvs2ram +action=/etc/acpi/shutdown.sh EOF - install -m755 ${SCRDIR}/misc/hvs2ram /usr/local/bin + install -v -m755 ${SCRDIR}/misc/acpi/suspend2ram.sh /etc/acpi + install -v -m755 ${SCRDIR}/misc/acpi/shutdown.sh /etc/acpi install -v -m740 ${SCRDIR}/bootscripts/acpid /etc/rc.d/init.d bootscript_add_rcsysinit acpid 65 90