[PATCH] D51571: [Xray] Darwin providing defined value for weak symbols to fix linkage issue

David CARLIER via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Sun Sep 2 07:14:55 PDT 2018


devnexen added a comment.

"/usr/bin/ld" -demangle -lto_library /Users/devnexen/Contribs/LLVMbuild/lib/libLTO.dylib -no_deduplicate -dynamic -arch x86_64 -macosx_version_min 10.13.0 -o a.out -L/Users/devnexen/Contribs/TestSuite/ /var/folders/0y/qp64bhnx57x5gvjdr34k0jg80000gn/T/fdrmode-bench-3b0d58.o -lbenchmark -lc++ /Users/devnexen/Contribs/LLVMbuild/lib/clang/8.0.0/lib/darwin/libclang_rt.xray_osx.a /Users/devnexen/Contribs/LLVMbuild/lib/clang/8.0.0/lib/darwin/libclang_rt.xray-basic_osx.a /Users/devnexen/Contribs/LLVMbuild/lib/clang/8.0.0/lib/darwin/libclang_rt.xray-fdr_osx.a -lSystem /Users/devnexen/Contribs/LLVMbuild/lib/clang/8.0.0/lib/darwin/libclang_rt.osx.a
Undefined symbols for architecture x86_64:

  "___start_xray_fn_idx", referenced from:
      ___xray_init in libclang_rt.xray_osx.a(xray_init.cc.o)
  "___start_xray_instr_map", referenced from:
      ___xray_init in libclang_rt.xray_osx.a(xray_init.cc.o)
  "___stop_xray_fn_idx", referenced from:
      ___xray_init in libclang_rt.xray_osx.a(xray_init.cc.o)
  "___stop_xray_instr_map", referenced from:
      ___xray_init in libclang_rt.xray_osx.a(xray_init.cc.o)

ld: symbol(s) not found for architecture x86_64
clang-8: error: linker command failed with exit code 1 (use -v to see invocation)

Another apple folk reported me the issue as well.


Repository:
  rCRT Compiler Runtime

https://reviews.llvm.org/D51571





More information about the llvm-commits mailing list