[llvm-dev] [lld] elf linker creates undefined empty symbol

Carlo Kok via llvm-dev llvm-dev at lists.llvm.org
Tue Feb 21 05:10:46 PST 2017


Hi,

When running my own lld generated library/executable I'm getting:

LD_LIBRARY_PATH=. ./ConsoleApplication347
./ConsoleApplication347: symbol lookup error: ./ConsoleApplication347: 
undefined symbol:

(theres nothing after undefined symbol)

How can I figure out what's I'm doing wrong?

Full log:
https://gist.github.com/carlokok/1dd510a16e1922271b520f1c00b14656

readelf -s for ConsoleApplication347:
https://gist.github.com/carlokok/0950e4b33e0bf421852b3ac58fc18aea

readelf -s for ClassLibrary22.so:
https://gist.github.com/carlokok/109a03620abb95bdad6479426e3dce11


lld command line used:
lld -flavor gnu -O0 --lto-O0
--eh-frame-hdr --dynamic-linker "/lib64/ld-linux-x86-64.so.2"
"-L."
"-oConsoleApplication347"
"RemObjects.Elements.Cirrus.ConsoleApplication347.o"
"libgc.a" "Island.a" 
"RemObjects.Elements.Cirrus.importlib-ConsoleApplication347-libc.so" 
"RemObjects.Elements.Cirrus.importlib-ConsoleApplication347-ClassLibrary22" 
"RemObjects.Elements.Cirrus.importlib-ConsoleApplication347-libpthread.so" 
"RemObjects.Elements.Cirrus.importlib-ConsoleApplication347-librt.so" 
"RemObjects.Elements.Cirrus.importlib-ConsoleApplication347-libgcc_s.so"


Input files:
https://www.dropbox.com/s/8yn3dggx05atn47/binLinux.zip?dl=0


output files:
https://www.dropbox.com/s/vxzl9jfkssmp3tk/testapp.zip?dl=0

-- 
Carlo Kok
RemObjects Software


More information about the llvm-dev mailing list