validate qconfig-*.h against qfeatures.txt
Change-Id: I59b7e30cfaa2b1bf2c5d4a3e04b5169f3c9439b5 Reviewed-by: Joerg Bornemann <joerg.bornemann@digia.com>
This commit is contained in:
parent
f37ed85a55
commit
d7a0d243a9
1
configure
vendored
1
configure
vendored
@ -6670,6 +6670,7 @@ echo "QT_BUILD_PARTS += $CFG_BUILD_PARTS" >> "$QTMODULE.tmp"
|
||||
if [ -n "$CFG_SKIP_MODULES" ]; then
|
||||
echo "QT_SKIP_MODULES += $CFG_SKIP_MODULES" >> "$QTMODULE.tmp"
|
||||
fi
|
||||
echo "QT_QCONFIG_PATH = ${CFG_QCONFIG_PATH#$relpath/src/corelib/global/}" >> "$QTMODULE.tmp"
|
||||
|
||||
cat >>"$QTMODULE.tmp" <<EOF
|
||||
host_build {
|
||||
|
11
qtbase.pro
11
qtbase.pro
@ -145,6 +145,17 @@ FWD_FEATURES_H = \
|
||||
'$${LITERAL_HASH}include "../../src/corelib/global/qfeatures.h"'
|
||||
write_file($$OUT_PWD/include/QtCore/qfeatures.h, FWD_FEATURES_H)|error("Aborting.")
|
||||
|
||||
lines = $$cat($$absolute_path($$QT_QCONFIG_PATH, $$PWD/src/corelib/global), lines)
|
||||
for (line, lines) {
|
||||
# We ignore all defines that don't follow the #ifndef + indent pattern.
|
||||
# This makes it possible to have unchecked defines which are no features.
|
||||
t = $$replace(line, "^$${LITERAL_HASH} define QT_NO_(\\S+)\\s*$", "\\1")
|
||||
!isEqual(t, $$line) {
|
||||
isEmpty(features.$${t}.name): \
|
||||
error("$$QT_QCONFIG_PATH disables unknown feature $$t")
|
||||
}
|
||||
}
|
||||
|
||||
#mkspecs
|
||||
mkspecs.path = $$[QT_HOST_DATA]/mkspecs
|
||||
mkspecs.files = \
|
||||
|
@ -2860,6 +2860,11 @@ void Configure::generateCachefile()
|
||||
moduleStream << "QT_BUILD_PARTS += " << buildParts.join(' ') << endl;
|
||||
if (!skipModules.isEmpty())
|
||||
moduleStream << "QT_SKIP_MODULES += " << skipModules.join(' ') << endl;
|
||||
QString qcpath = dictionary["QCONFIG_PATH"];
|
||||
QString qlpath = sourcePath + "/src/corelib/global/";
|
||||
if (qcpath.startsWith(qlpath))
|
||||
qcpath.remove(0, qlpath.length());
|
||||
moduleStream << "QT_QCONFIG_PATH = " << qcpath << endl;
|
||||
moduleStream << endl;
|
||||
|
||||
moduleStream << "host_build {" << endl;
|
||||
|
Loading…
Reference in New Issue
Block a user