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

Rui Ueyama via llvm-dev llvm-dev at lists.llvm.org
Tue Feb 21 10:07:13 PST 2017


Did you try to make a smaller test case? I'd try to remove unrelated code
from your project to minimize the code size so that it is easy to find a
cause.

On Tue, Feb 21, 2017 at 5:10 AM, Carlo Kok via llvm-dev <
llvm-dev at lists.llvm.org> wrote:

> 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.im
> portlib-ConsoleApplication347-libc.so" "RemObjects.Elements.Cirrus.im
> portlib-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
> _______________________________________________
> LLVM Developers mailing list
> llvm-dev at lists.llvm.org
> http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-dev
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20170221/eab512c3/attachment.html>


More information about the llvm-dev mailing list