[cfe-dev] Official Clang Ubuntu 13.10 x86_64 binary missing LLVMgold.so

邓尧 torshie at gmail.com
Wed Feb 12 21:57:36 PST 2014


File LLVMgold.so doesn't exist in the official binary, which causes
link-time-optimization to be unusable. Is this a bug or I invoked clang
incorrectly ? Here are the error messages:

ubuntu:/opt/clang$ echo 'int main() {}' | clang -xc - -flto -v
clang version 3.4 (tags/RELEASE_34/final)
Target: x86_64-unknown-linux-gnu
Thread model: posix
Found candidate GCC installation: /usr/lib/gcc/x86_64-linux-gnu/4.8
Found candidate GCC installation: /usr/lib/gcc/x86_64-linux-gnu/4.8.1
Selected GCC installation: /usr/lib/gcc/x86_64-linux-gnu/4.8
 "/opt/clang/bin/clang" -cc1 -triple x86_64-unknown-linux-gnu -emit-llvm-bc
-disable-free -disable-llvm-verifier -main-file-name - -mrelocation-model
static -mdisable-fp-elim -fmath-errno -masm-verbose -mconstructor-aliases
-munwind-tables -fuse-init-array -target-cpu x86-64 -target-linker-version
2.23.90.20131017 -v -resource-dir /opt/clang/bin/../lib/clang/3.4
-internal-isystem /usr/local/include -internal-isystem
/opt/clang/bin/../lib/clang/3.4/include -internal-externc-isystem
/usr/include/x86_64-linux-gnu -internal-externc-isystem /include
-internal-externc-isystem /usr/include -fdebug-compilation-dir /opt/clang
-ferror-limit 19 -fmessage-length 80 -mstackrealign -fobjc-runtime=gcc
-fdiagnostics-show-option -fcolor-diagnostics -vectorize-slp -o
/tmp/--84ea23.o -x c -
clang -cc1 version 3.4 based upon LLVM 3.4 default target
x86_64-unknown-linux-gnu
ignoring nonexistent directory "/include"
#include "..." search starts here:
#include <...> search starts here:
 /usr/local/include
 /opt/clang/bin/../lib/clang/3.4/include
 /usr/include/x86_64-linux-gnu
 /usr/include
End of search list.
 "/usr/bin/ld" -z relro --hash-style=gnu --build-id --eh-frame-hdr -m
elf_x86_64 -dynamic-linker /lib64/ld-linux-x86-64.so.2 -o a.out
/usr/lib/gcc/x86_64-linux-gnu/4.8/../../../x86_64-linux-gnu/crt1.o
/usr/lib/gcc/x86_64-linux-gnu/4.8/../../../x86_64-linux-gnu/crti.o
/usr/lib/gcc/x86_64-linux-gnu/4.8/crtbegin.o
-L/usr/lib/gcc/x86_64-linux-gnu/4.8
-L/usr/lib/gcc/x86_64-linux-gnu/4.8/../../../x86_64-linux-gnu
-L/lib/x86_64-linux-gnu -L/lib/../lib64 -L/usr/lib/x86_64-linux-gnu
-L/usr/lib/gcc/x86_64-linux-gnu/4.8/../../.. -L/lib -L/usr/lib -plugin
/opt/clang/bin/../lib/LLVMgold.so -plugin-opt=mcpu=x86-64 /tmp/--84ea23.o
-lgcc --as-needed -lgcc_s --no-as-needed -lc -lgcc --as-needed -lgcc_s
--no-as-needed /usr/lib/gcc/x86_64-linux-gnu/4.8/crtend.o
/usr/lib/gcc/x86_64-linux-gnu/4.8/../../../x86_64-linux-gnu/crtn.o
/usr/bin/ld: /opt/clang/bin/../lib/LLVMgold.so: error loading plugin:
/opt/clang/bin/../lib/LLVMgold.so: cannot open shared object file: No such
file or directory
clang: error: linker command failed with exit code 1 (use -v to see
invocation)
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/cfe-dev/attachments/20140213/8321fc28/attachment.html>


More information about the cfe-dev mailing list