bug-binutils
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Bug ld/11218] --gc-sections does not detect unresolved symbol


From: hjl dot tools at gmail dot com
Subject: [Bug ld/11218] --gc-sections does not detect unresolved symbol
Date: 25 Jan 2010 14:26:07 -0000

------- Additional Comments From hjl dot tools at gmail dot com  2010-01-25 
14:26 -------
Created an attachment (id=4554)
 --> (http://sourceware.org/bugzilla/attachment.cgi?id=4554&action=view)
A testcase

address@hidden gc-2]$ make
gcc -B./ -c -o main.o main.c
gcc -B./ -c -ffunction-sections -o a.o a.c
gcc -B./ -o so.so -shared -fPIC so.c
gcc -B./ -o main main.o a.o so.so -Wl,--gc-sections,-rpath,./
gcc -B./ -o foo main.o a.o so.so -Wl,-rpath,./
a.o: In function `call_unresolved':
a.c:(.text.call_unresolved+0xa): undefined reference to
`unresolved_detected_at_runtime_not_at_linktime'
collect2: ld returned 1 exit status
make: *** [foo] Error 1
address@hidden gc-2]$ ./main
./main: symbol lookup error: ./so.so: undefined symbol:
unresolved_detected_at_runtime_not_at_linktime
address@hidden gc-2]$ 

-- 


http://sourceware.org/bugzilla/show_bug.cgi?id=11218

------- You are receiving this mail because: -------
You are on the CC list for the bug, or are watching someone who is.




reply via email to

[Prev in Thread] Current Thread [Next in Thread]