diff --git a/lldb/cmake/modules/LLDBFramework.cmake b/lldb/cmake/modules/LLDBFramework.cmake --- a/lldb/cmake/modules/LLDBFramework.cmake +++ b/lldb/cmake/modules/LLDBFramework.cmake @@ -120,3 +120,7 @@ COMMENT "LLDB.framework: copy clang vendor-specific headers" ) endif() + +# Add an rpath pointing to the directory where LLDB.framework is installed. +set_property(TARGET liblldb APPEND PROPERTY INSTALL_RPATH + "@loader_path/../../../")