aboutsummaryrefslogtreecommitdiffstats
path: root/src/qml/CMakeLists.txt
diff options
context:
space:
mode:
authorAlexey Edelev <alexey.edelev@qt.io>2020-11-17 18:46:49 +0100
committerAlexey Edelev <alexey.edelev@qt.io>2020-11-18 12:43:39 +0100
commitb743323602babb9580149ca2b881ce4bc85e0584 (patch)
tree23468cfdb28c0f8eb4105e18f348b40b2723ca6b /src/qml/CMakeLists.txt
parent38088c451d3264eeb95ef697a79904d2461dcdd9 (diff)
CMake: Replace 'file' with 'configure_file' in 'qmldir' generation
Collect content of 'qmldir' file that is generated by 'qt6_add_qml_module' and 'qt6_target_qml_files' functions, instead of write content to file immediately. Use 'cmake_language(DEFER CALL)' to call 'configure_file' write whole 'qmldir', when finalizing CMAKE_CURRENT_SOURCE_DIR scope. This way a reconfiguration will not rewrite the files, touch the timestamps, and thus needlessly rebuild. Task-number: QTBUG-88172 Change-Id: Idca68e4ceed13d0aa7eac443e769d5677557b880 Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
Diffstat (limited to 'src/qml/CMakeLists.txt')
-rw-r--r--src/qml/CMakeLists.txt2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/qml/CMakeLists.txt b/src/qml/CMakeLists.txt
index 596a8fdfc0..8e977687cc 100644
--- a/src/qml/CMakeLists.txt
+++ b/src/qml/CMakeLists.txt
@@ -355,6 +355,8 @@ qt_internal_add_module(Qml
Qt::Core
PRIVATE_MODULE_INTERFACE
Qt::CorePrivate
+ EXTRA_CMAKE_FILES
+ "${CMAKE_CURRENT_SOURCE_DIR}/Qt6qmldirTemplate.cmake.in"
)
# special case begin remove the block, handled manually