Re: shutting down mac mini
On 4/25/05, Johannes Berg <johannes@sipsolutions.net> wrote:
> On Mon, 2005-04-25 at 11:18 -0400, Charles Lepple wrote:
>
> > This looks like it'll work for the G4 Cube as well (it is identified
> > as a Core99 machine, PMU version 12). I'll try it when I get home from
> > work.
> >
> > For reference, /dev/pmu was returning two-byte packets for each press
> > and release of the power button (0x40 0x0d and 0x40 0x05,
> > respectively).
>
> Yeah, it should work as well then.
Did I miss something, or is there no generic "map this key to a
script" configuration item?
I figured I could assign it to SleepKey:
SleepKey = pmupowerbutton
SleepKeyDelay = 0
but I don't see anything in the logs that would indicate that
/etc/power/pmcs-pbbuttonsd is being called. I'll try adding some debug
printfs later. (BTW, what is the recommended way to set
CFLAGS+=-DDEBUG when rebuilding a .deb? Or should I just manually
compile from source, now that apt-src fetched all the dependencies?)
(Note that the kernel (Debian's 2.6.10) does not support actual
sleeping on this hardware; I'm just trying to map the power button to
a safe shutdown routine.)
--
- Charles Lepple
Reply to: