ld linker error with 2.4.34 and 2.4.35.3
Posted: Tue Oct 23, 2007 7:37 am
Hello,
This is from vanilla 2.4.34 kernel patched with grsecurity:
Same problem with 2.4.35.3 and grsecurity-2.1.11-2.4.35.3-200710101250.patch
Vanilla kernel compiles ok. There was no problem some moths ago so it is probably because of change in ld.
gcc (GCC) 3.4.6 (Gentoo Hardened 3.4.6-r2, ssp-3.4.6-1.0, pie-8.7.10)
GNU ld (GNU Binutils) 2.18
glibc 2.5
Regards
This is from vanilla 2.4.34 kernel patched with grsecurity:
- Code: Select all
gcc -E -C -P -I/usr/src/linux-2.4.34/include -D__KERNEL__ -imacros /usr/src/linux-2.4.34/include/linux/config.h -imacros /usr/src/linux-2.4.34/include/asm-i386/segment.h -imacros /usr/src/linux-2.4.34/include/asm-i386/page.h -Ui386 arch/i386/vmlinux.lds.S >arch/i386/vmlinux.lds
ld -m elf_i386 -T /usr/src/linux-2.4.34/arch/i386/vmlinux.lds -e stext arch/i386/kernel/head.o arch/i386/kernel/init_task.o init/main.o init/version.o init/do_mounts.o \
--start-group \
arch/i386/kernel/kernel.o arch/i386/mm/mm.o kernel/kernel.o mm/mm.o fs/fs.o ipc/ipc.o \
drivers/acpi/acpi.o drivers/char/char.o drivers/block/block.o drivers/misc/misc.o drivers/net/net.o drivers/atm/atm.o drivers/ide/idedriver.o drivers/cdrom/driver.o drivers/pci/driver.o drivers/i2c/i2c.o drivers/video/video.o drivers/usb/usbdrv.o drivers/media/media.o crypto/crypto.o \
net/network.o \
grsecurity/grsec.o \
/usr/src/linux-2.4.34/arch/i386/lib/lib.a /usr/src/linux-2.4.34/lib/lib.a /usr/src/linux-2.4.34/arch/i386/lib/lib.a \
--end-group \
-o vmlinux
ld: vmlinux: section `.text' can't be allocated in segment 1
ld: final link failed: Bad value
make: *** [vmlinux] Error 1
Same problem with 2.4.35.3 and grsecurity-2.1.11-2.4.35.3-200710101250.patch
Vanilla kernel compiles ok. There was no problem some moths ago so it is probably because of change in ld.
gcc (GCC) 3.4.6 (Gentoo Hardened 3.4.6-r2, ssp-3.4.6-1.0, pie-8.7.10)
GNU ld (GNU Binutils) 2.18
glibc 2.5
Regards