[llvm] cmake: do not force building with the install name dir (PR #65656)
Raul Tambre via llvm-commits
llvm-commits at lists.llvm.org
Sat Sep 23 06:38:44 PDT 2023
================
@@ -6,7 +6,12 @@ set(LLVM_COMMON_CMAKE_UTILS ${CMAKE_CURRENT_SOURCE_DIR}/../cmake)
include(${LLVM_COMMON_CMAKE_UTILS}/Modules/CMakePolicy.cmake
NO_POLICY_SCOPE)
-set(CMAKE_BUILD_WITH_INSTALL_NAME_DIR ON)
+# Builds with custom install names and installation rpath setups may not work
+# in the build tree. Allow these cases to use CMake's default build tree
+# behavior by setting `LLVM_USE_INSTALL_NAME_DIR_IN_BUILD_TREE` to do this.
+if (NOT LLVM_USE_INSTALL_NAME_DIR_IN_BUILD_TREE)
----------------
tambry wrote:
The logic reads inverted to me. It seems `LLVM_USE_INSTALL_NAME_DIR_IN_BUILD_TREE=ON` should mean `CMAKE_BUILD_WITH_INSTALL_NAME_DIR=ON`, not the opposite.
https://github.com/llvm/llvm-project/pull/65656
More information about the llvm-commits
mailing list