LD .tmp_vmlinux1 ld: error: invalid assignment to dot outside of SECTIONS ld: error: invalid assignment to dot outside of SECTIONS ld: internal error in convert_types, at ../../gold/gold.h:294 make: *** [.tmp_vmlinux1] Error 1
This may be fixed now. Please let me know if it is not.
Not fixed. [bero@ebertswil linux-2.6.31]$ ld --version GNU gold (Linux/GNU Binutils 2.20.51.0.2.20091009) 1.9 Copyright 2008 Free Software Foundation, Inc. This program is free software; you may redistribute it under the terms of the GNU General Public License version 3 or (at your option) a later version. This program has absolutely no warranty. [bero@ebertswil linux-2.6.31]$ make 2>&1 |tail -n 5 LD .tmp_vmlinux1 ld: error: invalid assignment to dot outside of SECTIONS ld: error: invalid assignment to dot outside of SECTIONS ld: internal error in convert_types, at ../../gold/gold.h:294 make: *** [.tmp_vmlinux1] Error 1
Fixed in the 2.20 release here.
Bernhard: you were not using the current linker sources.
Hmm, right, the kernel.org version seems to be rather out of sync with gold (odd, given it's supposed to be synced)... 2.20 doesn't compile with the options I'm using, but that's a separate issue, will open a new bug for that
Hi, I have already reported that issue to LKML [1] and am still in conversion with Ian. Leaving out "--emit-relocs" or unsetting CONFIG_RELOCATABLE kernel-config variable let gold compile Linux-2.6.31-rc5-git3. This weekend I could track down the problem to (with binutils-cvs20091017): GOOD: 2.6.29-rc8 and 2.6.30 BAD: upstream (up-to 2.6.32-rc5-git1), 2.6.31, 2.6.31-{rc5..rc1} If you look at the kernel-sources the "incompatibility" arosed between 2.6.30 and the merge-window resulted in 2.6.31-rc1. With upstream kernel, (un)setting CONFIG_RELOCATABLE and binutils-2.20.51 snapshot tarball from 21-Oct-2009 gold still fails: ... LD drivers/built-in.o LD vmlinux.o MODPOST vmlinux.o WARNING: vmlinux.o(.devinit.text+0x387c): Section mismatch in reference from the function ezx_pcap_probe() to the function .init.text:set_irq_noprobe() The function __devinit ezx_pcap_probe() references a function __init set_irq_noprobe(). If set_irq_noprobe is only used by ezx_pcap_probe then annotate set_irq_noprobe with a matching annotation. GEN .version CHK include/generated/compile.h UPD include/generated/compile.h CC init/version.o LD init/built-in.o LD .tmp_vmlinux1 ld: internal error in convert_types, at ../../gold/gold.h:294 make[3]: *** [.tmp_vmlinux1] Error 1 ... Also the binutils-gold (2.20-1) package from Debian/sid fails. I prepared an archive with all involved input files, see [3]. Hope this get fixed, soon. IMHO, it would be a good idea to get in contact with the responsible maintainers in Linux-kernel. The bug is *NOT* fixed. - Sedat - [1] [binutils-gold][2.6.31-rc5-git3] ld error w/ LDFLAGS_vmlinux := --emit-reloc (CONFIG_RELOCATABLE=y) http://lkml.org/lkml/2009/8/5/288 [2] ftp://sourceware.org/pub/binutils/snapshots/binutils-2.20.51.tar.bz2 [3] http://files.iniza.org/for_iant/
For the sake of completeness: In [1] is the web-link to the patch to gold Ian mentionned in "Additional Comment #1". [1] gold patch committed: Permit assignment to dot outside of SECTIONS http://sourceware.org/ml/binutils/2009-10/msg00333.html
I put my latest kernel dot-config file and the build-log on [1]. [1] http://files.iniza.org/for_iant/build-with-binutils-2.20.51.20091021/
Eliminating "--emit-relocs" or unsetting CONFIG_RELOCATABLE in kernel-config does not fix it, too. This is the "ld-line", if you want to try it manually (here: for i386): ld -m elf_i386 --emit-relocs --build-id -X -o .tmp_vmlinux1 -T arch/x86/kernel/vmlinux.lds arch/x86/kernel/head_32.o arch/x86/kernel/head32.o arch/x86/kernel/head.o arch/x86/kernel/init_task.o init/built-in.o --start-group usr/built-in.o arch/x86/built-in.o kernel/built-in.o mm/built-in.o fs/built-in.o ipc/built-in.o security/built-in.o crypto/built-in.o block/built-in.o lib/lib.a arch/x86/lib/lib.a lib/built-in.o arch/x86/lib/built-in.o drivers/built-in.o sound/built-in.o firmware/built-in.o arch/x86/pci/built-in.o arch/x86/power/built-in.o arch/x86/video/built-in.o net/built-in.o --end-group