summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJoerg Bornemann <joerg.bornemann@nokia.com>2010-04-12 09:45:48 (GMT)
committerJoerg Bornemann <joerg.bornemann@nokia.com>2010-04-12 10:07:52 (GMT)
commitf1c74441b17dde565a91ab596cc1b9a920c2ab41 (patch)
treef3c48a1d0aae783eaa4f4622329e1caad813503a
parent2245641baa58125b57faf12496bc472491565498 (diff)
downloadQt-f1c74441b17dde565a91ab596cc1b9a920c2ab41.zip
Qt-f1c74441b17dde565a91ab596cc1b9a920c2ab41.tar.gz
Qt-f1c74441b17dde565a91ab596cc1b9a920c2ab41.tar.bz2
fix cetest build properly
Commit f5b19c173109c53bf3d8167573f7276cf39262d2 broke the build for cetest. Reverting my initial naive attempt to fix this bd5d323373dbaf9d827126b77895da253128c1e5. We're introducing a new define for building qmake without generators. QT_QMAKE_PARSER_ONLY is used for cetest and the qmake COM wrapper of the Visual Studio Add-in. Reviewed-by: ossi
-rw-r--r--qmake/generators/metamakefile.cpp38
-rw-r--r--qmake/project.cpp2
-rw-r--r--tools/qtestlib/wince/cetest/cetest.pro3
-rw-r--r--tools/qtestlib/wince/cetest/qmake_include.pri2
4 files changed, 24 insertions, 21 deletions
diff --git a/qmake/generators/metamakefile.cpp b/qmake/generators/metamakefile.cpp
index e76e596..c42a837 100644
--- a/qmake/generators/metamakefile.cpp
+++ b/qmake/generators/metamakefile.cpp
@@ -58,6 +58,8 @@ MetaMakefileGenerator::~MetaMakefileGenerator()
delete project;
}
+#ifndef QT_QMAKE_PARSER_ONLY
+
class BuildsMetaMakefileGenerator : public MetaMakefileGenerator
{
private:
@@ -489,6 +491,25 @@ MetaMakefileGenerator::createMakefileGenerator(QMakeProject *proj, bool noIO)
return mkfile;
}
+MetaMakefileGenerator *
+MetaMakefileGenerator::createMetaGenerator(QMakeProject *proj, const QString &name, bool op, bool *success)
+{
+ MetaMakefileGenerator *ret = 0;
+ if ((Option::qmake_mode == Option::QMAKE_GENERATE_MAKEFILE ||
+ Option::qmake_mode == Option::QMAKE_GENERATE_PRL)) {
+ if (proj->first("TEMPLATE").endsWith("subdirs"))
+ ret = new SubdirsMetaMakefileGenerator(proj, name, op);
+ }
+ if (!ret)
+ ret = new BuildsMetaMakefileGenerator(proj, name, op);
+ bool res = ret->init();
+ if (success)
+ *success = res;
+ return ret;
+}
+
+#endif // QT_QMAKE_PARSER_ONLY
+
bool
MetaMakefileGenerator::modesForGenerator(const QString &gen,
Option::HOST_MODE *host_mode, Option::TARG_MODE *target_mode)
@@ -523,21 +544,4 @@ MetaMakefileGenerator::modesForGenerator(const QString &gen,
return true;
}
-MetaMakefileGenerator *
-MetaMakefileGenerator::createMetaGenerator(QMakeProject *proj, const QString &name, bool op, bool *success)
-{
- MetaMakefileGenerator *ret = 0;
- if ((Option::qmake_mode == Option::QMAKE_GENERATE_MAKEFILE ||
- Option::qmake_mode == Option::QMAKE_GENERATE_PRL)) {
- if (proj->first("TEMPLATE").endsWith("subdirs"))
- ret = new SubdirsMetaMakefileGenerator(proj, name, op);
- }
- if (!ret)
- ret = new BuildsMetaMakefileGenerator(proj, name, op);
- bool res = ret->init();
- if (success)
- *success = res;
- return ret;
-}
-
QT_END_NAMESPACE
diff --git a/qmake/project.cpp b/qmake/project.cpp
index 56707cf..764264f 100644
--- a/qmake/project.cpp
+++ b/qmake/project.cpp
@@ -1507,7 +1507,6 @@ QMakeProject::read(uchar cmd)
void QMakeProject::validateModes()
{
-#if !defined(QT_BUILD_QMAKE_NO_GENERATORS)
if (Option::host_mode == Option::HOST_UNKNOWN_MODE
|| Option::target_mode == Option::TARG_UNKNOWN_MODE) {
Option::HOST_MODE host_mode;
@@ -1544,7 +1543,6 @@ void QMakeProject::validateModes()
}
}
}
-#endif // !defined(QT_BUILD_QMAKE_NO_GENERATORS)
}
bool
diff --git a/tools/qtestlib/wince/cetest/cetest.pro b/tools/qtestlib/wince/cetest/cetest.pro
index 43ed18e..82747da 100644
--- a/tools/qtestlib/wince/cetest/cetest.pro
+++ b/tools/qtestlib/wince/cetest/cetest.pro
@@ -13,8 +13,7 @@ DEFINES += QT_BUILD_QMAKE QT_BOOTSTRAPPED QT_NO_CODECS QT_LITE_UNICODE QT
QT_NO_STL QT_NO_COMPRESS QT_NO_DATASTREAM \
QT_NO_TEXTCODEC QT_NO_UNICODETABLES QT_NO_THREAD \
QT_NO_SYSTEMLOCALE QT_NO_GEOM_VARIANT \
- QT_NODLL QT_NO_QOBJECT \
- QT_BUILD_QMAKE_NO_GENERATORS
+ QT_NODLL QT_NO_QOBJECT
INCLUDEPATH = \
$$QT_SOURCE_TREE/tools/qtestlib/ce/cetest \
diff --git a/tools/qtestlib/wince/cetest/qmake_include.pri b/tools/qtestlib/wince/cetest/qmake_include.pri
index 8b415b0..35fbc64 100644
--- a/tools/qtestlib/wince/cetest/qmake_include.pri
+++ b/tools/qtestlib/wince/cetest/qmake_include.pri
@@ -5,7 +5,9 @@ SOURCES += \
$$QT_SOURCE_TREE/qmake/option.cpp \
$$QT_SOURCE_TREE/qmake/project.cpp \
$$QT_SOURCE_TREE/qmake/property.cpp \
+ $$QT_SOURCE_TREE/qmake/generators/metamakefile.cpp \
$$QT_SOURCE_TREE/qmake/generators/symbian/initprojectdeploy_symbian.cpp \
$$QT_SOURCE_TREE/tools/shared/symbian/epocroot.cpp \
$$QT_SOURCE_TREE/tools/shared/windows/registry.cpp
+DEFINES += QT_QMAKE_PARSER_ONLY