Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 118324 - genkernel-3.3.10 fails on klibc
Summary: genkernel-3.3.10 fails on klibc
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: PPC Linux
: High normal (vote)
Assignee: Gentoo Genkernel Maintainers
URL:
Whiteboard:
Keywords: InVCS
Depends on:
Blocks:
 
Reported: 2006-01-08 13:53 UTC by Lars Weiler (RETIRED)
Modified: 2006-01-11 18:23 UTC (History)
1 user (show)

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


Attachments
gen_compile.sh for ppc and klibc-1.1.16 (gen_compile.sh.patch,1.31 KB, patch)
2006-01-08 14:48 UTC, Lars Weiler (RETIRED)
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Lars Weiler (RETIRED) gentoo-dev 2006-01-08 13:53:36 UTC
Using the internal klibc in genkernel-3.3.10 on ppc with gentoo-sources-2.6.15, it fails with

gcc -Wp,-MT,fork.o,-MD,./.fork.o.d -Os  -D__KLIBC__=1 -D__KLIBC_MINOR__=1 -nostdlib -nostdinc -iwithprefix include -I../include
/arch/ppc -I../include/bits32 -I../include -I../linux/include -I../linux/include2 -I../linux/include -I../linux/arch/ppc/includ
e -I./zlib -I./zlib -DWITH_ERRLIST -W -Wall -Wpointer-arith -Wwrite-strings -Wstrict-prototypes -Winline -DDYNAMIC_CRC_TABLE -c
 -o fork.o fork.c
In file included from ../include/signal.h:13,
                 from fork.c:9:
../linux/arch/ppc/include/asm/signal.h:14: error: `BITS_PER_LONG' undeclared here (not in a function)
make[1]: *** [fork.o] Error 1
make[1]: Leaving directory `/var/tmp/genkernel/17907.14213.32028.8277/klibc-1.1.1/klibc'
make: *** [all] Error 2

There is already a patch for this error in klibc's git: http://www.kernel.org/git/?p=libs/klibc/klibc.git;a=commitdiff;h=dc6694ab699720c9e3519c5a98afd160f04a6fdc

Okay, this patch kills this error, but there is another now.

After that I tried with klibc-1.1.16 (testing-branch), but this gives me errors (but others) as well.  Instead of trying to fix klibc-1.1.1, I'll have a deeper look into the 1.1.16-errors.

This bug has been written to track the error and just let you genkernel-guys know ;)  Any hints appreciated!
Comment 1 Lars Weiler (RETIRED) gentoo-dev 2006-01-08 14:46:00 UTC
klibc-1.1.16 works, but gen_compile.sh needs some changes (as the make-environment in klibc changed).  Now udev spits out a lot of warnings related to klibc, but in the end it could be installed.

Have a look on the attached changes to gen_compile.sh
Comment 2 Lars Weiler (RETIRED) gentoo-dev 2006-01-08 14:48:37 UTC
Created attachment 76555 [details, diff]
gen_compile.sh for ppc and klibc-1.1.16
Comment 3 Benny Pedersen 2006-01-08 19:27:02 UTC
is that only related to ppc ?

used 3.3.10 gives me the samme error with klibc on amd64
Comment 4 Benny Pedersen 2006-01-08 20:05:40 UTC
seems genkernel 3.3.6 is lost in portage :(

can we have it back please ?
Comment 5 Chris Gianelloni (RETIRED) gentoo-dev 2006-01-11 15:23:32 UTC
I have added genkernel 3.3.11_pre1 into the tree with this patch.  Once I verify that it doesn't blow up on x86/amd64, I'll add it to genkernel CVS (we're being cautious this close to release)...
Comment 6 Chris Gianelloni (RETIRED) gentoo-dev 2006-01-11 17:48:38 UTC
Failed on x86...

# genkernel --kernel-config=/root/livecd/kconfig/2005.1/x86/installcd-2.6.15.config --kerneldir=/usr/src/linux-2.6.15-gentoo all
* Gentoo Linux Genkernel; Version 3.3.11_pre1
* Running with options: --kernel-config=/root/livecd/kconfig/2005.1/x86/installcd-2.6.15.config --kerneldir=/usr/src/linux-2.6.15-gentoo all

* Linux Kernel 2.6.15-gentoo for x86...
* kernel: >> Running mrproper...
* config: Using config from /root/livecd/kconfig/2005.1/x86/installcd-2.6.15.config
*         Previous config backed up to .config.bak
*         >> Running oldconfig...
* kernel: >> Cleaning...
*         >> Compiling 2.6.15-gentoo bzImage...
*         >> Compiling 2.6.15-gentoo modules...
* Copying config for successful build to /etc/kernels/kernel-config-x86-2.6.15-gentoo
* klibc: >> Compiling...
* udev: >> Compiling...
* ERROR: Failed to compile the "EXTRAS="extras/scsi_id extras/volume_id extras/ata_id extras/run_directory extras/usb_id extras/floppy extras/cdrom_id extras/firmware" USE_KLIBC=true KLCC=/var/tmp/genkernel/31596.31391.5911.25283/klibc-build/bin/klcc USE_LOG=false DEBUG=false udevdir=/dev all" target...

* -- Grepping log... --

<---SNIP--->

ar cq libudev.a udev_event.o udev_device.o udev_config.o udev_add.o udev_remove.o udev_db.o udev_rules.o udev_rules_parse.o udev_utils.o udev_utils_string.o udev_utils_file.o udev_utils_run.o udev_libc_wrapper.o
ranlib libudev.a
ld -Wl,-warn-common udev.o -o udev libudev.a libsysfs/libsysfs.a
ld: unrecognized option '-Wl,-warn-common'
ld: use the --help option for usage information
make: *** [udev] Error 1
* Gentoo Linux Genkernel; Version 3.3.11_pre1
* Running with options: --kernel-config=/root/livecd/kconfig/2005.1/x86/installcd-2.6.15.config --kerneldir=/usr/src/linux-2.6.15-gentoo all

* ERROR: Failed to compile the "EXTRAS="extras/scsi_id extras/volume_id extras/ata_id extras/run_directory extras/usb_id extras/floppy extras/cdrom_id extras/firmware" USE_KLIBC=true KLCC=/var/tmp/genkernel/31596.31391.5911.25283/klibc-build/bin/klcc USE_LOG=false DEBUG=false udevdir=/dev all" target...

* -- End log... --
Comment 7 Chris Gianelloni (RETIRED) gentoo-dev 2006-01-11 18:20:45 UTC
OK, so I reverted the above patch and changed my /etc/genkernel.conf to use klibc-1.1.1 (and added back byteswap.h) and got the *exact* same error on compiling, which leads me to believe that it is not related to the above patch.
Comment 8 Chris Gianelloni (RETIRED) gentoo-dev 2006-01-11 18:23:29 UTC
I've added this to CVS and it is in 3.3.11_pre1+ so you shouldn't have any problems.  Now, I just need to resolve the issue with x86 compilation, but it doesn't appear to be related.