From 07eeff5582edc11a4acbc516b18778f016c04723 Mon Sep 17 00:00:00 2001 From: Oleg Ranevskyy Date: Thu, 26 Jan 2017 18:16:02 +0000 Subject: [Compiler-rt] Broken compiler-rt CMake configuring on Windows Summary: Hi Michal, Would you be able to review this simple fix, please? Since r291504 compiler-rt uses `llvm-config --cmakedir` to get the path to the LLVM CMake modules. On Windows this option returns Windows style path with backslashes. CMake treats backslashes as beginning of an escaped character and thus fails to append the path to `CMAKE_MODULE_PATH`. Reviewers: compnerd, mgorny Reviewed By: mgorny Subscribers: compnerd, llvm-commits, dberris Differential Revision: https://reviews.llvm.org/D28908 git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@293195 91177308-0d34-0410-b5e6-96231b3b80d8 --- cmake/Modules/CompilerRTUtils.cmake | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'cmake/Modules') diff --git a/cmake/Modules/CompilerRTUtils.cmake b/cmake/Modules/CompilerRTUtils.cmake index c337523cd..ed946d88f 100644 --- a/cmake/Modules/CompilerRTUtils.cmake +++ b/cmake/Modules/CompilerRTUtils.cmake @@ -225,7 +225,8 @@ macro(load_llvm_config) RESULT_VARIABLE HAD_ERROR OUTPUT_VARIABLE CONFIG_OUTPUT) if(NOT HAD_ERROR) - string(STRIP "${CONFIG_OUTPUT}" LLVM_CMAKE_PATH) + string(STRIP "${CONFIG_OUTPUT}" LLVM_CMAKE_PATH_FROM_LLVM_CONFIG) + file(TO_CMAKE_PATH ${LLVM_CMAKE_PATH_FROM_LLVM_CONFIG} LLVM_CMAKE_PATH) else() file(TO_CMAKE_PATH ${LLVM_BINARY_DIR} LLVM_BINARY_DIR_CMAKE_STYLE) set(LLVM_CMAKE_PATH "${LLVM_BINARY_DIR_CMAKE_STYLE}/lib${LLVM_LIBDIR_SUFFIX}/cmake/llvm") -- cgit v1.2.3