summaryrefslogtreecommitdiff
path: root/clang/CMakeLists.txt
diff options
context:
space:
mode:
authorAhmed Bougacha <ahmed.bougacha@gmail.com>2018-06-28 18:35:25 +0000
committerAhmed Bougacha <ahmed.bougacha@gmail.com>2018-06-28 18:35:25 +0000
commit0f26710d0382348917bec724e74cae7a17e5a5f7 (patch)
treebe8baf832517ebc97ef657fa95c5d93e34f360ae /clang/CMakeLists.txt
parent843d8eeb9a459c3997a2f52b80e31d2ee48d3513 (diff)
[CMake] Make bootstrap and compiler-rt depend on cxx-headers.
Since r334468, we no longer always copy the libcxx headers by virtue of their presence when cmake runs. This makes some of the later stages (compiler-rt, and the bootstrapped stages) depend on them being copied, via the cxx-headers target. Differential Revision: https://reviews.llvm.org/D48700
Diffstat (limited to 'clang/CMakeLists.txt')
-rw-r--r--clang/CMakeLists.txt11
1 files changed, 8 insertions, 3 deletions
diff --git a/clang/CMakeLists.txt b/clang/CMakeLists.txt
index ae8835d751c..52b88193949 100644
--- a/clang/CMakeLists.txt
+++ b/clang/CMakeLists.txt
@@ -621,10 +621,15 @@ if (CLANG_ENABLE_BOOTSTRAP)
LLVM_ENABLE_PROJECTS
LLVM_ENABLE_RUNTIMES)
- # We don't need to depend on compiler-rt if we're building instrumented
+ # We don't need to depend on compiler-rt/libcxx if we're building instrumented
# because the next stage will use the same compiler used to build this stage.
- if(TARGET compiler-rt AND NOT LLVM_BUILD_INSTRUMENTED)
- add_dependencies(clang-bootstrap-deps compiler-rt)
+ if(NOT LLVM_BUILD_INSTRUMENTED)
+ if(TARGET compiler-rt)
+ add_dependencies(clang-bootstrap-deps compiler-rt)
+ endif()
+ if(TARGET cxx-headers)
+ add_dependencies(clang-bootstrap-deps cxx-headers)
+ endif()
endif()
set(C_COMPILER "clang")