forked from OSchip/llvm-project
[lldb\utils] Place lldb-repro in a per-configuration directory to support multi-configuration generators
Summary: Currently, lldb-repro is placed in the wrong location for multi-configuration generators. For example, in the case of VS, it is placed in a directory $(Configuration) instead of in each of Debug, Release, etc. Reviewers: JDevlieghere Reviewed By: JDevlieghere Subscribers: mgorny, lldb-commits, asmith Tags: #lldb Differential Revision: https://reviews.llvm.org/D74148
This commit is contained in:
parent
80e17e5fcc
commit
733923a97d
|
@ -53,7 +53,7 @@ if(LLDB_BUILT_STANDALONE)
|
|||
endforeach()
|
||||
elseif(NOT "${CMAKE_CFG_INTDIR}" STREQUAL ".")
|
||||
foreach(LLVM_BUILD_MODE ${CMAKE_CONFIGURATION_TYPES})
|
||||
string(REPLACE ${CMAKE_CFG_INTDIR} ${LLVM_BUILD_MODE} LLDB_DOTEST_DIR_CONFIGURED ${LLVM_RUNTIME_OUTPUT_INTDIR})
|
||||
string(REPLACE ${CMAKE_CFG_INTDIR} ${LLVM_BUILD_MODE} LLDB_DOTEST_DIR ${LLVM_RUNTIME_OUTPUT_INTDIR})
|
||||
string(REPLACE ${CMAKE_CFG_INTDIR} ${LLVM_BUILD_MODE} LLDB_DOTEST_ARGS_CONFIGURED "${LLDB_DOTEST_ARGS}")
|
||||
string(REPLACE ${CMAKE_CFG_INTDIR} ${LLVM_BUILD_MODE} LLDB_SOURCE_DIR_CONFIGURED "${LLDB_SOURCE_DIR}")
|
||||
string(REPLACE ${CMAKE_CFG_INTDIR} ${LLVM_BUILD_MODE} LLDB_TEST_BUILD_DIRECTORY_CONFIGURED "${LLDB_TEST_BUILD_DIRECTORY}")
|
||||
|
@ -65,7 +65,7 @@ elseif(NOT "${CMAKE_CFG_INTDIR}" STREQUAL ".")
|
|||
|
||||
configure_file(
|
||||
lldb-dotest.in
|
||||
${LLDB_DOTEST_DIR_CONFIGURED}/lldb-dotest
|
||||
${LLDB_DOTEST_DIR}/lldb-dotest
|
||||
)
|
||||
endforeach()
|
||||
else()
|
||||
|
|
|
@ -1,4 +1,23 @@
|
|||
add_custom_target(lldb-repro)
|
||||
add_dependencies(lldb-repro lldb-test-deps)
|
||||
set_target_properties(lldb-repro PROPERTIES FOLDER "lldb utils")
|
||||
configure_file(lldb-repro.py ${LLVM_RUNTIME_OUTPUT_INTDIR}/lldb-repro COPYONLY)
|
||||
|
||||
# Generate lldb-repro Python script for each build mode.
|
||||
if(LLDB_BUILT_STANDALONE)
|
||||
set(config_types ".")
|
||||
if(CMAKE_CONFIGURATION_TYPES)
|
||||
set(config_types ${CMAKE_CONFIGURATION_TYPES})
|
||||
endif()
|
||||
|
||||
foreach(config_type ${config_types})
|
||||
string(REPLACE ${CMAKE_CFG_INTDIR} ${config_type} config_runtime_output_dir ${LLVM_RUNTIME_OUTPUT_INTDIR})
|
||||
configure_file(lldb-repro.py ${config_runtime_output_dir}/lldb-repro COPYONLY)
|
||||
endforeach()
|
||||
elseif(NOT "${CMAKE_CFG_INTDIR}" STREQUAL ".")
|
||||
foreach(LLVM_BUILD_MODE ${CMAKE_CONFIGURATION_TYPES})
|
||||
string(REPLACE ${CMAKE_CFG_INTDIR} ${LLVM_BUILD_MODE} LLDB_REPRO_DIR ${LLVM_RUNTIME_OUTPUT_INTDIR})
|
||||
configure_file(lldb-repro.py ${LLDB_REPRO_DIR}/lldb-repro COPYONLY)
|
||||
endforeach()
|
||||
else()
|
||||
configure_file(lldb-repro.py ${LLVM_RUNTIME_OUTPUT_INTDIR}/lldb-repro COPYONLY)
|
||||
endif()
|
||||
|
|
Loading…
Reference in New Issue