diff options
Diffstat (limited to 'tools/configure/configureapp.cpp')
-rw-r--r-- | tools/configure/configureapp.cpp | 43 |
1 files changed, 39 insertions, 4 deletions
diff --git a/tools/configure/configureapp.cpp b/tools/configure/configureapp.cpp index 3e91e85882..5ed6b803c3 100644 --- a/tools/configure/configureapp.cpp +++ b/tools/configure/configureapp.cpp @@ -1827,7 +1827,7 @@ bool Configure::displayHelp() desc("BUILD_QMAKE", "no", "-no-qmake", "Do not compile qmake."); desc("BUILD_QMAKE", "yes", "-qmake", "Compile qmake.\n"); - desc("PROCESS", "partial", "-process", "Generate top-level Makefiles/Project files."); + desc("PROCESS", "partial", "-process", "Generate only top-level Makefile."); desc("PROCESS", "full", "-fully-process", "Generate Makefiles/Project files for the entire Qt\ntree."); desc("PROCESS", "no", "-dont-process", "Do not generate Makefiles/Project files.\n"); @@ -1973,7 +1973,7 @@ QString Configure::defaultTo(const QString &option) return "auto"; if (option == "SYNCQT" - && (!QFile::exists(sourcePath + "/bin/syncqt.pl"))) + && (!QFile::exists(sourcePath + "/.git"))) return "no"; // Do not actually build the examples in production builds with -prefix, unless requested @@ -3346,6 +3346,37 @@ void Configure::generateConfigfiles() tmpFile.close(); } + QTemporaryFile tmpFile2; + if (tmpFile2.open()) { + tmpStream.setDevice(&tmpFile2); + tmpStream << "#include \"../../src/corelib/global/qconfig.h\"" << endl; + + tmpStream.flush(); + tmpFile2.flush(); + + outName = buildPath + "/include/QtCore/qconfig.h"; + ::SetFileAttributes((wchar_t*)outName.utf16(), FILE_ATTRIBUTE_NORMAL); + QFile::remove(outName); + + tmpFile2.copy(outName); + tmpFile2.close(); + } + QTemporaryFile tmpFile2a; + if (tmpFile2a.open()) { + tmpStream.setDevice(&tmpFile2a); + tmpStream << "#include \"qconfig.h\"" << endl; + + tmpStream.flush(); + tmpFile2a.flush(); + + outName = buildPath + "/include/QtCore/QtConfig"; + ::SetFileAttributes((wchar_t*)outName.utf16(), FILE_ATTRIBUTE_NORMAL); + QFile::remove(outName); + + tmpFile2a.copy(outName); + tmpFile2a.close(); + } + QTemporaryFile tmpFile3; if (tmpFile3.open()) { tmpStream.setDevice(&tmpFile3); @@ -3774,7 +3805,10 @@ void Configure::buildQmake() QTextStream stream(&out); stream << "#AutoGenerated by configure.exe" << endl << "BUILD_PATH = " << QDir::toNativeSeparators(buildPath) << endl - << "SOURCE_PATH = " << QDir::toNativeSeparators(sourcePath) << endl; + << "SOURCE_PATH = " << QDir::toNativeSeparators(sourcePath) << endl + << "INC_PATH = " << QDir::toNativeSeparators( + (QFile::exists(sourcePath + "/.git") ? buildPath : sourcePath) + + "/include") << endl; stream << "QT_VERSION = " << dictionary["VERSION"] << endl; if (dictionary[ "QMAKESPEC" ] == QString("win32-g++")) { stream << "QMAKESPEC = $(SOURCE_PATH)\\mkspecs\\win32-g++" << endl @@ -3918,7 +3952,8 @@ void Configure::generateMakefiles() { QString dirName; bool generate = true; - bool doDsp = (dictionary["VCPROJFILES"] == "yes"); + bool doDsp = (dictionary["VCPROJFILES"] == "yes" + && dictionary["PROCESS"] == "full"); while (generate) { QString pwd = QDir::currentPath(); QString dirPath = buildPath + dirName; |