[Lldb-commits] [lldb] [lldb-dap] Make lldbDAP an OBJECT library (NFC) (PR #196108)
Sergei Barannikov via lldb-commits
lldb-commits at lists.llvm.org
Wed May 6 17:49:35 PDT 2026
s-barannikov wrote:
Hi,
I started seeing linking errors like these when linking `liblldbDAP.so`:
```
ld.lld: error: undefined symbol: lldb::SBBreakpoint::SetCondition(char const*)
>>> referenced by Breakpoint.cpp
>>> tools/lldb/tools/lldb-dap/CMakeFiles/obj.lldbDAP.dir/Breakpoint.cpp.o:(lldb_dap::Breakpoint::SetCondition())
>>> referenced by ExceptionBreakpoint.cpp
>>> tools/lldb/tools/lldb-dap/CMakeFiles/obj.lldbDAP.dir/ExceptionBreakpoint.cpp.o:(lldb_dap::ExceptionBreakpoint::SetBreakpoint(llvm::StringRef))
ld.lld: error: undefined symbol: llvm::getAsUnsignedInteger(llvm::StringRef, unsigned int, unsigned long long&)
>>> referenced by Breakpoint.cpp
>>> tools/lldb/tools/lldb-dap/CMakeFiles/obj.lldbDAP.dir/Breakpoint.cpp.o:(lldb_dap::Breakpoint::SetHitCondition())
>>> referenced by ClientLauncher.cpp
>>> tools/lldb/tools/lldb-dap/CMakeFiles/obj.lldbDAP.dir/ClientLauncher.cpp.o:(llvm::support::detail::provider_format_adapter<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&>::format(llvm::raw_ostream&, llvm::StringRef))
>>> referenced by CommandPlugins.cpp
>>> tools/lldb/tools/lldb-dap/CMakeFiles/obj.lldbDAP.dir/CommandPlugins.cpp.o:(llvm::support::detail::provider_format_adapter<llvm::StringRef&>::format(llvm::raw_ostream&, llvm::StringRef))
>>> referenced 16 more times
```
I didn't try to bisect to a specific commit, but this one looks the most relevant. Can you confirm that `-DBUILD_SHARED_LIBS=ON` works on your side?
The host is Ubuntu-22.04, there is nothing special in CMake options, just lldb added to `-DLLVM_ENABLE_PROJECTS`.
https://github.com/llvm/llvm-project/pull/196108
More information about the lldb-commits
mailing list