[prev in list] [next in list] [prev in thread] [next in thread]
List: binutils-bugs
Subject: [Bug ld/25593] New: --as-needed breaks DT_NEEDED order with linker plugin
From: "rguenth at gcc dot gnu.org" <sourceware-bugzilla () sourceware ! org>
Date: 2020-02-24 12:18:24
Message-ID: bug-25593-70 () http ! sourceware ! org/bugzilla/
[Download RAW message or body]
https://sourceware.org/bugzilla/show_bug.cgi?id=25593
Bug ID: 25593
Summary: --as-needed breaks DT_NEEDED order with linker plugin
Product: binutils
Version: 2.33
Status: NEW
Severity: normal
Priority: P2
Component: ld
Assignee: unassigned at sourceware dot org
Reporter: rguenth at gcc dot gnu.org
Target Milestone: ---
echo 'void foo() {}' > libt.c
echo 'void foo(); int main() { foo(); }' > t.c
gcc -o libt.so -shared libt.c -Wl,-soname,libt.so -fPIC -flto
gcc -c t.c -flto
gcc -Wl,--as-needed t.o libt.so
readelf -d a.out | grep NEEDED
0x0000000000000001 (NEEDED) Shared library: [libc.so.6]
0x0000000000000001 (NEEDED) Shared library: [libt.so]
but libc has to come last so the program can use RTLD_NEXT to arrive at
symbols from libc. Works fine with gold.
--
You are receiving this mail because:
You are on the CC list for the bug.
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic