From fccc64fc4f051bb377ba6e5000daac728be52eed Mon Sep 17 00:00:00 2001 From: Alexey Edelev Date: Wed, 10 Apr 2024 14:45:42 +0200 Subject: [PATCH] Install config.opt and config.summary files in top-level prefix builds Assuming the DATADIR is a good destination for these files. The behavior is disabled by default, set QT_INSTALL_CONFIG_INFO_FILES to TRUE to enable it. Task-number: QTBUG-78749 Change-Id: Ief81b856265ad028714e1d6651239c05aed1a5c4 Reviewed-by: Alexandru Croitor --- cmake/QtBaseTopLevelHelpers.cmake | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/cmake/QtBaseTopLevelHelpers.cmake b/cmake/QtBaseTopLevelHelpers.cmake index 07893b6cece..ea334206a02 100644 --- a/cmake/QtBaseTopLevelHelpers.cmake +++ b/cmake/QtBaseTopLevelHelpers.cmake @@ -74,6 +74,15 @@ macro(qt_internal_top_level_end) # Depends on QtBuildInternalsConfig being included, which is the case whenver any repo is # configured. qt_internal_qt_configure_end() + + if(QT_WILL_INSTALL AND QT_INSTALL_CONFIG_INFO_FILES) + qt_install( + FILES + "${CMAKE_BINARY_DIR}/config.opt" + "${CMAKE_BINARY_DIR}/config.summary" + DESTINATION ${INSTALL_DATADIR} + ) + endif() endmacro() function(qt_internal_print_top_level_info)