[Lldb-commits] [PATCH] D142241: Don't use CLANG_LIBS and LINK_COMPONENTS in lldb/tools/lldb-instr/CMakeLists.txt

Heejin Ahn via Phabricator via lldb-commits lldb-commits at lists.llvm.org
Thu Feb 9 12:23:44 PST 2023


aheejin added a comment.

This broke `-sBUILD_SHARED_LIBS=ON` build:

  ld.lld: error: undefined symbol: llvm::errs()
  >>> referenced by Instrument.cpp:162 (/usr/local/google/home/aheejin/llvm-git/lldb/tools/lldb-instr/Instrument.cpp:162)
  >>>               tools/lldb/tools/lldb-instr/CMakeFiles/lldb-instr.dir/Instrument.cpp.o:(main)
  
  ld.lld: error: undefined symbol: llvm::vfs::getRealFileSystem()
  >>> referenced by Instrument.cpp:171 (/usr/local/google/home/aheejin/llvm-git/lldb/tools/lldb-instr/Instrument.cpp:171)
  >>>               tools/lldb/tools/lldb-instr/CMakeFiles/lldb-instr.dir/Instrument.cpp.o:(main)
  
  ...
  ...

Is using `CLANG_LIBS` and `LINK_COMPONENTS Supportt` in the same file a problem? There are many files that use both:

  ./lldb/source/Core/CMakeLists.txt
  ./lldb/source/Plugins/TypeSystem/Clang/CMakeLists.txt
  ./lldb/source/Plugins/LanguageRuntime/ObjC/AppleObjCRuntime/CMakeLists.txt
  ./lldb/source/Plugins/LanguageRuntime/RenderScript/RenderScriptRuntime/CMakeLists.txt
  ./lldb/source/Plugins/ExpressionParser/Clang/CMakeLists.txt
  ./lldb/source/Plugins/Platform/MacOSX/CMakeLists.txt
  ./lldb/source/Plugins/SymbolFile/DWARF/CMakeLists.txt
  ./lldb/source/Plugins/SymbolFile/NativePDB/CMakeLists.txt
  ./lldb/source/Plugins/SymbolFile/PDB/CMakeLists.txt


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D142241/new/

https://reviews.llvm.org/D142241



More information about the lldb-commits mailing list