On Fri, 11 Nov 2005, Paul wrote:
On Thursday 10 November 2005 22:43, Dan Hatton wrote:
I mentioned this in passing in a thread last week, so apologies to anyone who's heard it before: I'd like idle-timer-based power management on my FC4 machine, but can't get sleepd 1.2.14 to compile. Can anyone suggest how to make it work, please?
FC4 - Hrmmm.. Doesn't that release ship with gcc-4. ?
4.0.1, to be precise.
Correct me if I'm wrong, but sleepd is a user space application, not a kernel module. Therefore, you should not be using includes from the kernel tree, only the ones from /usr/include/ (and any headers in the sleepd tarball).
OK, so I should be limiting myself to using the apm.h and acpi.h provided by sleepd or the apm.h from libapm-dev.
Something appears to be screwed here... Downloading and grepping the sleepd sources reveals a couple of problems that may cause "issues"... The first line in sleepd's apm.h reads "#include <apm.h>"... Do you have libapm-devel installed on your system ?
There doesn't seem to be an equivalent to libapm-dev on Fedora, so I pulled the apm.h file out of the Debian one, and put it in /usr/include.
Once this was done, "make" failed with
cc -o sleepd sleepd.o acpi.o -lapm /usr/bin/ld: cannot find -lapm collect2: ld returned 1 exit status make: *** [sleepd] Error 1
no matter what combination of CPATH and LIBRARY_PATH I used.
I've got a sort of feeling the arguments of that "cc" command might be in the wrong order. Can anyone confirm this and/or suggest the right order, please?