diff --git a/Tests/QtAutogen/CMakeLists.txt b/Tests/QtAutogen/CMakeLists.txt index 81a70f4611..67e0f7e81d 100644 --- a/Tests/QtAutogen/CMakeLists.txt +++ b/Tests/QtAutogen/CMakeLists.txt @@ -147,7 +147,7 @@ set(timeformat "%Y%j%H%M%S") file(TIMESTAMP "${qrc_file1}" file1_before "${timeformat}") execute_process(COMMAND "${CMAKE_COMMAND}" -E sleep 1) # Ensure that the timestamp will change. -execute_process(COMMAND "${CMAKE_COMMAND}" -E touch "${CMAKE_CURRENT_SOURCE_DIR}/autorcc_depends/res1_input.txt") +execute_process(COMMAND "${CMAKE_COMMAND}" -E touch "${CMAKE_CURRENT_BINARY_DIR}/autorcc_depends/res1_input.txt") execute_process(COMMAND "${CMAKE_COMMAND}" --build . WORKING_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/autorcc_depends" diff --git a/Tests/QtAutogen/autorcc_depends/CMakeLists.txt b/Tests/QtAutogen/autorcc_depends/CMakeLists.txt index 0ba86cff2b..9faf803834 100644 --- a/Tests/QtAutogen/autorcc_depends/CMakeLists.txt +++ b/Tests/QtAutogen/autorcc_depends/CMakeLists.txt @@ -15,9 +15,12 @@ else() set(QT_CORE_TARGET Qt5::Core) endif() +configure_file(res1.qrc.in res1.qrc @ONLY) +configure_file(res1_input.txt.in res1_input.txt @ONLY) + add_executable(test_res1 test_res1.cpp - res1.qrc + ${CMAKE_CURRENT_BINARY_DIR}/res1.qrc ) target_link_libraries(test_res1 ${QT_CORE_TARGET}) add_custom_command(TARGET test_res1 POST_BUILD COMMAND diff --git a/Tests/QtAutogen/autorcc_depends/res1.qrc b/Tests/QtAutogen/autorcc_depends/res1.qrc.in similarity index 100% rename from Tests/QtAutogen/autorcc_depends/res1.qrc rename to Tests/QtAutogen/autorcc_depends/res1.qrc.in diff --git a/Tests/QtAutogen/autorcc_depends/res1_input.txt b/Tests/QtAutogen/autorcc_depends/res1_input.txt.in similarity index 100% rename from Tests/QtAutogen/autorcc_depends/res1_input.txt rename to Tests/QtAutogen/autorcc_depends/res1_input.txt.in