]> granicus.if.org Git - clang/commitdiff
CMake: Fix out-of-source build's symlinks.
authorJordan Rose <jordan_rose@apple.com>
Tue, 27 Aug 2013 16:59:30 +0000 (16:59 +0000)
committerJordan Rose <jordan_rose@apple.com>
Tue, 27 Aug 2013 16:59:30 +0000 (16:59 +0000)
Symlinks to clang should go in Clang's build directory, not LLVM's.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@189371 91177308-0d34-0410-b5e6-96231b3b80d8

tools/driver/CMakeLists.txt

index 0a45b58c442eac486e67dab53d3a9208f99273ad..19581c7e680a11fcac9323bb01e98a332474209c 100644 (file)
@@ -65,11 +65,11 @@ if(UNIX)
   set(clang_binary "clang${CMAKE_EXECUTABLE_SUFFIX}")
 else()
   set(CLANGXX_LINK_OR_COPY copy)
-  set(clang_binary "${LLVM_BINARY_DIR}/bin/${CMAKE_CFG_INTDIR}/clang${CMAKE_EXECUTABLE_SUFFIX}")
+  set(clang_binary "${CLANG_BINARY_DIR}/bin/${CMAKE_CFG_INTDIR}/clang${CMAKE_EXECUTABLE_SUFFIX}")
 endif()
 
 # Create the clang++ symlink in the build directory.
-set(clang_pp "${LLVM_BINARY_DIR}/bin/${CMAKE_CFG_INTDIR}/clang++${CMAKE_EXECUTABLE_SUFFIX}")
+set(clang_pp "${CLANG_BINARY_DIR}/bin/${CMAKE_CFG_INTDIR}/clang++${CMAKE_EXECUTABLE_SUFFIX}")
 add_custom_command(TARGET clang POST_BUILD
     COMMAND ${CMAKE_COMMAND} -E ${CLANGXX_LINK_OR_COPY} "${clang_binary}" "${clang_pp}")
 
@@ -77,7 +77,7 @@ set_property(DIRECTORY APPEND
   PROPERTY ADDITIONAL_MAKE_CLEAN_FILES ${clang_pp})
 
 # Create the clang-cl symlink in the build directory.
-set(clang_cl "${LLVM_BINARY_DIR}/bin/${CMAKE_CFG_INTDIR}/clang-cl${CMAKE_EXECUTABLE_SUFFIX}")
+set(clang_cl "${CLANG_BINARY_DIR}/bin/${CMAKE_CFG_INTDIR}/clang-cl${CMAKE_EXECUTABLE_SUFFIX}")
 add_custom_command(TARGET clang POST_BUILD
     COMMAND ${CMAKE_COMMAND} -E ${CLANGXX_LINK_OR_COPY} "${clang_binary}" "${clang_cl}")