]> granicus.if.org Git - clang/commitdiff
[CMake] Fixing clang bootstrap to use LLVM_RUNTIME_OUTPUT_INTDIR instead of CMAKE_BIN...
authorChris Bieneman <beanz@apple.com>
Fri, 2 Oct 2015 00:56:53 +0000 (00:56 +0000)
committerChris Bieneman <beanz@apple.com>
Fri, 2 Oct 2015 00:56:53 +0000 (00:56 +0000)
This should make bootstrap builds work with multi-configuration generators.

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

CMakeLists.txt

index 0cc388eb35b343ea5db61ccac923f9f7142339ac..e7a8cdcc34cf93379cff3796f51c3de935e2a7f4 100644 (file)
@@ -598,9 +598,9 @@ if (CLANG_ENABLE_BOOTSTRAP)
   # DARWIN_LTO_LIBRARY so that -flto will work using the just-built compiler
   if(APPLE)
     set(LTO_DEP LTO llvm-ar llvm-ranlib)
-    set(LTO_LIBRARY -DDARWIN_LTO_LIBRARY=${CMAKE_BINARY_DIR}/lib/libLTO.dylib)
-    set(LTO_AR -DCMAKE_AR=${CMAKE_BINARY_DIR}/bin/llvm-ar)
-    set(LTO_RANLIB -DCMAKE_RANLIB=${CMAKE_BINARY_DIR}/bin/llvm-ranlib)
+    set(LTO_LIBRARY -DDARWIN_LTO_LIBRARY=${LLVM_RUNTIME_OUTPUT_INTDIR}/libLTO.dylib)
+    set(LTO_AR -DCMAKE_AR=${LLVM_RUNTIME_OUTPUT_INTDIR}/llvm-ar)
+    set(LTO_RANLIB -DCMAKE_RANLIB=${LLVM_RUNTIME_OUTPUT_INTDIR}/llvm-ranlib)
   endif()
 
   add_custom_target(bootstrap-clear
@@ -628,9 +628,9 @@ if (CLANG_ENABLE_BOOTSTRAP)
                 # seem to work, so instead I'm passing this through
                 -DCMAKE_INSTALL_PREFIX=${CMAKE_INSTALL_PREFIX}
                 ${CLANG_BOOTSTRAP_CMAKE_ARGS}
-                -DCMAKE_CXX_COMPILER=${CMAKE_BINARY_DIR}/bin/clang++
-                -DCMAKE_C_COMPILER=${CMAKE_BINARY_DIR}/bin/clang
-                -DCMAKE_ASM_COMPILER=${CMAKE_BINARY_DIR}/bin/clang
+                -DCMAKE_CXX_COMPILER=${LLVM_RUNTIME_OUTPUT_INTDIR}/clang++
+                -DCMAKE_C_COMPILER=${LLVM_RUNTIME_OUTPUT_INTDIR}/clang
+                -DCMAKE_ASM_COMPILER=${LLVM_RUNTIME_OUTPUT_INTDIR}/clang
                 ${LTO_LIBRARY} ${LTO_AR} ${LTO_RANLIB}
     INSTALL_COMMAND ""
     STEP_TARGETS configure build