On Thu, Sep 02, 2010 at 01:25:11PM +0800, 徐超 wrote: > > Recently, I update the toolchain(binutils 2.20.1) I meet one issue > on LD. > When I use LD to link the object with options “–oformat binary “ > and “--start-group –end-group” simultaneously, > LD fail to find the symbol. > > When I remove “—oformat”, it can build the ELF file. I try to write some > simple case to reproduce it, but in the simple > Case, it is OK. > (host i686-pc-linux-gnu target i686-cm-linux) > > The log file is as follow: > Linking: elf/rom.bin > ../..//lib/elf/libcore.a(bios_keybd.o): In function `biosKeybdShiftStatus': > bios_keybd.c:(.text+0x67): undefined reference to > `kbdmgrGetShiftFlagStatusByte' > ../..//lib/elf/libcore.a(bios_keybd.o): In function > `biosKeybdExtendedShiftStatus': > bios_keybd.c:(.text+0x8b): undefined reference to > `kbdmgrGetShiftFlagStatusByte' > I use readelf and objdump to check the symbol, the symbol can be > found in the libcore.a. > At the same time the LD (2.17.50, 2.18.50) both can work under this > situation. > So it should be bug.
What happens if you do not use an archive? ie. extract the files in the archive then specify all of them on the ld command line? -- Alan Modra Australia Development Lab, IBM _______________________________________________ bug-binutils mailing list bug-binutils@gnu.org http://lists.gnu.org/mailman/listinfo/bug-binutils