https://sourceware.org/bugzilla/show_bug.cgi?id=20513
Bug ID: 20513 Summary: GNU ld does not ignore symbols defined in sections marked EXCLUDE Product: binutils Version: 2.26 Status: NEW Severity: normal Priority: P2 Component: ld Assignee: unassigned at sourceware dot org Reporter: rguenth at gcc dot gnu.org Target Milestone: --- When linking two object files, one with a definition of symbol FOO and one with a definition of symbol FOO in a section marked with SHF_EXCLUDE then GNU ld complains about 'multiple definitions of 'FOO''. GOLD handles this situation just fine. t1.s: .text .section .text.startup,"ax",@progbits .p2align 4,,15 .globl main .type main, @function main: t2.s: .text .section .text.startup,"axe",@progbits .p2align 4,,15 .globl main .type main, @function main: (ignore assembler warnings about bogus section attributes) > ld t1.o t2.o -o a.out t2.o: In function `main': (.text.startup+0x0): multiple definition of `main' t1.o:(.text.startup+0x0): first defined here > gold t1.o t2.o -o a.out -- You are receiving this mail because: You are on the CC list for the bug. _______________________________________________ bug-binutils mailing list bug-binutils@gnu.org https://lists.gnu.org/mailman/listinfo/bug-binutils