From 051a0c794b050564c31d320861a87de2be55c1db Mon Sep 17 00:00:00 2001 From: Rafael Roquetto Date: Tue, 7 May 2013 23:40:38 +0200 Subject: Add -eventfd flag support to configure.exe The lack of eventfd(7) switches and auto detection caused cross-compilations to fail on Windows hosts, for builds targeting POSIX systems which do not support eventfd(7), such as QNX and BB10. Change-Id: Ic8f53c64066ece6f16d4dbc79c089b058401e632 Reviewed-by: Oswald Buddenhagen --- tools/configure/configureapp.cpp | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) (limited to 'tools/configure') diff --git a/tools/configure/configureapp.cpp b/tools/configure/configureapp.cpp index a18aac3209..fb8f8b8b71 100644 --- a/tools/configure/configureapp.cpp +++ b/tools/configure/configureapp.cpp @@ -243,6 +243,7 @@ Configure::Configure(int& argc, char** argv) dictionary[ "QT_GLIB" ] = "no"; dictionary[ "QT_ICONV" ] = "auto"; dictionary[ "QT_INOTIFY" ] = "auto"; + dictionary[ "QT_EVENTFD" ] = "auto"; dictionary[ "QT_CUPS" ] = "auto"; dictionary[ "CFG_GCC_SYSROOT" ] = "yes"; dictionary[ "SLOG2" ] = "no"; @@ -908,6 +909,10 @@ void Configure::parseCmdLine() dictionary[ "WERROR" ] = "yes"; } else if (configCmdLine.at(i) == "-no-warnings-are-errors") { dictionary[ "WERROR" ] = "no"; + } else if (configCmdLine.at(i) == "-no-eventfd") { + dictionary[ "QT_EVENTFD" ] = "no"; + } else if (configCmdLine.at(i) == "-eventfd") { + dictionary[ "QT_EVENTFD" ] = "yes"; } // Work around compiler nesting limitation @@ -1787,6 +1792,9 @@ bool Configure::displayHelp() desc("QT_INOTIFY", "yes", "-inotify", "Explicitly enable Qt inotify(7) support."); desc("QT_INOTIFY", "no", "-no-inotify", "Explicitly disable Qt inotify(7) support.\n"); + desc("QT_EVENTFD", "yes", "-eventfd", "Enable eventfd(7) support in the UNIX event loop."); + desc("QT_EVENTFD", "no", "-no-eventfd", "Disable eventfd(7) support in the UNIX event loop.\n"); + desc("LARGE_FILE", "yes", "-largefile", "Enables Qt to access files larger than 4 GB.\n"); desc("FONT_CONFIG", "yes", "-fontconfig", "Build with FontConfig support."); @@ -2181,6 +2189,8 @@ bool Configure::checkAvailability(const QString &part) available = tryCompileProject("unix/iconv") || tryCompileProject("unix/gnu-libiconv"); } else if (part == "INOTIFY") { available = tryCompileProject("unix/inotify"); + } else if (part == "QT_EVENTFD") { + available = tryCompileProject("unix/eventfd"); } else if (part == "CUPS") { available = (platform() != WINDOWS) && (platform() != WINDOWS_CE) && tryCompileProject("unix/cups"); } else if (part == "STACK_PROTECTOR_STRONG") { @@ -2323,6 +2333,9 @@ void Configure::autoDetection() dictionary["SLOG2"] = checkAvailability("SLOG2") ? "yes" : "no"; } + if (dictionary["QT_EVENTFD"] == "auto") + dictionary["QT_EVENTFD"] = checkAvailability("QT_EVENTFD") ? "yes" : "no"; + // Mark all unknown "auto" to the default value.. for (QMap::iterator i = dictionary.begin(); i != dictionary.end(); ++i) { if (i.value() == "auto") @@ -2722,6 +2735,9 @@ void Configure::generateOutputVars() if (dictionary["QT_INOTIFY"] == "yes") qtConfig += "inotify"; + if (dictionary["QT_EVENTFD"] == "yes") + qtConfig += "eventfd"; + if (dictionary["FONT_CONFIG"] == "yes") { qtConfig += "fontconfig"; qmakeVars += "QMAKE_CFLAGS_FONTCONFIG ="; @@ -3379,6 +3395,7 @@ void Configure::generateConfigfiles() if (dictionary["QT_ICONV"] == "no") qconfigList += "QT_NO_ICONV"; if (dictionary["QT_GLIB"] == "no") qconfigList += "QT_NO_GLIB"; if (dictionary["QT_INOTIFY"] == "no") qconfigList += "QT_NO_INOTIFY"; + if (dictionary["QT_EVENTFD"] == "no") qconfigList += "QT_NO_EVENTFD"; if (dictionary["REDUCE_EXPORTS"] == "yes") qconfigList += "QT_VISIBILITY_AVAILABLE"; if (dictionary["REDUCE_RELOCATIONS"] == "yes") qconfigList += "QT_REDUCE_RELOCATIONS"; @@ -3521,6 +3538,7 @@ void Configure::displayConfig() sout << "NIS support................." << dictionary[ "NIS" ] << endl; sout << "Iconv support..............." << dictionary[ "QT_ICONV" ] << endl; sout << "Inotify support............." << dictionary[ "QT_INOTIFY" ] << endl; + sout << "eventfd(7) support.........." << dictionary[ "QT_EVENTFD" ] << endl; sout << "Glib support................" << dictionary[ "QT_GLIB" ] << endl; sout << "CUPS support................" << dictionary[ "QT_CUPS" ] << endl; sout << "OpenVG support.............." << dictionary[ "OPENVG" ] << endl; -- cgit v1.2.3 From d37dc75116aeb55971ab44c84e8f10ed18b8a5aa Mon Sep 17 00:00:00 2001 From: Matt Fischer Date: Mon, 8 Apr 2013 17:07:13 -0500 Subject: Improve support for _PATH options Several modules, including DBus, MySQL, and OpenSSL have configure options of the form _PATH, which is used on Windows (where pkg-config is not present) to specify the locations of third-party libraries. These switches had been implemented by adding extra variables which were referenced in .pro files, to add the appropriate compiler and linker switches. This is undesirable because it means there are two independent paths for adding the switches to the build, which can get out of sync with each other, and indeed this had happened for some of the DBus tools. To remedy the situation, all three of the switches were reworked so that they added values directly to the principal variables that are used in the project files. This reduces maintenance, by ensuring that the pkg-config and non-pkg-config paths appear the same to the rest of the build system. Change-Id: Iae342f1d14b79fbcfef9fe38aadc803ad3141799 Reviewed-by: Oswald Buddenhagen --- tools/configure/configureapp.cpp | 24 +++++++++++++++--------- 1 file changed, 15 insertions(+), 9 deletions(-) (limited to 'tools/configure') diff --git a/tools/configure/configureapp.cpp b/tools/configure/configureapp.cpp index fb8f8b8b71..fa8456e447 100644 --- a/tools/configure/configureapp.cpp +++ b/tools/configure/configureapp.cpp @@ -988,7 +988,7 @@ void Configure::parseCmdLine() } else if (configCmdLine.at(i).startsWith("OPENSSL_LIBS_RELEASE=")) { opensslLibsRelease = configCmdLine.at(i); } else if (configCmdLine.at(i).startsWith("OPENSSL_PATH=")) { - opensslPath = QDir::fromNativeSeparators(configCmdLine.at(i)); + opensslPath = QDir::fromNativeSeparators(configCmdLine.at(i).section("=", 1)); } else if (configCmdLine.at(i).startsWith("PSQL_LIBS=")) { psqlLibs = configCmdLine.at(i); } else if (configCmdLine.at(i).startsWith("SYBASE=")) { @@ -996,9 +996,9 @@ void Configure::parseCmdLine() } else if (configCmdLine.at(i).startsWith("SYBASE_LIBS=")) { sybaseLibs = configCmdLine.at(i); } else if (configCmdLine.at(i).startsWith("DBUS_PATH=")) { - dbusPath = QDir::fromNativeSeparators(configCmdLine.at(i)); + dbusPath = QDir::fromNativeSeparators(configCmdLine.at(i).section("=", 1)); } else if (configCmdLine.at(i).startsWith("MYSQL_PATH=")) { - mysqlPath = QDir::fromNativeSeparators(configCmdLine.at(i)); + mysqlPath = QDir::fromNativeSeparators(configCmdLine.at(i).section("=", 1)); } else if (configCmdLine.at(i).startsWith("ZLIB_LIBS=")) { zlibLibs = QDir::fromNativeSeparators(configCmdLine.at(i)); } @@ -2811,13 +2811,19 @@ void Configure::generateOutputVars() } else if (opensslLibs.isEmpty()) { qmakeVars += QString("OPENSSL_LIBS = -lssleay32 -llibeay32"); } - if (!opensslPath.isEmpty()) - qmakeVars += opensslPath; + if (!opensslPath.isEmpty()) { + qmakeVars += QString("OPENSSL_CFLAGS += -I%1/include").arg(opensslPath); + qmakeVars += QString("OPENSSL_LIBS += -L%1/lib").arg(opensslPath); + } + } + if (dictionary[ "DBUS" ] != "no" && !dbusPath.isEmpty()) { + qmakeVars += QString("QT_CFLAGS_DBUS = -I%1/include").arg(dbusPath); + qmakeVars += QString("QT_LIBS_DBUS = -L%1/lib").arg(dbusPath); + } + if (dictionary[ "SQL_MYSQL" ] != "no" && !mysqlPath.isEmpty()) { + qmakeVars += QString("QT_CFLAGS_MYSQL = -I%1/include").arg(mysqlPath); + qmakeVars += QString("QT_LFLAGS_MYSQL = -L%1/lib").arg(mysqlPath); } - if (dictionary[ "DBUS" ] != "no" && !dbusPath.isEmpty()) - qmakeVars += dbusPath; - if (dictionary[ "SQL_MYSQL" ] != "no" && !mysqlPath.isEmpty()) - qmakeVars += mysqlPath; if (!psqlLibs.isEmpty()) qmakeVars += QString("QT_LFLAGS_PSQL=") + psqlLibs.section("=", 1); if (!zlibLibs.isEmpty()) -- cgit v1.2.3 From 8739487b1ce2dc2b93fe7ff283c76f6a56919f1b Mon Sep 17 00:00:00 2001 From: Oswald Buddenhagen Date: Wed, 8 May 2013 15:30:56 +0200 Subject: install host libraries into -hostprefix ... and introduce -hostlibdir configure option for symmetry. the libraries built for the host have no business in the target prefix. in principle this code would even support dynamically linked host libraries, but that's currently unused. Task-number: QTBUG-30591 Change-Id: I8e600fa4911a020fb0e87fbf7ef2f35647c7c4d5 Reviewed-by: Joerg Bornemann Reviewed-by: Ivan Romanov --- tools/configure/configureapp.cpp | 11 +++++++++++ 1 file changed, 11 insertions(+) (limited to 'tools/configure') diff --git a/tools/configure/configureapp.cpp b/tools/configure/configureapp.cpp index fa8456e447..fbc9941ac7 100644 --- a/tools/configure/configureapp.cpp +++ b/tools/configure/configureapp.cpp @@ -1171,6 +1171,13 @@ void Configure::parseCmdLine() dictionary[ "QT_HOST_BINS" ] = configCmdLine.at(i); } + else if (configCmdLine.at(i) == "-hostlibdir") { + ++i; + if (i == argCount) + break; + dictionary[ "QT_HOST_LIBS" ] = configCmdLine.at(i); + } + else if (configCmdLine.at(i) == "-hostdatadir") { ++i; if (i == argCount) @@ -1698,6 +1705,7 @@ bool Configure::displayHelp() desc( "-testsdir ", "Tests will be installed to \n(default PREFIX/tests)\n"); desc( "-hostbindir ", "Host executables will be installed to \n(default HOSTPREFIX/bin)"); + desc( "-hostlibdir ", "Host libraries will be installed to \n(default HOSTPREFIX/lib)"); desc( "-hostdatadir ", "Data used by qmake will be installed to \n(default HOSTPREFIX)"); #if !defined(EVAL) @@ -3758,6 +3766,8 @@ void Configure::generateQConfigCpp() haveHpx = true; if (dictionary["QT_HOST_BINS"].isEmpty()) dictionary["QT_HOST_BINS"] = haveHpx ? dictionary["QT_HOST_PREFIX"] + "/bin" : dictionary["QT_INSTALL_BINS"]; + if (dictionary["QT_HOST_LIBS"].isEmpty()) + dictionary["QT_HOST_LIBS"] = haveHpx ? dictionary["QT_HOST_PREFIX"] + "/lib" : dictionary["QT_INSTALL_LIBS"]; if (dictionary["QT_HOST_DATA"].isEmpty()) dictionary["QT_HOST_DATA"] = haveHpx ? dictionary["QT_HOST_PREFIX"] : dictionary["QT_INSTALL_ARCHDATA"]; @@ -3798,6 +3808,7 @@ void Configure::generateQConfigCpp() << " \"qt_ssrtpath=" << formatPath(dictionary["CFG_SYSROOT"]) << "\"," << endl << " \"qt_hpfxpath=" << formatPath(dictionary["QT_HOST_PREFIX"]) << "\"," << endl << " \"qt_hbinpath=" << formatPath(dictionary["QT_HOST_BINS"]) << "\"," << endl + << " \"qt_hlibpath=" << formatPath(dictionary["QT_HOST_LIBS"]) << "\"," << endl << " \"qt_hdatpath=" << formatPath(dictionary["QT_HOST_DATA"]) << "\"," << endl << " \"qt_targspec=" << targSpec << "\"," << endl << " \"qt_hostspec=" << hostSpec << "\"," << endl -- cgit v1.2.3 From 6b38524bba4254c06ac5811fdde66bcafb49632f Mon Sep 17 00:00:00 2001 From: Oswald Buddenhagen Date: Fri, 10 May 2013 18:21:27 +0200 Subject: get rid of syncqt wrapper scripts instead, rename it to syncqt.pl and rely on qtPrepareTool()'s new ability to correctly invoke it as a perl script even under windows. the wrappers themselves have been trivial at this point, so there is no added value in keeping them, either. Change-Id: I77cf65edbcfaa48ed1900defe940d4eb4b82d5b9 Reviewed-by: Thiago Macieira Reviewed-by: Joerg Bornemann --- tools/configure/configureapp.cpp | 24 +++--------------------- 1 file changed, 3 insertions(+), 21 deletions(-) (limited to 'tools/configure') diff --git a/tools/configure/configureapp.cpp b/tools/configure/configureapp.cpp index fbc9941ac7..00bc61a077 100644 --- a/tools/configure/configureapp.cpp +++ b/tools/configure/configureapp.cpp @@ -160,24 +160,6 @@ Configure::Configure(int& argc, char** argv) cout << "Preparing build tree..." << endl; QDir(buildPath).mkpath("bin"); - { //make a syncqt script(s) that can be used in the shadow - QFile syncqt(buildPath + "/bin/syncqt"); - // no QFile::Text, just in case the perl interpreter can't cope with them (unlikely) - if (syncqt.open(QFile::WriteOnly)) { - QTextStream stream(&syncqt); - stream << "#!/usr/bin/perl -w" << endl - << "require \"" << sourcePath + "/bin/syncqt\";" << endl; - } - QFile syncqt_bat(buildPath + "/bin/syncqt.bat"); - if (syncqt_bat.open(QFile::WriteOnly | QFile::Text)) { - QTextStream stream(&syncqt_bat); - stream << "@echo off" << endl - << "call " << QDir::toNativeSeparators(sourcePath + "/bin/syncqt.bat") - << " %*" << endl; - syncqt_bat.close(); - } - } - //copy the mkspecs buildDir.mkpath("mkspecs"); if (!Environment::cpdir(sourcePath + "/mkspecs", buildPath + "/mkspecs")){ @@ -2029,8 +2011,7 @@ QString Configure::defaultTo(const QString &option) return "auto"; if (option == "SYNCQT" - && (!QFile::exists(sourcePath + "/bin/syncqt") || - !QFile::exists(sourcePath + "/bin/syncqt.bat"))) + && (!QFile::exists(sourcePath + "/bin/syncqt.pl"))) return "no"; return "yes"; @@ -3700,7 +3681,8 @@ void Configure::generateHeaders() if (!QStandardPaths::findExecutable(QStringLiteral("perl.exe")).isEmpty()) { cout << "Running syncqt..." << endl; QStringList args; - args += buildPath + "/bin/syncqt.bat"; + args << "perl" << "-w"; + args += sourcePath + "/bin/syncqt.pl"; args << "-minimal" << "-module" << "QtCore"; args += sourcePath; int retc = Environment::execute(args, QStringList(), QStringList()); -- cgit v1.2.3 From 62b4525d6f5025dbddb0a7dbd9514256eff3cd0f Mon Sep 17 00:00:00 2001 From: Oswald Buddenhagen Date: Tue, 21 May 2013 14:25:58 +0200 Subject: purge obsolete EVAL #ifdefs clearly, nobody's been maintaining them for an extended period of time. Change-Id: I41c6b40026f107d34f7964934f36bc727fb6b795 Reviewed-by: Joerg Bornemann --- tools/configure/configureapp.cpp | 37 +------------------------------------ tools/configure/configureapp.h | 10 ---------- tools/configure/main.cpp | 4 ---- 3 files changed, 1 insertion(+), 50 deletions(-) (limited to 'tools/configure') diff --git a/tools/configure/configureapp.cpp b/tools/configure/configureapp.cpp index 00bc61a077..53e6a2de80 100644 --- a/tools/configure/configureapp.cpp +++ b/tools/configure/configureapp.cpp @@ -395,7 +395,6 @@ void Configure::parseCmdLine() int i = 0; const QStringList imageFormats = QStringList() << "gif" << "png" << "jpeg"; -#if !defined(EVAL) if (argCount < 1) // skip rest if no arguments ; else if (configCmdLine.at(i) == "-redo") { @@ -416,7 +415,6 @@ void Configure::parseCmdLine() i = 0; } argCount = configCmdLine.size(); -#endif bool isDeviceMkspec = false; @@ -441,7 +439,6 @@ void Configure::parseCmdLine() || configCmdLine.at(i) == "-?") dictionary[ "HELP" ] = "yes"; -#if !defined(EVAL) else if (configCmdLine.at(i) == "-qconfig") { ++i; if (i == argCount) @@ -493,9 +490,6 @@ void Configure::parseCmdLine() dictionary[ "FORCE_ASSERTS" ] = "yes"; } - -#endif - else if (configCmdLine.at(i) == "-platform") { ++i; if (i == argCount) @@ -515,8 +509,6 @@ void Configure::parseCmdLine() // do nothing } - -#if !defined(EVAL) else if (configCmdLine.at(i) == "-no-zlib") { // No longer supported since Qt 4.4.0 // But save the information for later so that we can print a warning @@ -773,7 +765,7 @@ void Configure::parseCmdLine() else if (configCmdLine.at(i).startsWith("-no-imageformat-") && imageFormats.contains(configCmdLine.at(i).section('-', 3))) dictionary[ configCmdLine.at(i).section('-', 3).toUpper() ] = "no"; -#endif + // IDE project generation ----------------------------------- else if (configCmdLine.at(i) == "-no-vcproj") dictionary[ "VCPROJFILES" ] = "no"; @@ -788,7 +780,6 @@ void Configure::parseCmdLine() dictionary[ "NATIVE_GESTURES" ] = "yes"; else if (configCmdLine.at(i) == "-no-native-gestures") dictionary[ "NATIVE_GESTURES" ] = "no"; -#if !defined(EVAL) // Others --------------------------------------------------- else if (configCmdLine.at(i) == "-widgets") dictionary[ "WIDGETS" ] = "yes"; @@ -1294,8 +1285,6 @@ void Configure::parseCmdLine() cout << "Unknown option " << configCmdLine.at(i) << endl; break; } - -#endif } // Ensure that QMAKESPEC exists in the mkspecs folder @@ -1419,7 +1408,6 @@ void Configure::parseCmdLine() if (dictionary["FORCE_ASSERTS"] == "yes") qtConfig += "force_asserts"; -#if !defined(EVAL) for (QStringList::Iterator dis = disabledModules.begin(); dis != disabledModules.end(); ++dis) { modules.removeAll((*dis)); } @@ -1434,10 +1422,8 @@ void Configure::parseCmdLine() if ((dictionary[ "REDO" ] != "yes") && (dictionary[ "HELP" ] != "yes")) saveCmdLine(); -#endif } -#if !defined(EVAL) void Configure::validateArgs() { // Validate the specified config @@ -1484,8 +1470,6 @@ void Configure::validateArgs() else qmakeConfig += (*config) + "-config"; } -#endif - // Output helper functions --------------------------------[ Start ]- /*! @@ -1690,7 +1674,6 @@ bool Configure::displayHelp() desc( "-hostlibdir ", "Host libraries will be installed to \n(default HOSTPREFIX/lib)"); desc( "-hostdatadir ", "Data used by qmake will be installed to \n(default HOSTPREFIX)"); -#if !defined(EVAL) desc("\nConfigure options:\n\n"); desc(" The defaults (*) are usually acceptable. A plus (+) denotes a default value" @@ -1761,7 +1744,6 @@ bool Configure::displayHelp() desc("OPENVG", "no","-no-openvg", "Disables OpenVG functionality."); desc("OPENVG", "yes","-openvg", "Enables OpenVG functionality.\n"); desc( "-force-asserts", "Activate asserts in release mode.\n"); -#endif desc( "-platform ", "The operating system and compiler you are building on.\n(default %QMAKESPEC%)\n"); desc( "-xplatform ", "The operating system and compiler you are cross compiling to.\n"); desc( "", "See the README file for a list of supported operating systems and compilers.\n", false, ' '); @@ -1802,18 +1784,15 @@ bool Configure::displayHelp() desc("WERROR", "yes", "-warnings-are-errors", "Make warnings be treated as errors."); desc("WERROR", "no", "-no-warnings-are-errors","Make warnings be treated normally."); -#if !defined(EVAL) desc( "-qtnamespace ", "Wraps all Qt library code in 'namespace name {...}'."); desc( "-qtlibinfix ", "Renames all Qt* libs to Qt*.\n"); desc( "-D ", "Add an explicit define to the preprocessor."); desc( "-I ", "Add an explicit include path."); desc( "-L ", "Add an explicit library path."); desc( "-l ", "Add an explicit library name, residing in a librarypath.\n"); -#endif desc( "-help, -h, -?", "Display this information.\n"); -#if !defined(EVAL) // 3rd party stuff options go below here -------------------------------------------------------------------------------- desc("Third Party Libraries:\n\n"); @@ -1848,7 +1827,6 @@ bool Configure::displayHelp() desc("ANGLE", "yes", "-angle", "Use the ANGLE implementation of OpenGL ES 2.0."); desc("ANGLE", "d3d11", "-angle-d3d11", "Use the Direct3D 11-based ANGLE implementation of OpenGL ES 2.0."); desc("ANGLE", "no", "-no-angle", "Do not use ANGLE.\nSee http://code.google.com/p/angleproject/\n"); -#endif // Qt\Windows only options go below here -------------------------------------------------------------------------------- desc("\nQt for Windows only:\n\n"); @@ -1860,7 +1838,6 @@ bool Configure::displayHelp() desc("PLUGIN_MANIFESTS", "no", "-no-plugin-manifests", "Do not embed manifests in plugins."); desc("PLUGIN_MANIFESTS", "yes", "-plugin-manifests", "Embed manifests in plugins.\n"); -#if !defined(EVAL) desc("BUILD_QMAKE", "no", "-no-qmake", "Do not compile qmake."); desc("BUILD_QMAKE", "yes", "-qmake", "Compile qmake.\n"); @@ -1921,7 +1898,6 @@ bool Configure::displayHelp() desc( "", qPrintable(QString(" %1").arg(allConfigs.at(i))), false, ' '); printf("\n"); */ -#endif desc( "-loadconfig ", "Run configure with the parameters from file configure_.cache."); desc( "-saveconfig ", "Run configure and save the parameters in file configure_.cache."); desc( "-redo", "Run configure with the same parameters as last time.\n"); @@ -2867,7 +2843,6 @@ void Configure::generateOutputVars() } } -#if !defined(EVAL) void Configure::generateCachefile() { // Generate .qmake.cache @@ -3217,7 +3192,6 @@ void Configure::generateQConfigPri() configFile.close(); } } -#endif QString Configure::addDefine(QString def) { @@ -3251,7 +3225,6 @@ QString Configure::addDefine(QString def) return result; } -#if !defined(EVAL) void Configure::generateConfigfiles() { QDir(buildPath).mkpath("src/corelib/global"); @@ -3457,9 +3430,7 @@ void Configure::generateConfigfiles() qdeviceFile.close(); } } -#endif -#if !defined(EVAL) void Configure::displayConfig() { fstream sout; @@ -3669,9 +3640,7 @@ void Configure::displayConfig() cout << str << endl; } } -#endif -#if !defined(EVAL) void Configure::generateHeaders() { if (dictionary["SYNCQT"] == "auto") @@ -3959,7 +3928,6 @@ void Configure::buildQmake() } } -#endif void Configure::appendMakeItem(int inList, const QString &item) { @@ -4062,8 +4030,6 @@ Configure::ProjectType Configure::projectType(const QString& proFileName) return App; } -#if !defined(EVAL) - bool Configure::showLicense(QString orgLicenseFile) { if (dictionary["LICENSE_CONFIRMED"] == "yes") { @@ -4242,7 +4208,6 @@ void Configure::saveCmdLine() } } } -#endif // !EVAL bool Configure::isDone() { diff --git a/tools/configure/configureapp.h b/tools/configure/configureapp.h index 3cb5de8520..85fc70d9e5 100644 --- a/tools/configure/configureapp.h +++ b/tools/configure/configureapp.h @@ -57,9 +57,7 @@ public: ~Configure(); void parseCmdLine(); -#if !defined(EVAL) void validateArgs(); -#endif bool displayHelp(); QString defaultTo(const QString &option); @@ -70,27 +68,21 @@ public: bool verifyConfiguration(); void generateOutputVars(); -#if !defined(EVAL) void generateHeaders(); void generateBuildKey(); void generateCachefile(); void displayConfig(); -#endif void generateMakefiles(); void appendMakeItem(int inList, const QString &item); -#if !defined(EVAL) void generateConfigfiles(); void detectArch(); void generateQConfigPri(); void generateSystemVars(); -#endif void showSummary(); QString firstLicensePath(); -#if !defined(EVAL) bool showLicense(QString licenseFile); void readLicense(); -#endif QString addDefine(QString def); @@ -172,10 +164,8 @@ private: QString locateFile(const QString &fileName) const; bool findFile(const QString &fileName) const { return !locateFile(fileName).isEmpty(); } static QString findFileInPaths(const QString &fileName, const QStringList &paths); -#if !defined(EVAL) void reloadCmdLine(); void saveCmdLine(); -#endif bool tryCompileProject(const QString &projectPath, const QString &extraOptions = QString()); bool compilerSupportsFlag(const QString &compilerAndArgs); diff --git a/tools/configure/main.cpp b/tools/configure/main.cpp index c4154c8f38..efb3a893b7 100644 --- a/tools/configure/main.cpp +++ b/tools/configure/main.cpp @@ -55,9 +55,7 @@ int runConfigure( int argc, char** argv ) return 3; app.parseCmdLine(); -#if !defined(EVAL) app.validateArgs(); -#endif if (!app.isOk()) return 3; if( app.displayHelp() ) @@ -95,7 +93,6 @@ int runConfigure( int argc, char** argv ) app.generateOutputVars(); -#if !defined(EVAL) if( !app.isDone() ) app.generateCachefile(); if( !app.isDone() ) @@ -110,7 +107,6 @@ int runConfigure( int argc, char** argv ) app.generateQConfigPri(); if (!app.isDone()) app.displayConfig(); -#endif if( !app.isDone() ) app.generateMakefiles(); if( !app.isDone() ) -- cgit v1.2.3 From c21a1621cee0f3d16404e250d57bcec2704e2390 Mon Sep 17 00:00:00 2001 From: Oswald Buddenhagen Date: Fri, 17 May 2013 17:51:13 +0200 Subject: purge buildkey-related dead code Change-Id: I196dbe33b349d437450a5ea68befb3d6bfe1b574 Reviewed-by: Joerg Bornemann --- tools/configure/configureapp.cpp | 46 ---------------------------------------- tools/configure/configureapp.h | 1 - tools/configure/main.cpp | 2 -- 3 files changed, 49 deletions(-) (limited to 'tools/configure') diff --git a/tools/configure/configureapp.cpp b/tools/configure/configureapp.cpp index 53e6a2de80..4f973a4398 100644 --- a/tools/configure/configureapp.cpp +++ b/tools/configure/configureapp.cpp @@ -2388,52 +2388,6 @@ bool Configure::verifyConfiguration() return true; } -/* - Things that affect the Qt API/ABI: - Options: - minimal-config small-config medium-config large-config full-config - - Options: - debug release - - Things that do not affect the Qt API/ABI: - system-jpeg no-jpeg jpeg - system-png no-png png - system-zlib no-zlib zlib - no-gif gif - dll staticlib - - nocrosscompiler - GNUmake - largefile - nis - nas - tablet - - X11 : x11sm xinerama xcursor xfixes xrandr xrender fontconfig xkb - Embedded: embedded freetype -*/ -void Configure::generateBuildKey() -{ - QString spec = dictionary["QMAKESPEC"]; - - QString compiler = "msvc"; // ICC is compatible - if (spec.endsWith("-g++")) - compiler = "mingw"; - else if (spec.endsWith("-borland")) - compiler = "borland"; - - // Build options which changes the Qt API/ABI - QStringList build_options; - if (!dictionary["QCONFIG"].isEmpty()) - build_options += dictionary["QCONFIG"] + "-config "; - build_options.sort(); - - // Sorted defines that start with QT_NO_ - QStringList build_defines = qmakeDefines.filter(QRegExp("^QT_NO_")); - build_defines.sort(); -} - void Configure::generateSystemVars() { // Generate an empty .qmake.cache file for config.tests diff --git a/tools/configure/configureapp.h b/tools/configure/configureapp.h index 85fc70d9e5..18e61b65ae 100644 --- a/tools/configure/configureapp.h +++ b/tools/configure/configureapp.h @@ -69,7 +69,6 @@ public: void generateOutputVars(); void generateHeaders(); - void generateBuildKey(); void generateCachefile(); void displayConfig(); void generateMakefiles(); diff --git a/tools/configure/main.cpp b/tools/configure/main.cpp index efb3a893b7..59eb690bd9 100644 --- a/tools/configure/main.cpp +++ b/tools/configure/main.cpp @@ -95,8 +95,6 @@ int runConfigure( int argc, char** argv ) if( !app.isDone() ) app.generateCachefile(); - if( !app.isDone() ) - app.generateBuildKey(); if( !app.isDone() ) app.generateConfigfiles(); // must be done after buildQmake() -- cgit v1.2.3 From 836260974fb65bf3826d41bd6ffe6af1102de608 Mon Sep 17 00:00:00 2001 From: Oswald Buddenhagen Date: Tue, 21 May 2013 14:27:24 +0200 Subject: purge dead output-related code QTBUILDINSTRUCTION is not evaluated anywhere anymore. Change-Id: Ie23f61f5a25594591efdafdc49e279f13623b049 Reviewed-by: Joerg Bornemann --- tools/configure/configureapp.cpp | 12 ------------ 1 file changed, 12 deletions(-) (limited to 'tools/configure') diff --git a/tools/configure/configureapp.cpp b/tools/configure/configureapp.cpp index 4f973a4398..bbc27e36d8 100644 --- a/tools/configure/configureapp.cpp +++ b/tools/configure/configureapp.cpp @@ -1333,18 +1333,6 @@ void Configure::parseCmdLine() } } - // Tell the user how to proceed building Qt after configure finished its job - dictionary["QTBUILDINSTRUCTION"] = dictionary["MAKE"]; - if (dictionary.contains("XQMAKESPEC")) { - if (dictionary["XQMAKESPEC"].startsWith("wince")) { - dictionary["QTBUILDINSTRUCTION"] = - QString("setcepaths.bat ") + dictionary["XQMAKESPEC"] + QString(" && ") + dictionary["MAKE"]; - } - } - - // Tell the user how to confclean before the next configure - dictionary["CONFCLEANINSTRUCTION"] = dictionary["MAKE"] + QString(" confclean"); - if (isDeviceMkspec) { const QStringList devices = mkspecs.filter("devices/", Qt::CaseInsensitive); const QStringList family = devices.filter(dictionary["XQMAKESPEC"], Qt::CaseInsensitive); -- cgit v1.2.3 From f18b0810be29acbebeab86e7571d1cb4062ee763 Mon Sep 17 00:00:00 2001 From: Oswald Buddenhagen Date: Fri, 17 May 2013 17:53:03 +0200 Subject: reality adjustment: rename generateSystemVars() => prepareConfigTests() Change-Id: I3f9cd8b8cdb54d682d0207f28168f4e518b98280 Reviewed-by: Thiago Macieira --- tools/configure/configureapp.cpp | 2 +- tools/configure/configureapp.h | 2 +- tools/configure/main.cpp | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) (limited to 'tools/configure') diff --git a/tools/configure/configureapp.cpp b/tools/configure/configureapp.cpp index bbc27e36d8..bb314280cf 100644 --- a/tools/configure/configureapp.cpp +++ b/tools/configure/configureapp.cpp @@ -2376,7 +2376,7 @@ bool Configure::verifyConfiguration() return true; } -void Configure::generateSystemVars() +void Configure::prepareConfigTests() { // Generate an empty .qmake.cache file for config.tests QDir buildDir(buildPath); diff --git a/tools/configure/configureapp.h b/tools/configure/configureapp.h index 18e61b65ae..3014e409f9 100644 --- a/tools/configure/configureapp.h +++ b/tools/configure/configureapp.h @@ -76,7 +76,7 @@ public: void generateConfigfiles(); void detectArch(); void generateQConfigPri(); - void generateSystemVars(); + void prepareConfigTests(); void showSummary(); QString firstLicensePath(); diff --git a/tools/configure/main.cpp b/tools/configure/main.cpp index 59eb690bd9..3a6390d5c2 100644 --- a/tools/configure/main.cpp +++ b/tools/configure/main.cpp @@ -78,7 +78,7 @@ int runConfigure( int argc, char** argv ) if (!app.isOk()) return 3; - app.generateSystemVars(); + app.prepareConfigTests(); if (!app.isOk()) return 3; -- cgit v1.2.3 From 23ee57c5e97c2108c20929bac08c7f0bbb741a4c Mon Sep 17 00:00:00 2001 From: Oswald Buddenhagen Date: Fri, 17 May 2013 18:01:14 +0200 Subject: move detectArch() call right after autoDetection() MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit it belongs there (technically, it would not hurt to actually call it from within autoDetection()). Task-number: QTBUG-31095 Change-Id: I7eb53762513eb9cebfd22317c8f44fe123eb91dd Reviewed-by: Thiago Macieira Reviewed-by: Tor Arne Vestbø --- tools/configure/main.cpp | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) (limited to 'tools/configure') diff --git a/tools/configure/main.cpp b/tools/configure/main.cpp index 3a6390d5c2..9beee36a50 100644 --- a/tools/configure/main.cpp +++ b/tools/configure/main.cpp @@ -68,16 +68,20 @@ int runConfigure( int argc, char** argv ) if (!app.isOk()) return 3; + // Source file with path settings. Needed by qmake. app.generateQConfigCpp(); + // Bootstrapped includes. Needed by qmake. app.generateHeaders(); if (!app.isOk()) return 3; + // Bootstrap qmake. Needed by config tests. app.buildQmake(); if (!app.isOk()) return 3; + // Prepare the config test build directory. app.prepareConfigTests(); if (!app.isOk()) return 3; @@ -85,6 +89,9 @@ int runConfigure( int argc, char** argv ) // Auto-detect modules and settings. app.autoDetection(); + // ... and the CPU architectures. + app.detectArch(); + // After reading all command-line arguments, and doing all the // auto-detection, it's time to do some last minute validation. // If the validation fails, we cannot continue. @@ -97,10 +104,6 @@ int runConfigure( int argc, char** argv ) app.generateCachefile(); if( !app.isDone() ) app.generateConfigfiles(); - // must be done after buildQmake() - if (!app.isDone()) - app.detectArch(); - // must be done after detectArch() if (!app.isDone()) app.generateQConfigPri(); if (!app.isDone()) -- cgit v1.2.3 From 7582bb51f39f2336e9d14b83206873bbb3e47de3 Mon Sep 17 00:00:00 2001 From: Ray Donnelly Date: Tue, 14 May 2013 02:02:21 +0100 Subject: Android: Disable xkbcommon in configure.exe Task-number: QTBUG-31220 Change-Id: I711fa5d37cb58216199cc0ce479a14a3300d8cb8 Reviewed-by: Oswald Buddenhagen --- tools/configure/configureapp.cpp | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'tools/configure') diff --git a/tools/configure/configureapp.cpp b/tools/configure/configureapp.cpp index bb314280cf..a030351443 100644 --- a/tools/configure/configureapp.cpp +++ b/tools/configure/configureapp.cpp @@ -1622,6 +1622,7 @@ void Configure::applySpecSpecifics() dictionary[ "ANGLE" ] = "no"; dictionary[ "REDUCE_RELOCATIONS" ] = "yes"; dictionary[ "QT_GETIFADDRS" ] = "no"; + dictionary[ "QT_XKBCOMMON" ] = "no"; } } @@ -2812,6 +2813,9 @@ void Configure::generateCachefile() if (dictionary["QT_EDITION"] != "QT_EDITION_OPENSOURCE") moduleStream << "DEFINES *= QT_EDITION=QT_EDITION_DESKTOP" << endl; + if (dictionary["QT_XKBCOMMON"] == "no") + moduleStream << "DEFINES += QT_NO_XKBCOMMON" << endl; + if (dictionary["CETEST"] == "yes") { moduleStream << "QT_CE_RAPI_INC = " << formatPath(dictionary["QT_CE_RAPI_INC"]) << endl; moduleStream << "QT_CE_RAPI_LIB = " << formatPath(dictionary["QT_CE_RAPI_LIB"]) << endl; -- cgit v1.2.3