1 # This file sets up a CMakeCache for a simple distribution bootstrap build.
3 # Only build the native target in stage1 since it is a throwaway build.
4 set(LLVM_TARGETS_TO_BUILD Native CACHE STRING "")
6 # Optimize the stage1 compiler, but don't LTO it because that wastes time.
7 set(CMAKE_BUILD_TYPE Release CACHE STRING "")
9 # Setup vendor-specific settings.
10 set(PACKAGE_VENDOR LLVM.org CACHE STRING "")
12 # Setting up the stage2 LTO option needs to be done on the stage1 build so that
13 # the proper LTO library dependencies can be connected.
14 set(BOOTSTRAP_LLVM_ENABLE_LTO ON CACHE BOOL "")
16 # Expose stage2 targets through the stage1 build configuration.
17 set(CLANG_BOOTSTRAP_TARGETS
28 clang CACHE STRING "")
30 # Setup the bootstrap build.
31 set(CLANG_ENABLE_BOOTSTRAP ON CACHE BOOL "")
34 set(CLANG_BOOTSTRAP_CMAKE_ARGS
35 -C ${STAGE2_CACHE_FILE}
38 set(CLANG_BOOTSTRAP_CMAKE_ARGS
39 -C ${CMAKE_CURRENT_LIST_DIR}/DistributionExample-stage2.cmake