https://llvm.org/bugs/show_bug.cgi?id=31354
Bug ID: 31354 Summary: [ELF] - duplicate symbol error when linking some FreeBSD ports. Product: lld Version: unspecified Hardware: PC OS: Windows NT Status: NEW Severity: normal Priority: P Component: ELF Assignee: unassignedb...@nondot.org Reporter: gri...@accesssoftek.com CC: llvm-bugs@lists.llvm.org Classification: Unclassified Created attachment 17749 --> https://llvm.org/bugs/attachment.cgi?id=17749&action=edit repro Noticed that when linked ports/sysutils/safecat-1.13 and I think I saw the same in few other ports. Error was: /usr/bin/ld: error: byte_copy.c:(.text+0x0): duplicate symbol 'byte_copy' /usr/bin/ld: error: byte_copy.c:(function byte_copy): previous definition was here Reproduce file (attached) can be reduced to: -o safecat usr/ports/sysutils/safecat/work/safecat-1.13/str.a usr/ports/sysutils/safecat/work/safecat-1.13/alloc_re.o usr/ports/sysutils/safecat/work/safecat-1.13/byte_copy.o and problem is that str.a contains byte_copy.o: ./makelib str.a str_len.o byte_chr.o byte_diff.o byte_copy.o byte_cr.o byte_zero.o and has next symbol: 'byte_copy' So LLD first creates lazy symbol 'byte_copy', then finds undefined 'byte_copy' in alloc_re.o and resolves it. At the end it reports duplicate symbol from byte_copy.o. Do we want to fix it ? -- You are receiving this mail because: You are on the CC list for the bug.
_______________________________________________ llvm-bugs mailing list llvm-bugs@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-bugs