summaryrefslogtreecommitdiffstats
path: root/cmake
diff options
context:
space:
mode:
authorAlexandru Croitor <alexandru.croitor@qt.io>2020-06-17 09:11:50 +0200
committerAlexandru Croitor <alexandru.croitor@qt.io>2020-06-17 15:13:43 +0200
commit3452b08df6a3802c96b06651f9a530d55cbe7477 (patch)
tree0e9bf92dfb93a844b374c5a2ea514eeb0f2d145e /cmake
parent17d8b54cbc0a9ef507808d19733b2a753717a0dd (diff)
CMake: Record info about namespaced build for qmake
To make sure qmake generates appropriate rules when building other applications. Task-number: QTBUG-84781 Change-Id: I75618575602be820bf20a8067e3a6ee3ff7e7950 Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
Diffstat (limited to 'cmake')
-rw-r--r--cmake/QtBuild.cmake9
1 files changed, 9 insertions, 0 deletions
diff --git a/cmake/QtBuild.cmake b/cmake/QtBuild.cmake
index c82b33ab8b..37d4b118e9 100644
--- a/cmake/QtBuild.cmake
+++ b/cmake/QtBuild.cmake
@@ -1101,6 +1101,14 @@ function(qt_generate_global_config_pri_file)
list(JOIN corrected_public_config " " public_config_joined)
list(JOIN corrected_qt_public_config " " qt_public_config_joined)
+ set(extra_statements "")
+ if(QT_NAMESPACE)
+ list(APPEND extra_statements "QT_NAMESPACE = ${QT_NAMESPACE}")
+ endif()
+ if(extra_statements)
+ string (REPLACE ";" "\n" extra_statements "${extra_statements}")
+ endif()
+
file(GENERATE
OUTPUT "${qconfig_pri_target_path}"
CONTENT
@@ -1115,6 +1123,7 @@ QT_VERSION = ${PROJECT_VERSION}
QT_MAJOR_VERSION = ${PROJECT_VERSION_MAJOR}
QT_MINOR_VERSION = ${PROJECT_VERSION_MINOR}
QT_PATCH_VERSION = ${PROJECT_VERSION_PATCH}
+${extra_statements}
"
)
qt_install(FILES "${qconfig_pri_target_path}" DESTINATION ${INSTALL_MKSPECSDIR})