diff options
Diffstat (limited to 'tools/configure')
-rw-r--r-- | tools/configure/configure.pro | 12 | ||||
-rw-r--r-- | tools/configure/configureapp.cpp | 51 | ||||
-rw-r--r-- | tools/configure/environment.cpp | 12 | ||||
-rw-r--r-- | tools/configure/environment.h | 4 |
4 files changed, 40 insertions, 39 deletions
diff --git a/tools/configure/configure.pro b/tools/configure/configure.pro index 0a49fbe..608d876 100644 --- a/tools/configure/configure.pro +++ b/tools/configure/configure.pro @@ -48,6 +48,10 @@ HEADERS = configureapp.h environment.h tools.h\ $$QT_SOURCE_TREE/src/corelib/io/qdiriterator.h \ $$QT_SOURCE_TREE/src/corelib/io/qfile.h \ $$QT_SOURCE_TREE/src/corelib/io/qfileinfo.h \ + $$QT_SOURCE_TREE/src/corelib/io/qfilesystementry_p.h \ + $$QT_SOURCE_TREE/src/corelib/io/qfilesystemengine_p.h \ + $$QT_SOURCE_TREE/src/corelib/io/qfilesystemmetadata_p.h \ + $$QT_SOURCE_TREE/src/corelib/io/qfilesystemiterator_p.h \ $$QT_SOURCE_TREE/src/corelib/io/qfsfileengine.h \ $$QT_SOURCE_TREE/src/corelib/io/qfsfileengine_iterator_p.h \ $$QT_SOURCE_TREE/src/corelib/io/qiodevice.h \ @@ -86,9 +90,13 @@ SOURCES = main.cpp configureapp.cpp environment.cpp tools.cpp \ $$QT_SOURCE_TREE/src/corelib/io/qfile.cpp \ $$QT_SOURCE_TREE/src/corelib/io/qfileinfo.cpp \ $$QT_SOURCE_TREE/src/corelib/io/qabstractfileengine.cpp \ + $$QT_SOURCE_TREE/src/corelib/io/qfilesystementry.cpp \ + $$QT_SOURCE_TREE/src/corelib/io/qfilesystemengine.cpp \ + $$QT_SOURCE_TREE/src/corelib/io/qfilesystemengine_win.cpp \ + $$QT_SOURCE_TREE/src/corelib/io/qfilesystemiterator_win.cpp \ $$QT_SOURCE_TREE/src/corelib/io/qfsfileengine.cpp \ + $$QT_SOURCE_TREE/src/corelib/io/qfsfileengine_win.cpp \ $$QT_SOURCE_TREE/src/corelib/io/qfsfileengine_iterator.cpp \ - $$QT_SOURCE_TREE/src/corelib/io/qfsfileengine_iterator_win.cpp \ $$QT_SOURCE_TREE/src/corelib/io/qiodevice.cpp \ $$QT_SOURCE_TREE/src/corelib/io/qtextstream.cpp \ $$QT_SOURCE_TREE/src/corelib/io/qtemporaryfile.cpp \ @@ -115,8 +123,6 @@ SOURCES = main.cpp configureapp.cpp environment.cpp tools.cpp \ $$QT_SOURCE_TREE/tools/shared/symbian/epocroot.cpp \ $$QT_SOURCE_TREE/tools/shared/windows/registry.cpp -win32:SOURCES += $$QT_SOURCE_TREE/src/corelib/io/qfsfileengine_win.cpp - DEFINES += COMMERCIAL_VERSION INCLUDEPATH += $$QT_SOURCE_TREE/src/corelib/arch/generic \ diff --git a/tools/configure/configureapp.cpp b/tools/configure/configureapp.cpp index 9dda3bd..0c172e8 100644 --- a/tools/configure/configureapp.cpp +++ b/tools/configure/configureapp.cpp @@ -590,8 +590,6 @@ void Configure::parseCmdLine() // Image formats -------------------------------------------- else if (configCmdLine.at(i) == "-no-gif") dictionary[ "GIF" ] = "no"; - else if (configCmdLine.at(i) == "-qt-gif") - dictionary[ "GIF" ] = "plugin"; else if (configCmdLine.at(i) == "-no-libtiff") { dictionary[ "TIFF"] = "no"; @@ -1661,7 +1659,7 @@ bool Configure::displayHelp() "[-no-qmake] [-qmake] [-dont-process] [-process]\n" "[-no-style-<style>] [-qt-style-<style>] [-redo]\n" "[-saveconfig <config>] [-loadconfig <config>]\n" - "[-qt-zlib] [-system-zlib] [-no-gif] [-qt-gif] [-no-libpng]\n" + "[-qt-zlib] [-system-zlib] [-no-gif] [-no-libpng]\n" "[-qt-libpng] [-system-libpng] [-no-libtiff] [-qt-libtiff]\n" "[-system-libtiff] [-no-libjpeg] [-qt-libjpeg] [-system-libjpeg]\n" "[-no-libmng] [-qt-libmng] [-system-libmng] [-no-qt3support] [-mmx]\n" @@ -1794,7 +1792,6 @@ bool Configure::displayHelp() desc("ZLIB", "system", "-system-zlib", "Use zlib from the operating system.\nSee http://www.gzip.org/zlib\n"); desc("GIF", "no", "-no-gif", "Do not compile GIF reading support."); - desc("GIF", "auto", "-qt-gif", "Compile GIF reading support.\nSee also src/gui/image/qgifhandler_p.h\n"); desc("LIBPNG", "no", "-no-libpng", "Do not compile PNG support."); desc("LIBPNG", "qt", "-qt-libpng", "Use the libpng bundled with Qt."); @@ -1959,6 +1956,22 @@ QString Configure::findFileInPaths(const QString &fileName, const QString &paths return QString(); } +static QString mingwPaths(const QString &mingwPath, const QString &pathName) +{ + QString ret; + QDir mingwDir = QFileInfo(mingwPath).dir(); + const QFileInfoList subdirs = mingwDir.entryInfoList(QDir::Dirs | QDir::NoDotAndDotDot); + for (int i = 0 ;i < subdirs.length(); ++i) { + const QFileInfo &fi = subdirs.at(i); + const QString name = fi.fileName(); + if (name == pathName) + ret += fi.absoluteFilePath() + ';'; + else if (name.contains("mingw")) + ret += fi.absoluteFilePath() + QDir::separator() + pathName + ';'; + } + return ret; +} + bool Configure::findFile(const QString &fileName) { const QString file = fileName.toLower(); @@ -1969,18 +1982,22 @@ bool Configure::findFile(const QString &fileName) QString paths; if (file.endsWith(".h")) { if (!mingwPath.isNull()) { - if (!findFileInPaths(file, mingwPath + QLatin1String("/../include")).isNull()) + if (!findFileInPaths(file, mingwPaths(mingwPath, "include")).isNull()) return true; //now let's try the additional compiler path - QDir mingwLibDir = mingwPath + QLatin1String("/../lib/gcc/mingw32"); - foreach(const QFileInfo &version, mingwLibDir.entryInfoList(QDir::Dirs | QDir::NoDotAndDotDot)) { - if (!findFileInPaths(file, version.absoluteFilePath() + QLatin1String("/include")).isNull()) - return true; + + const QFileInfoList mingwConfigs = QDir(mingwPath + QLatin1String("/../lib/gcc")).entryInfoList(QDir::Dirs | QDir::NoDotAndDotDot); + for (int i = 0; i < mingwConfigs.length(); ++i) { + const QDir mingwLibDir = mingwConfigs.at(i).absoluteFilePath(); + foreach(const QFileInfo &version, mingwLibDir.entryInfoList(QDir::Dirs | QDir::NoDotAndDotDot)) { + if (!findFileInPaths(file, version.absoluteFilePath() + QLatin1String("/include")).isNull()) + return true; + } } } paths = QString::fromLocal8Bit(getenv("INCLUDE")); } else if (file.endsWith(".lib") || file.endsWith(".a")) { - if (!mingwPath.isNull() && !findFileInPaths(file, mingwPath + QLatin1String("/../lib")).isNull()) + if (!mingwPath.isNull() && !findFileInPaths(file, mingwPaths(mingwPath, "lib")).isNull()) return true; paths = QString::fromLocal8Bit(getenv("LIB")); } else { @@ -2133,13 +2150,8 @@ bool Configure::checkAvailability(const QString &part) else if (part == "INCREDIBUILD_XGE") available = findFile("BuildConsole.exe") && findFile("xgConsole.exe"); else if (part == "XMLPATTERNS") - { - /* MSVC 6.0 and MSVC 2002/7.0 has too poor C++ support for QtXmlPatterns. */ - return dictionary.value("QMAKESPEC") != "win32-msvc" - && dictionary.value("QMAKESPEC") != "win32-msvc.net" // Leave for now, since we can't be sure if they are using 2002 or 2003 with this spec - && dictionary.value("QMAKESPEC") != "win32-msvc2002" - && dictionary.value("EXCEPTIONS") == "yes"; - } else if (part == "PHONON") { + available = dictionary.value("EXCEPTIONS") == "yes"; + else if (part == "PHONON") { if (dictionary.contains("XQMAKESPEC") && dictionary["XQMAKESPEC"].startsWith("symbian")) { available = true; } else { @@ -3085,10 +3097,7 @@ void Configure::generateConfigfiles() tmpStream << "/* Machine byte-order */" << endl; tmpStream << "#define Q_BIG_ENDIAN 4321" << endl; tmpStream << "#define Q_LITTLE_ENDIAN 1234" << endl; - if (QSysInfo::ByteOrder == QSysInfo::BigEndian) - tmpStream << "#define Q_BYTE_ORDER Q_BIG_ENDIAN" << endl; - else - tmpStream << "#define Q_BYTE_ORDER Q_LITTLE_ENDIAN" << endl; + tmpStream << "#define Q_BYTE_ORDER Q_LITTLE_ENDIAN" << endl; tmpStream << endl << "// Compile time features" << endl; tmpStream << "#define QT_ARCH_" << dictionary["ARCHITECTURE"].toUpper() << endl; diff --git a/tools/configure/environment.cpp b/tools/configure/environment.cpp index 05fd567..8040c7a 100644 --- a/tools/configure/environment.cpp +++ b/tools/configure/environment.cpp @@ -75,8 +75,6 @@ struct CompilerInfo{ {CC_BORLAND, "Borland C++", 0, "bcc32.exe"}, {CC_MINGW, "MinGW (Minimalist GNU for Windows)", 0, "g++.exe"}, {CC_INTEL, "Intel(R) C++ Compiler for 32-bit applications", 0, "icl.exe"}, // xilink.exe, xilink5.exe, xilink6.exe, xilib.exe - {CC_MSVC6, "Microsoft (R) 32-bit C/C++ Optimizing Compiler (6.x)", "Software\\Microsoft\\VisualStudio\\6.0\\Setup\\Microsoft Visual C++\\ProductDir", "cl.exe"}, // link.exe, lib.exe - {CC_NET2002, "Microsoft (R) 32-bit C/C++ Optimizing Compiler.NET 2002 (7.0)", "Software\\Microsoft\\VisualStudio\\7.0\\Setup\\VC\\ProductDir", "cl.exe"}, // link.exe, lib.exe {CC_NET2003, "Microsoft (R) 32-bit C/C++ Optimizing Compiler.NET 2003 (7.1)", "Software\\Microsoft\\VisualStudio\\7.1\\Setup\\VC\\ProductDir", "cl.exe"}, // link.exe, lib.exe {CC_NET2005, "Microsoft (R) 32-bit C/C++ Optimizing Compiler.NET 2005 (8.0)", "Software\\Microsoft\\VisualStudio\\SxS\\VC7\\8.0", "cl.exe"}, // link.exe, lib.exe {CC_NET2008, "Microsoft (R) 32-bit C/C++ Optimizing Compiler.NET 2008 (9.0)", "Software\\Microsoft\\VisualStudio\\SxS\\VC7\\9.0", "cl.exe"}, // link.exe, lib.exe @@ -118,14 +116,6 @@ QString Environment::detectQMakeSpec() case CC_NET2003: spec = "win32-msvc2003"; break; - case CC_NET2002: - spec = "win32-msvc2002"; - break; - case CC_MSVC4: - case CC_MSVC5: - case CC_MSVC6: - spec = "win32-msvc"; - break; case CC_INTEL: spec = "win32-icc"; break; @@ -152,7 +142,7 @@ QString Environment::detectQMakeSpec() Compiler Environment::detectCompiler() { #ifndef Q_OS_WIN32 - return MSVC6; // Always generate MSVC 6.0 versions on other platforms + return CC_UNKNOWN; // Always generate CC_UNKNOWN on other platforms #else if(detectedCompiler != CC_UNKNOWN) return detectedCompiler; diff --git a/tools/configure/environment.h b/tools/configure/environment.h index e3e8629..6bb962f 100644 --- a/tools/configure/environment.h +++ b/tools/configure/environment.h @@ -50,10 +50,6 @@ enum Compiler { CC_BORLAND = 0x01, CC_MINGW = 0x02, CC_INTEL = 0x03, - CC_MSVC4 = 0x40, - CC_MSVC5 = 0x50, - CC_MSVC6 = 0x60, - CC_NET2002 = 0x70, CC_NET2003 = 0x71, CC_NET2005 = 0x80, CC_NET2008 = 0x90, |