llvm.org GIT mirror llvm / 43fa064
[CMake] Make the runtimes directory work with bootstrap builds This patch builds on clang r284648, and allows the runtime directory to make the bootstrap builds depend on the builtin libraries. This patch also make the bootstrap build depend on configuring the other runtimes because the libcxx headers are copied during configuration. I have left a TODO in the code to remove that once I come up with a better solution. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@284650 91177308-0d34-0410-b5e6-96231b3b80d8 Chris Bieneman 4 years ago
1 changed file(s) with 15 addition(s) and 0 deletion(s). Raw diff Collapse all Expand all
145145 PASSTHROUGH_PREFIXES COMPILER_RT
146146 USE_TOOLCHAIN)
147147 set(deps builtins)
148 # We don't need to depend on the builtins if we're building instrumented
149 # because the next stage will use the same compiler used to build this stage.
150 if(NOT LLVM_BUILD_INSTRUMENTED AND CLANG_ENABLE_BOOTSTRAP)
151 add_dependencies(clang-bootstrap-deps builtins)
152 endif()
148153 endif()
149154
150155 # We create a list the names of all the runtime projects in all uppercase and
195200 ${SUB_COMPONENT_CHECK_TARGETS}
196201 ${SUB_INSTALL_TARGETS}
197202 USE_TOOLCHAIN)
203
204 # TODO: This is a hack needed because the libcxx headers are copied into the
205 # build directory during configuration. Without that step the clang in the
206 # build directory cannot find the C++ headers in certain configurations.
207 # I need to build a mechanism for runtime projects to provide CMake code
208 # that executes at LLVM configuration time to handle this case.
209 if(NOT LLVM_BUILD_INSTRUMENTED AND CLANG_ENABLE_BOOTSTRAP)
210 add_dependencies(clang-bootstrap-deps runtimes-configure)
211 endif()
212
198213 if(LLVM_INCLUDE_TESTS)
199214 set_property(GLOBAL APPEND PROPERTY LLVM_ADDITIONAL_TEST_DEPENDS runtimes-test-depends)
200215 set_property(GLOBAL APPEND PROPERTY LLVM_ADDITIONAL_TEST_TARGETS check-runtimes)