From Bugzilla Helper:
User-Agent: Mozilla/5.0 (X11; U; Linux 2.2.18 i686; en-US; 0.8.1)
I have the following packages:
When I am building a 2.2.18 or 2.2.19 kernel with aic7xxx support, it bombs
at the end and says something like scsis.a(aic7xxx.o): in
aic7xxx_load_seeprom -- undefined reference to "memcpy"
There is not a memcpy in that function, and the kernel builds fine in linux
which has the following egcs related files:
Steps to Reproduce:
1.run up2date -u on RH7.0 and get all updates
2.download kernel 2.2.19 from kernel.org
3.configure kernel with aic7xxx driver
4. make dep; make bzImage -- and it fails
Actual Results: all the build messages are fine, at the end when
everything is put together:
cc -D__KERNEL__ -I/usr/src/linux/include -E -C -P -I/usr/src/linux/include
-imacros /usr/src/linux/include/asm-i386/page_offset.h -Ui386
ld -m elf_i386 -T /usr/src/linux/arch/i386/vmlinux.lds -e stext
arch/i386/kernel/head.o arch/i386/kernel/init_task.o init/main.o
arch/i386/kernel/kernel.o arch/i386/mm/mm.o kernel/kernel.o mm/mm.o fs/fs.o
drivers/block/block.a drivers/char/char.o drivers/misc/misc.a
drivers/net/net.a drivers/scsi/scsi.a drivers/cdrom/cdrom.a
drivers/pci/pci.a drivers/video/video.a \
drivers/scsi/scsi.a(aic7xxx.o): In function `aic7xxx_load_seeprom':
aic7xxx.o(.text+0x117cf): undefined reference to `memcpy'
make: *** [vmlinux] Error 1
Expected Results: Should have built correctly.
I don't think this a problem with the kernel, because it builds under egcs
in 6.2. It could have to do with the binutils since it's calling ld ..
Important because 2.2.19 fixes some security issues and people wh use
custom kernels cannot upgrade.
2.2.x kernels (unless patched) should be built with kgcc compiler.
2.2.18/2.2.19 Makefile already looks if kgcc is present in the $PATH, so it looks
like you don't have kgcc package installed.
memcpy is generated internally by gcc for structure copies, it is kernel's
fault that it is not exporting memcpy and relying gcc on always expanding
even huge memcpys inline (which gcc does for small copies but not when it
generates too big code). 2.4.x kernels already export memcpy/memset even
on ia32 architecture.