From a674879a8e070a8fbb85110c0bba3eed212c16b4 Mon Sep 17 00:00:00 2001 From: Shane Kearns Date: Mon, 9 Nov 2009 14:22:17 +0100 Subject: Remove temp dirs workaround for raptor builds only Webkit cannot build because of too long command lines in the sbsv2 config. There is an alternative workaround in raptor for the relative include paths problem, i.e. "sbs -c winscw_udeb.mwccinc" Removing the temp dirs from being created and added to systeminclude makes the command line short enough again that webkit can be compiled. Reviewed-By: Miikka Heikkinen Based on following commit from the no-tmp-dirs branch: commit 33e8c420bb40ca6194d29f96ef2fbd0f18340e6b Author: Iain Date: Wed Oct 7 13:45:48 2009 +0200 First attempt at removing the tmp dirs workaround on Symbian OS I may not have caught all the places where it is used, but MMP files look OK afterwards. TODO: Slightly concerned that I've trimmed too much from the abld generator as I think that the bit I cut was also used for other temp dirs --- .../flm/qt/qmake_generate_temp_dirs.flm | 22 ------------ mkspecs/symbian-sbsv2/flm/qt/qt.xml | 5 --- qmake/generators/symbian/symmake.cpp | 11 +----- qmake/generators/symbian/symmake.h | 1 + qmake/generators/symbian/symmake_abld.cpp | 14 ++++++++ qmake/generators/symbian/symmake_abld.h | 1 + qmake/generators/symbian/symmake_sbsv2.cpp | 40 +++++++++------------- qmake/generators/symbian/symmake_sbsv2.h | 1 + 8 files changed, 34 insertions(+), 61 deletions(-) delete mode 100644 mkspecs/symbian-sbsv2/flm/qt/qmake_generate_temp_dirs.flm diff --git a/mkspecs/symbian-sbsv2/flm/qt/qmake_generate_temp_dirs.flm b/mkspecs/symbian-sbsv2/flm/qt/qmake_generate_temp_dirs.flm deleted file mode 100644 index ca6cca9..0000000 --- a/mkspecs/symbian-sbsv2/flm/qt/qmake_generate_temp_dirs.flm +++ /dev/null @@ -1,22 +0,0 @@ -# /**************************************************************************** -# ** -# ** Copyright (C) 2009 Nokia Corporation and/or its subsidiary(-ies). -# ** Contact: Nokia Corporation (qt-info@nokia.com) -# ** -# ** This file is part of symbian-sbsv2 mkspec. -# ** -# ****************************************************************************/ - -include $(FLMHOME)/metaflm.mk - -SINGLETON:=$(call sanitise,TEMP_DIRS_$(EXTENSION_ROOT)) - -ifeq ($($(SINGLETON)),) -$(SINGLETON):=1 -$(call makepath,$(DIRS)) -$(eval $(call GenerateStandardCleanTarget,'',$(DIRS))) -endif - - - - diff --git a/mkspecs/symbian-sbsv2/flm/qt/qt.xml b/mkspecs/symbian-sbsv2/flm/qt/qt.xml index 5074e47..c99b5e2 100644 --- a/mkspecs/symbian-sbsv2/flm/qt/qt.xml +++ b/mkspecs/symbian-sbsv2/flm/qt/qt.xml @@ -35,11 +35,6 @@ - - - - diff --git a/qmake/generators/symbian/symmake.cpp b/qmake/generators/symbian/symmake.cpp index 8ec4b3f..1326a49 100644 --- a/qmake/generators/symbian/symmake.cpp +++ b/qmake/generators/symbian/symmake.cpp @@ -610,19 +610,10 @@ void SymbianMakefileGenerator::initMmpVariables() incpaths << project->values("UI_HEADERS_DIR"); incpaths << project->values("UI_DIR"); - QString epocPath("epoc32"); for (int j = 0; j < incpaths.size(); ++j) { QString includepath = canonizePath(incpaths.at(j)); appendIfnotExist(sysincspaths, includepath); - // As a workaround for Symbian toolchain insistence to treat include - // statements as relative to source file rather than the file they appear in, - // we generate extra temporary include directories to make - // relative include paths used in various headers to work properly. - // Note that this is not a fix-all solution; it's just a stop-gap measure - // to make Qt itself build until toolchain can support relative includes in - // a way that Qt expects. - if (!includepath.contains(epocPath)) // No temp dirs for epoc includes - appendIfnotExist(sysincspaths, includepath + QString("/" QT_EXTRA_INCLUDE_DIR)); + appendAbldTempDirs(sysincspaths, includepath); } // Remove duplicate include path entries diff --git a/qmake/generators/symbian/symmake.h b/qmake/generators/symbian/symmake.h index 36f6e05..a3e2c17 100644 --- a/qmake/generators/symbian/symmake.h +++ b/qmake/generators/symbian/symmake.h @@ -147,6 +147,7 @@ protected: virtual void writeBldInfMkFilePart(QTextStream& t, bool addDeploymentExtension) = 0; virtual void writeMkFile(const QString& wrapperFileName, bool deploymentOnly) = 0; virtual void writeWrapperMakefile(QFile& wrapperFile, bool isPrimaryMakefile) = 0; + virtual void appendAbldTempDirs(QStringList& sysincspaths, QString includepath) = 0; public: diff --git a/qmake/generators/symbian/symmake_abld.cpp b/qmake/generators/symbian/symmake_abld.cpp index 4d1673b..1b5464f 100644 --- a/qmake/generators/symbian/symmake_abld.cpp +++ b/qmake/generators/symbian/symmake_abld.cpp @@ -450,3 +450,17 @@ void SymbianAbldMakefileGenerator::writeBldInfMkFilePart(QTextStream& t, bool ad t << "gnumakefile " << gnuMakefileName << endl; } } + +void SymbianAbldMakefileGenerator::appendAbldTempDirs(QStringList& sysincspaths, QString includepath) +{ + // As a workaround for Symbian toolchain insistence to treat include + // statements as relative to source file rather than the file they appear in, + // we generate extra temporary include directories to make + // relative include paths used in various headers to work properly. + // Note that this is not a fix-all solution; it's just a stop-gap measure + // to make Qt itself build until toolchain can support relative includes in + // a way that Qt expects. + QString epocPath("epoc32"); + if (!includepath.contains(epocPath)) // No temp dirs for epoc includes + appendIfnotExist(sysincspaths, includepath + QString("/" QT_EXTRA_INCLUDE_DIR)); +} diff --git a/qmake/generators/symbian/symmake_abld.h b/qmake/generators/symbian/symmake_abld.h index f844096..11b9cd1 100644 --- a/qmake/generators/symbian/symmake_abld.h +++ b/qmake/generators/symbian/symmake_abld.h @@ -55,6 +55,7 @@ protected: virtual void writeBldInfMkFilePart(QTextStream& t, bool addDeploymentExtension); virtual void writeMkFile(const QString& wrapperFileName, bool deploymentOnly); virtual void writeWrapperMakefile(QFile& wrapperFile, bool isPrimaryMakefile); + virtual void appendAbldTempDirs(QStringList& sysincspaths, QString includepath); void writeStoreBuildTarget(QTextStream &t); bool writeDeploymentTargets(QTextStream &t); diff --git a/qmake/generators/symbian/symmake_sbsv2.cpp b/qmake/generators/symbian/symmake_sbsv2.cpp index cad2736..5e624de 100644 --- a/qmake/generators/symbian/symmake_sbsv2.cpp +++ b/qmake/generators/symbian/symmake_sbsv2.cpp @@ -182,15 +182,22 @@ void SymbianSbsv2MakefileGenerator::writeWrapperMakefile(QFile& wrapperFile, boo } t << endl; + QString winscw("winscw"); // For more specific builds, targets are in this form: build-platform, e.g. release-armv5 foreach(QString item, debugPlatforms) { t << "debug-" << item << ": " << BLD_INF_FILENAME << endl; - t << "\t$(SBS) -c " << item << "_udeb" << testClause << endl; + if(QString::compare(item, winscw) == 0) + t << "\t$(SBS) -c " << item << "_udeb.mwccinc" << testClause << endl; + else + t << "\t$(SBS) -c " << item << "_udeb" << testClause << endl; } foreach(QString item, releasePlatforms) { t << "release-" << item << ": " << BLD_INF_FILENAME << endl; - t << "\t$(SBS) -c " << item << "_urel" << testClause << endl; + if(QString::compare(item, winscw) == 0) + t << "\t$(SBS) -c " << item << "_urel.mwccinc" << testClause << endl; + else + t << "\t$(SBS) -c " << item << "_urel" << testClause << endl; } t << endl; @@ -379,28 +386,6 @@ void SymbianSbsv2MakefileGenerator::writeBldInfExtensionRulesPart(QTextStream& t t << "END" << endl; } - // Generate temp dirs - QString tempDirs; - for (QMap::iterator it = systeminclude.begin(); it != systeminclude.end(); ++it) { - QStringList values = it.value(); - for (int i = 0; i < values.size(); ++i) { - QString value = values.at(i); - if (value.endsWith("/" QT_EXTRA_INCLUDE_DIR)) { - value = fileInfo(value).absoluteFilePath(); - tempDirs.append(value); - tempDirs.append(" "); - } - } - } - - if (tempDirs.size()) - tempDirs.chop(1); // Remove final space - - t << "START EXTENSION qt/qmake_generate_temp_dirs" << endl; - t << "OPTION DIRS " << tempDirs << endl; - t << "END" << endl; - t << endl; - t << "START EXTENSION qt/qmake_store_build" << endl; t << "END" << endl; t << endl; @@ -414,3 +399,10 @@ void SymbianSbsv2MakefileGenerator::writeBldInfMkFilePart(QTextStream& t, bool a Q_UNUSED(t); Q_UNUSED(addDeploymentExtension); } + +void SymbianSbsv2MakefileGenerator::appendAbldTempDirs(QStringList& sysincspaths, QString includepath) +{ + //Do nothing + Q_UNUSED(sysincspaths); + Q_UNUSED(includepath); +} diff --git a/qmake/generators/symbian/symmake_sbsv2.h b/qmake/generators/symbian/symmake_sbsv2.h index 1cbddb3..9472b68 100644 --- a/qmake/generators/symbian/symmake_sbsv2.h +++ b/qmake/generators/symbian/symmake_sbsv2.h @@ -55,6 +55,7 @@ protected: virtual void writeBldInfMkFilePart(QTextStream& t, bool addDeploymentExtension); virtual void writeMkFile(const QString& wrapperFileName, bool deploymentOnly); virtual void writeWrapperMakefile(QFile& wrapperFile, bool isPrimaryMakefile); + virtual void appendAbldTempDirs(QStringList& sysincspaths, QString includepath); public: -- cgit v0.12