summaryrefslogtreecommitdiff
path: root/qmake
diff options
context:
space:
mode:
authorMarc Mutz <marc.mutz@kdab.com>2016-05-11 11:53:02 +0200
committerMarc Mutz <marc.mutz@kdab.com>2016-05-11 16:55:32 +0000
commitf0d7080e9e640fdc7b540aba69bfbc14fc96ce39 (patch)
treee12977a9f80e2125753d94f618fcfcc38092a161 /qmake
parent81793b8b58cde01e52675093dc378147dc2102e3 (diff)
downloadqtbase-f0d7080e9e640fdc7b540aba69bfbc14fc96ce39.tar.gz
qmake/tools: port the last remaining Q_FOREACH loops and add QT_NO_FOREACH
Port the last four remaining Q_FOREACH users in qmake and uic to C++11 range-for and mark all qtbase tools (incl. qmake) as Q_FOREACH-free, using QT_NO_FOREACH. Change-Id: Ief4e5877269e7a853e4cf05e58861a448e822d3d Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com> Reviewed-by: Lars Knoll <lars.knoll@theqtcompany.com>
Diffstat (limited to 'qmake')
-rw-r--r--qmake/Makefile.unix1
-rw-r--r--qmake/Makefile.win321
-rw-r--r--qmake/generators/win32/msvc_vcproj.cpp2
-rw-r--r--qmake/qmake.pro1
4 files changed, 4 insertions, 1 deletions
diff --git a/qmake/Makefile.unix b/qmake/Makefile.unix
index 405bbf9212..9d3ddab6f9 100644
--- a/qmake/Makefile.unix
+++ b/qmake/Makefile.unix
@@ -106,6 +106,7 @@ CPPFLAGS = -g $(EXTRA_CPPFLAGS) \
-DQT_BUILD_QMAKE -DQT_BOOTSTRAPPED -DPROEVALUATOR_FULL \
-DQT_NO_TEXTCODEC -DQT_NO_UNICODETABLES -DQT_NO_COMPONENT -DQT_NO_COMPRESS \
-DQT_NO_THREAD -DQT_NO_QOBJECT -DQT_NO_GEOM_VARIANT -DQT_NO_DATASTREAM \
+ -DQT_NO_FOREACH \
-DQT_CRYPTOGRAPHICHASH_ONLY_SHA1 -DQT_JSON_READONLY -DQT_NO_STANDARDPATHS
CXXFLAGS = $(EXTRA_CXXFLAGS) $(CPPFLAGS)
diff --git a/qmake/Makefile.win32 b/qmake/Makefile.win32
index 1d50f872d9..834065ee61 100644
--- a/qmake/Makefile.win32
+++ b/qmake/Makefile.win32
@@ -49,6 +49,7 @@ CFLAGS_BARE = -c -Fo./ -Fdqmake.pdb \
-DQT_BUILD_QMAKE -DQT_BOOTSTRAPPED -DPROEVALUATOR_FULL \
-DQT_NO_TEXTCODEC -DQT_NO_UNICODETABLES -DQT_NO_COMPONENT -DQT_NO_COMPRESS \
-DQT_NO_THREAD -DQT_NO_QOBJECT -DQT_NO_GEOM_VARIANT -DQT_NO_DATASTREAM \
+ -DQT_NO_FOREACH \
-DUNICODE -DQT_CRYPTOGRAPHICHASH_ONLY_SHA1 -DQT_JSON_READONLY -DQT_NO_STANDARDPATHS
CFLAGS = $(CFLAGS_PCH) $(CFLAGS_BARE) $(CFLAGS)
diff --git a/qmake/generators/win32/msvc_vcproj.cpp b/qmake/generators/win32/msvc_vcproj.cpp
index a972316972..9486cf8b6f 100644
--- a/qmake/generators/win32/msvc_vcproj.cpp
+++ b/qmake/generators/win32/msvc_vcproj.cpp
@@ -1316,7 +1316,7 @@ void VcprojGenerator::initDeploymentTool()
if (foundGuid || dllName.contains(QLatin1String("Gui"))) {
QFileInfo info2;
- foreach (const ProString &dllPath, dllPaths) {
+ for (const ProString &dllPath : dllPaths) {
QString absoluteDllFilePath = dllPath.toQString();
if (!absoluteDllFilePath.endsWith(QLatin1Char('/')))
absoluteDllFilePath += QLatin1Char('/');
diff --git a/qmake/qmake.pro b/qmake/qmake.pro
index 89d6ea5fc1..74cefb07aa 100644
--- a/qmake/qmake.pro
+++ b/qmake/qmake.pro
@@ -7,6 +7,7 @@ CONFIG += console bootstrap
CONFIG -= qt
DEFINES += \
QT_BUILD_QMAKE \
+ QT_NO_FOREACH \
PROEVALUATOR_FULL
VPATH += \