diff options
author | Michal Gorny <mgorny@gentoo.org> | 2017-01-09 23:12:37 +0000 |
---|---|---|
committer | Michal Gorny <mgorny@gentoo.org> | 2017-01-09 23:12:37 +0000 |
commit | eb200b2ccfc780142812d935c1854bd2ad2ca139 (patch) | |
tree | ca63017b2f0cc337aef67730a923a13d04bf9a11 /lldb/cmake | |
parent | 5b30b67cd1bf93b136ca33656b50fcff715bbfbe (diff) | |
download | bcm5719-llvm-eb200b2ccfc780142812d935c1854bd2ad2ca139.tar.gz bcm5719-llvm-eb200b2ccfc780142812d935c1854bd2ad2ca139.zip |
[cmake] Obtain LLVM_CMAKE_PATH from llvm-config
Use the new --cmakedir option to obtain LLVM_CMAKE_PATH straight from
llvm-config instead of reconstructing it locally.
llvm-svn: 291500
Diffstat (limited to 'lldb/cmake')
-rw-r--r-- | lldb/cmake/modules/LLDBStandalone.cmake | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/lldb/cmake/modules/LLDBStandalone.cmake b/lldb/cmake/modules/LLDBStandalone.cmake index d849602c57b..a142b757569 100644 --- a/lldb/cmake/modules/LLDBStandalone.cmake +++ b/lldb/cmake/modules/LLDBStandalone.cmake @@ -21,7 +21,8 @@ if (CMAKE_SOURCE_DIR STREQUAL CMAKE_CURRENT_SOURCE_DIR) "--libdir" "--includedir" "--prefix" - "--src-root") + "--src-root" + "--cmakedir") execute_process( COMMAND ${CONFIG_COMMAND} RESULT_VARIABLE HAD_ERROR @@ -47,6 +48,7 @@ if (CMAKE_SOURCE_DIR STREQUAL CMAKE_CURRENT_SOURCE_DIR) list(GET CONFIG_OUTPUT 3 INCLUDE_DIR) list(GET CONFIG_OUTPUT 4 LLVM_OBJ_ROOT) list(GET CONFIG_OUTPUT 5 MAIN_SRC_DIR) + list(GET CONFIG_OUTPUT 6 LLVM_CMAKE_PATH) if(NOT MSVC_IDE) set(LLVM_ENABLE_ASSERTIONS ${ENABLE_ASSERTIONS} @@ -65,7 +67,6 @@ if (CMAKE_SOURCE_DIR STREQUAL CMAKE_CURRENT_SOURCE_DIR) find_program(LLVM_TABLEGEN_EXE "llvm-tblgen" ${LLVM_TOOLS_BINARY_DIR} NO_DEFAULT_PATH) - set(LLVM_CMAKE_PATH "${LLVM_BINARY_DIR}/lib${LLVM_LIBDIR_SUFFIX}/cmake/llvm") set(LLVMCONFIG_FILE "${LLVM_CMAKE_PATH}/LLVMConfig.cmake") if(EXISTS ${LLVMCONFIG_FILE}) list(APPEND CMAKE_MODULE_PATH "${LLVM_CMAKE_PATH}") |