summaryrefslogtreecommitdiffstats
path: root/mkspecs
diff options
context:
space:
mode:
authorLars Knoll <lars.knoll@qt.io>2016-08-18 22:25:08 +0200
committerLars Knoll <lars.knoll@qt.io>2016-08-19 04:27:29 +0000
commit56ee007b3f44eb3276b244a630f55482c2b02228 (patch)
tree349a978e664592f51d26563603219e5a537d3cfc /mkspecs
parent606924132ff1f11b9d7b4357251f07ccabb8bdb6 (diff)
Rework privateFeature
privateFeature would add QT_NO_FEATURE to the DEFINES in the private .pri file, which was somewhat inelegant. Additionally, it would add the feature to the _public_ QT_CONFIG variable, which was plain wrong. Replace the implementation with the one just introduced for publicFeature, with the difference that the features are written to the private files instead. As this entirely disposes of the old system, all usages in the project files need to be replaced atomically as well. Change-Id: I506b5d41054410659ea503bc6901736cd5edec6e Reviewed-by: Lars Knoll <lars.knoll@qt.io> Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
Diffstat (limited to 'mkspecs')
-rw-r--r--mkspecs/features/qt_configure.prf8
1 files changed, 5 insertions, 3 deletions
diff --git a/mkspecs/features/qt_configure.prf b/mkspecs/features/qt_configure.prf
index 72dd1c4c8d..2700b2eb80 100644
--- a/mkspecs/features/qt_configure.prf
+++ b/mkspecs/features/qt_configure.prf
@@ -1419,12 +1419,14 @@ defineTest(qtConfOutput_privateFeature) {
name = "$$eval($${1}.name)"
isEmpty(name): \
name = $$eval($${1}.feature)
+ feature = $$replace(name, [-+.], _)
$${2} {
- qtConfOutputVar(append, "publicPro", "QT_CONFIG", $$name)
+ qtConfOutputVar(append, "privatePro", "QT.global.enabled_features", $$name)
+ qtConfOutputSetDefine("privateHeader", "QT_FEATURE_$$feature", 1)
} else {
- f = $$upper($$replace(name, -, _))
- qtConfOutputVar(append, "privatePro", "DEFINES", "QT_NO_$$f")
+ qtConfOutputVar(append, "privatePro", "QT.global.disabled_features", $$name)
+ qtConfOutputSetDefine("privateHeader", "QT_FEATURE_$$feature", -1)
}
}