brintos

brintos / llvm-project-archived public Read only

0
0
Text · 1.5 KiB · 63a1c21 Raw
47 lines · plain
1set(CMAKE_BUILD_TYPE RELEASE CACHE STRING "")2set(CLANG_ENABLE_BOOTSTRAP ON CACHE BOOL "")3 4set(LLVM_ENABLE_PROJECTS "clang;lld" CACHE STRING "")5set(LLVM_ENABLE_RUNTIMES "compiler-rt;libcxx;libcxxabi" CACHE STRING "")6 7if(APPLE)8  # Use LLD to have fewer requirements on system linker, unless we're on an apple9  # platform where the system compiler is to be preferred.10  set(BOOTSTRAP_LLVM_ENABLE_LLD OFF CACHE BOOL "")11  set(BOOTSTRAP_LLVM_ENABLE_LTO ON CACHE BOOL "")12elseif(CMAKE_HOST_UNIX)13  # s390/SystemZ is unsupported by LLD, so don't try to enable LTO if it14  # cannot work.15  # We do our own uname business here since the appropriate variables from CMake16  # and llvm are not yet available.17  find_program(CMAKE_UNAME uname /bin /usr/bin /usr/local/bin )18  if(CMAKE_UNAME)19    exec_program(${CMAKE_UNAME} ARGS -m OUTPUT_VARIABLE CMAKE_HOST_SYSTEM_PROCESSOR20        RETURN_VALUE val)21  endif(CMAKE_UNAME)22 23  if("${CMAKE_HOST_SYSTEM_PROCESSOR}" MATCHES "s390")24    set(BOOTSTRAP_LLVM_ENABLE_LTO OFF CACHE BOOL "")25    set(BOOTSTRAP_LLVM_ENABLE_LLD OFF CACHE BOOL "")26  else()27    set(BOOTSTRAP_LLVM_ENABLE_LTO ON CACHE BOOL "")28    set(BOOTSTRAP_LLVM_ENABLE_LLD ON CACHE BOOL "")29  endif()30 31else()32  set(BOOTSTRAP_LLVM_ENABLE_LTO ON CACHE BOOL "")33  set(BOOTSTRAP_LLVM_ENABLE_LLD ON CACHE BOOL "")34endif()35 36 37set(CLANG_BOOTSTRAP_TARGETS38  clang39  check-all40  check-llvm41  check-clang42  test-suite CACHE STRING "")43 44set(CLANG_BOOTSTRAP_CMAKE_ARGS45  -C ${CMAKE_CURRENT_LIST_DIR}/3-stage-base.cmake46  CACHE STRING "")47