1get_property(LLVM_LIT_CONFIG_MAP GLOBAL PROPERTY LLVM_LIT_CONFIG_MAP)
2
3get_llvm_lit_path(LIT_BASE_DIR LIT_FILE_NAME)
4
5set(LLVM_SOURCE_DIR ${LLVM_MAIN_SRC_DIR})
6
7if(NOT "${CMAKE_CFG_INTDIR}" STREQUAL ".")
8  foreach(BUILD_MODE ${CMAKE_CONFIGURATION_TYPES})
9    string(REPLACE ${CMAKE_CFG_INTDIR} ${BUILD_MODE} bi ${LIT_BASE_DIR})
10    set(bi "${bi}/${LIT_FILE_NAME}")
11    configure_file(
12      llvm-lit.in
13      ${bi}
14      )
15  endforeach()
16else()
17  set(BUILD_MODE .)
18  configure_file(
19    llvm-lit.in
20    ${LIT_BASE_DIR}/${LIT_FILE_NAME}
21    )
22endif()
23