summaryrefslogtreecommitdiffstats
path: root/qmake
diff options
context:
space:
mode:
authorQt Continuous Integration System <qt-info@nokia.com>2010-02-22 15:36:25 +0100
committerQt Continuous Integration System <qt-info@nokia.com>2010-02-22 15:36:25 +0100
commitdba104808411c7eb4321cb13333101c6335b3621 (patch)
treeb59bf6fc5eba0b231d4a47c81a573fd68dd509a2 /qmake
parentb8fa411051eda208dfd0e0c658710c77a04ce998 (diff)
parenta8af0c1aba81716bd0f609b1d9afe5c10951b303 (diff)
Merge branch '4.6' of scm.dev.nokia.troll.no:qt/qt-s60-public into 4.6-integration
* '4.6' of scm.dev.nokia.troll.no:qt/qt-s60-public: Changed canonical paths to absolute paths in symmake. Don't use vgClear() for semi-transparent brushes.
Diffstat (limited to 'qmake')
-rw-r--r--qmake/generators/symbian/symmake.cpp35
-rw-r--r--qmake/generators/symbian/symmake.h2
2 files changed, 14 insertions, 23 deletions
diff --git a/qmake/generators/symbian/symmake.cpp b/qmake/generators/symbian/symmake.cpp
index a7124341c8..217c1c3333 100644
--- a/qmake/generators/symbian/symmake.cpp
+++ b/qmake/generators/symbian/symmake.cpp
@@ -109,11 +109,13 @@ QString SymbianMakefileGenerator::fixPathForMmp(const QString& origPath, const Q
{
static QString epocRootStr;
if (epocRootStr.isEmpty()) {
- QFileInfo efi(epocRoot());
- epocRootStr = efi.canonicalFilePath();
- if (epocRootStr.isEmpty()) {
+ epocRootStr = epocRoot();
+ QFileInfo efi(epocRootStr);
+ if (!efi.exists() || epocRootStr.isEmpty()) {
fprintf(stderr, "Unable to resolve epocRoot '%s' to real dir on current drive, defaulting to '/' for mmp paths\n", qPrintable(epocRoot()));
epocRootStr = "/";
+ } else {
+ epocRootStr = efi.absoluteFilePath();
}
if (!epocRootStr.endsWith("/"))
epocRootStr += "/";
@@ -137,16 +139,8 @@ QString SymbianMakefileGenerator::fixPathForMmp(const QString& origPath, const Q
return resultPath;
}
-QString SymbianMakefileGenerator::canonizePath(const QString& origPath)
+QString SymbianMakefileGenerator::absolutizePath(const QString& origPath)
{
- // Since current path gets appended almost always anyway, use it as default
- // for nonexisting paths.
- static QString defaultPath;
- if (defaultPath.isEmpty()) {
- QFileInfo fi(".");
- defaultPath = fi.canonicalFilePath();
- }
-
// Prepend epocroot to any paths beginning with "/epoc32/"
QString resultPath = QDir::fromNativeSeparators(origPath);
if (resultPath.startsWith("/epoc32/", Qt::CaseInsensitive))
@@ -154,16 +148,13 @@ QString SymbianMakefileGenerator::canonizePath(const QString& origPath)
QFileInfo fi(fileInfo(resultPath));
if (fi.isDir()) {
- resultPath = fi.canonicalFilePath();
+ resultPath = fi.absoluteFilePath();
} else {
- resultPath = fi.canonicalPath();
+ resultPath = fi.absolutePath();
}
resultPath = QDir::cleanPath(resultPath);
- if (resultPath.isEmpty())
- resultPath = defaultPath;
-
return resultPath;
}
@@ -695,7 +686,7 @@ void SymbianMakefileGenerator::initMmpVariables()
srcpaths << project->values("UI_DIR");
QDir current = QDir::current();
- QString canonizedCurrent = canonizePath(".");
+ QString absolutizedCurrent = absolutizePath(".");
for (int j = 0; j < srcpaths.size(); ++j) {
QFileInfo fi(fileInfo(srcpaths.at(j)));
@@ -703,10 +694,10 @@ void SymbianMakefileGenerator::initMmpVariables()
if (fi.suffix().startsWith("c")) {
if (fi.filePath().length() > fi.fileName().length()) {
appendIfnotExist(srcincpaths, fi.path());
- sources[canonizePath(fi.path())] += fi.fileName();
+ sources[absolutizePath(fi.path())] += fi.fileName();
} else {
- sources[canonizedCurrent] += fi.fileName();
- appendIfnotExist(srcincpaths, canonizedCurrent);
+ sources[absolutizedCurrent] += fi.fileName();
+ appendIfnotExist(srcincpaths, absolutizedCurrent);
}
}
}
@@ -720,7 +711,7 @@ void SymbianMakefileGenerator::initMmpVariables()
incpaths << project->values("UI_DIR");
for (int j = 0; j < incpaths.size(); ++j) {
- QString includepath = canonizePath(incpaths.at(j));
+ QString includepath = absolutizePath(incpaths.at(j));
appendIfnotExist(sysincspaths, includepath);
appendAbldTempDirs(sysincspaths, includepath);
}
diff --git a/qmake/generators/symbian/symmake.h b/qmake/generators/symbian/symmake.h
index 77d61da12f..542284c8be 100644
--- a/qmake/generators/symbian/symmake.h
+++ b/qmake/generators/symbian/symmake.h
@@ -84,7 +84,7 @@ protected:
void removeSpecialCharacters(QString& str);
QString fixPathForMmp(const QString& origPath, const QDir& parentDir);
- QString canonizePath(const QString& origPath);
+ QString absolutizePath(const QString& origPath);
virtual bool writeMakefile(QTextStream &t);
void generatePkgFile(const QString &iconFile, DeploymentList &depList);