[llvm-bugs] [Bug 35828] New: lld ignores /usr/lib/rcrt1.o crt file
via llvm-bugs
llvm-bugs at lists.llvm.org
Thu Jan 4 12:54:17 PST 2018
https://bugs.llvm.org/show_bug.cgi?id=35828
Bug ID: 35828
Summary: lld ignores /usr/lib/rcrt1.o crt file
Product: lld
Version: unspecified
Hardware: All
OS: Linux
Status: NEW
Severity: enhancement
Priority: P
Component: All Bugs
Assignee: unassignedbugs at nondot.org
Reporter: bjornpagen at gmail.com
CC: llvm-bugs at lists.llvm.org
In musl-1.1.10 and foward, musl provides rcrt1 in addition to crt{1,i,n}. This
new crt start file, rcrt1.o, is provided for producing static-linked position
independent executables (PIE). [1]
rcrt1.o is a dependency of musl, and musl will not compile unless it is able to
access the __dls2 function that is defined in it.
GNU linkers such as bfd and gold have added support for including this file,
and musl compiles with no issue. But when I tried to use lld as a drop in
replacement, the build fails, and the lld throws this error:
/usr/bin/x86_64-gentoo-linux-musl-ld: error: undefined symbol: __dls2
>>> referenced by ld-temp.o
>>> lto.tmp:(_dlstart_c)
clang-5.0: error: linker command failed with exit code 1 (use -v to see
invocation)
A couple grep -R's in lld's source code didn't reveal anything concerning
rcrt1, so I am assuming it has not been implemented yet.
lld version is 5.0.1
[1] https://www.musl-libc.org/oldversions.html
--
You are receiving this mail because:
You are on the CC list for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-bugs/attachments/20180104/5030278f/attachment.html>
More information about the llvm-bugs
mailing list