Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 1549 - APMD does not compile using emerge apmd
Summary: APMD does not compile using emerge apmd
Status: RESOLVED DUPLICATE of bug 1472
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: x86 Linux
: High normal (vote)
Assignee: Daniel Robbins (RETIRED)
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2002-04-05 14:13 UTC by Richard Torkar
Modified: 2005-07-17 13:06 UTC (History)
4 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Richard Torkar 2002-04-05 14:13:28 UTC
I've done an "emerge --clean rsync" and then an "emerge apmd" and I get this:


root@wlan-3 root # emerge apmd
Calculating dependencies ...done!
>>> emerge sys-apps/apmd-3.0.2-r1 to /
>>> Unpacking source...
>>> Unpacking apmd-3.0.2.tar.gz
>>> Source unpacked.
gcc -c  -O2 -mcpu=i686 -pipe -Wall -pipe -I. -I/usr/src/linux/include
-I/usr/src/linux-2.2/include -I /usr/src/linux-2.0/include -DVERSION=\"3.0.2\"
-DAPMD_PROXY_NAME=\"/etc/apm/apmd_proxy\" apmlib.c
ar rv libapm.a apmlib.o
a - apmlib.o
ranlib libapm.a
gcc -c  -O2 -mcpu=i686 -pipe -Wall -pipe -I. -I/usr/src/linux/include
-I/usr/src/linux-2.2/include -I /usr/src/linux-2.0/include -DVERSION=\"3.0.2\"
-DAPMD_PROXY_NAME=\"/etc/apm/apmd_proxy\" apm.c
gcc -o apm apm.o  -L. -lapm
gcc -c  -O2 -mcpu=i686 -pipe -Wall -pipe -I. -I/usr/src/linux/include
-I/usr/src/linux-2.2/include -I /usr/src/linux-2.0/include -DVERSION=\"3.0.2\"
-DAPMD_PROXY_NAME=\"/etc/apm/apmd_proxy\" apmd.c
gcc -o apmd apmd.o  -L. -lapm
gcc -c  -O2 -mcpu=i686 -pipe -Wall -pipe -I. -I/usr/src/linux/include
-I/usr/src/linux-2.2/include -I /usr/src/linux-2.0/include -DVERSION=\"3.0.2\"
-DAPMD_PROXY_NAME=\"/etc/apm/apmd_proxy\" apmsleep.c
In file included from apmsleep.c:49:
/usr/src/linux/include/asm/spinlock.h: In function `spin_lock':
/usr/src/linux/include/asm/spinlock.h:137: parse error before `LOCK_SECTION_START'
/usr/src/linux/include/asm/spinlock.h: In function `read_lock':
/usr/src/linux/include/asm/spinlock.h:188: parse error before `LOCK_SECTION_START'
/usr/src/linux/include/asm/spinlock.h:188: warning: implicit declaration of
function `LOCK_SECTION_START'
/usr/src/linux/include/asm/spinlock.h:188: parse error before string constant
/usr/src/linux/include/asm/spinlock.h: In function `write_lock':
/usr/src/linux/include/asm/spinlock.h:197: parse error before `LOCK_SECTION_START'
/usr/src/linux/include/asm/spinlock.h:197: parse error before string constant
apmsleep.c: At top level:
apmsleep.c:64: warning: `rcsid' defined but not used
make: *** [apmsleep.o] Error 1
rm apm.o apmd.o

!!! ERROR: The ebuild did not complete successfully.
!!! Function src_compile, Line 2, Exitcode 2
!!! compile problem

!!! emerge aborting on  /usr/portage/sys-apps/apmd/apmd-3.0.2-r1.ebuild .
Comment 1 Vern Ceder 2002-04-05 15:53:06 UTC
I get the exact same problem. 
Kernel is 2.4.19 with apm section configured as follows:

CONFIG_PM=y
# CONFIG_ACPI is not set
CONFIG_APM=y
# CONFIG_APM_IGNORE_USER_SUSPEND is not set
CONFIG_APM_DO_ENABLE=y
CONFIG_APM_CPU_IDLE=y
CONFIG_APM_DISPLAY_BLANK=y
# CONFIG_APM_RTC_IS_GMT is not set
CONFIG_APM_ALLOW_INTS=y
# CONFIG_APM_REAL_MODE_POWER_OFF is not set
Comment 2 Daniel Robbins (RETIRED) gentoo-dev 2002-04-06 10:21:33 UTC
Try updating your linux *headers* to 2.4.19, and this problem should go away.
Comment 3 B. Allyn Fay 2002-04-09 23:26:26 UTC
This still occurs with 1.1a:

sys-kernel/linux-sources-2.4.19
sys-kernel/linux-headers-2.4.19 and 2.4.19-r1
(from 1.1 install)

and 

sys-kernel/linux-sources-2.4.19-r1
sys-kernel/linux-headers-2.4.18

which appear to be the latest unmasked combination
Comment 4 Dave Nellans 2002-04-10 18:43:26 UTC
I also have the exact same apmd error on a IBM Thinkpad 600e for which I have
gotten apmd working under different distros.  both my kernel source and kernel
headers appear to be 2.4.19-r1 according to emerge -s linux.  however the
kernel-headers still list 2.4.18 as the newest available while 2.4.19-r1 is
listed as installed.  My system as a whole is 1.1a or newer.
Comment 5 Robert Holak 2002-04-11 18:11:56 UTC
It seems like the linux-gentoo-2.4.19-r1.patch is adding the spinlock code into
the kernel source and that the spinlock code has some sort of bug going on.
Having the 2.4.18 headers package and the 2.4.19-r1 should not be a problem as
long as the 2.4.19-r1 is installed later, since the kernel source contains all
headers.
I am no kernel guru, so maybe someone familiar with the spinlock code can take a
look...
Comment 6 Daniel Robbins (RETIRED) gentoo-dev 2002-04-21 16:14:11 UTC

*** This bug has been marked as a duplicate of 1472 ***