https://sourceware.org/bugzilla/show_bug.cgi?id=23818
Bug ID: 23818 Summary: Symbols from discarded section in IR object leaked into final executable Product: binutils Version: 2.32 (HEAD) Status: NEW Severity: normal Priority: P2 Component: ld Assignee: unassigned at sourceware dot org Reporter: hjl.tools at gmail dot com Target Milestone: --- [hjl@gnu-efi-2 pr87698]$ cat test.c void foo () { } [hjl@gnu-efi-2 pr87698]$ cat test2.c void foo (void); void bar (void) { foo (); } [hjl@gnu-efi-2 pr87698]$ cat x.t { local: *; }; [hjl@gnu-efi-2 pr87698]$ make gcc -flto -ffat-lto-objects -fPIC -O2 -g -c -o test.o test.c gcc -flto -ffat-lto-objects -fPIC -O2 -g -c -o test2.o test2.c gcc -shared -o x.so test.o test2.o -Wl,--version-script,x.t readelf -sW x.so | grep foo 5: 0000000000000000 0 NOTYPE GLOBAL DEFAULT ABS foo [hjl@gnu-efi-2 pr87698]$ -- 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