summaryrefslogtreecommitdiffstats
path: root/qmake
diff options
context:
space:
mode:
authoraxis <qt-info@nokia.com>2010-03-01 14:06:02 (GMT)
committeraxis <qt-info@nokia.com>2010-03-01 14:06:02 (GMT)
commit88a36e9e7e0e0bc09788c41ab6b968031dbc9154 (patch)
tree947663f695f54a0deb2724116f82d89fde761576 /qmake
parent4be1e01c6faebe11bfe205c1b910049747b5c335 (diff)
parentca82ee4ee55e52c75326949148455af1095df014 (diff)
downloadQt-88a36e9e7e0e0bc09788c41ab6b968031dbc9154.zip
Qt-88a36e9e7e0e0bc09788c41ab6b968031dbc9154.tar.gz
Qt-88a36e9e7e0e0bc09788c41ab6b968031dbc9154.tar.bz2
Merge branch 'master' of scm.dev.nokia.troll.no:qt/qt-s60-public
Conflicts: configure mkspecs/common/symbian/symbian.conf qmake/generators/symbian/initprojectdeploy_symbian.cpp qmake/generators/symbian/symmake_abld.cpp qmake/generators/symbian/symmake_sbsv2.cpp src/plugins/plugins.pro
Diffstat (limited to 'qmake')
-rw-r--r--qmake/generators/symbian/initprojectdeploy_symbian.cpp50
-rw-r--r--qmake/generators/symbian/initprojectdeploy_symbian.h2
-rw-r--r--qmake/generators/symbian/symmake.cpp86
-rw-r--r--qmake/generators/symbian/symmake.h4
-rw-r--r--qmake/generators/symbian/symmake_abld.cpp53
-rw-r--r--qmake/generators/symbian/symmake_abld.h2
-rw-r--r--qmake/generators/symbian/symmake_sbsv2.cpp47
-rw-r--r--qmake/generators/symbian/symmake_sbsv2.h1
-rw-r--r--qmake/option.h3
-rw-r--r--qmake/property.cpp3
10 files changed, 147 insertions, 104 deletions
diff --git a/qmake/generators/symbian/initprojectdeploy_symbian.cpp b/qmake/generators/symbian/initprojectdeploy_symbian.cpp
index 6087605..6407412 100644
--- a/qmake/generators/symbian/initprojectdeploy_symbian.cpp
+++ b/qmake/generators/symbian/initprojectdeploy_symbian.cpp
@@ -96,7 +96,7 @@ static void createPluginStub(const QFileInfo& info,
generatedDirs << PLUGIN_STUB_DIR;
// Plugin stubs must have different name from the actual plugins, because
// the toolchain for creating ROM images cannot handle non-binary .dll files properly.
- QFile stubFile(QDir::toNativeSeparators(QLatin1String(PLUGIN_STUB_DIR "/") + info.completeBaseName() + "." SUFFIX_QTPLUGIN));
+ QFile stubFile(QLatin1String(PLUGIN_STUB_DIR "/") + info.completeBaseName() + "." SUFFIX_QTPLUGIN);
if (stubFile.open(QIODevice::WriteOnly)) {
if (!generatedFiles.contains(stubFile.fileName()))
generatedFiles << stubFile.fileName();
@@ -175,21 +175,29 @@ void initProjectDeploySymbian(QMakeProject* project,
foreach(QString item, project->values("DEPLOYMENT")) {
QString devicePath = project->first(item + ".path");
+ QString devicePathWithoutDrive = devicePath;
+
+ bool devicePathHasDriveLetter = false;
+ if (devicePath.size() > 1) {
+ devicePathHasDriveLetter = devicePath.at(1) == QLatin1Char(':');
+ }
+
+ // Sometimes devicePath can contain disk but APP_RESOURCE_DIR does not,
+ // so remove the drive letter for comparison purposes.
+ if (devicePathHasDriveLetter)
+ {
+ devicePathWithoutDrive.remove(0,2);
+ }
if (!deployBinaries
- && !devicePath.isEmpty()
- && (0 == devicePath.compare(project->values("APP_RESOURCE_DIR").join(""), Qt::CaseInsensitive)
- || 0 == devicePath.compare(project->values("REG_RESOURCE_IMPORT_DIR").join(""), Qt::CaseInsensitive))) {
+ && !devicePathWithoutDrive.isEmpty()
+ && (0 == devicePathWithoutDrive.compare(project->values("APP_RESOURCE_DIR").join(""), Qt::CaseInsensitive)
+ || 0 == devicePathWithoutDrive.compare(project->values("REG_RESOURCE_IMPORT_DIR").join(""), Qt::CaseInsensitive))) {
// Do not deploy resources in emulator builds, as that seems to cause conflicts
// If there is ever a real need to deploy pre-built resources for emulator,
// BLD_INF_RULES.prj_exports can be used as a workaround.
continue;
}
- bool devicePathHasDriveLetter = false;
- if (devicePath.size() > 1) {
- devicePathHasDriveLetter = devicePath.at(1) == QLatin1Char(':');
- }
-
if (devicePath.isEmpty() || devicePath == QLatin1String(".")) {
devicePath = targetPath;
}
@@ -197,19 +205,30 @@ void initProjectDeploySymbian(QMakeProject* project,
else if (!(devicePath.at(0) == QLatin1Char('/')
|| devicePath.at(0) == QLatin1Char('\\')
|| devicePathHasDriveLetter)) {
- // create output path
+ // Create output path
devicePath = Option::fixPathToLocalOS(QDir::cleanPath(targetPath + QLatin1Char('/') + devicePath));
} else {
- if (0 == platform.compare(QLatin1String("winscw"), Qt::CaseInsensitive)) {
+ if (!platform.compare(QLatin1String(EMULATOR_DEPLOYMENT_PLATFORM))) {
if (devicePathHasDriveLetter) {
devicePath = epocRoot() + "epoc32/winscw/" + devicePath.remove(1, 1);
} else {
devicePath = epocRoot() + "epoc32/winscw/c" + devicePath;
}
} else {
- // Drive letter needed if targetpath contains one and it is not already in
- if (targetPathHasDriveLetter && !devicePathHasDriveLetter) {
- devicePath = deploymentDrive + devicePath;
+ if (!devicePathHasDriveLetter) {
+ if (!platform.compare(QLatin1String(ROM_DEPLOYMENT_PLATFORM))) {
+ //For plugin deployment under ARM no needed drive letter
+ devicePath = epocRoot() + "epoc32/data/z" + devicePath;
+ } else if (targetPathHasDriveLetter) {
+ // Drive letter needed if targetpath contains one and it is not already in
+ devicePath = deploymentDrive + devicePath;
+ }
+ } else {
+ //it is necessary to delete drive letter for ARM deployment
+ if (!platform.compare(QLatin1String(ROM_DEPLOYMENT_PLATFORM))) {
+ devicePath.remove(0,2);
+ devicePath = epocRoot() + "epoc32/data/z" + devicePath;
+ }
}
}
}
@@ -307,7 +326,8 @@ void initProjectDeploySymbian(QMakeProject* project,
+ iterator.fileName())));
}
}
- createPluginStub(info, devicePath + "/" + absoluteItemPath.right(diffSize), deploymentList, generatedDirs, generatedFiles);
+ createPluginStub(info, devicePath + "/" + absoluteItemPath.right(diffSize),
+ deploymentList, generatedDirs, generatedFiles);
continue;
} else {
deploymentList.append(CopyItem(
diff --git a/qmake/generators/symbian/initprojectdeploy_symbian.h b/qmake/generators/symbian/initprojectdeploy_symbian.h
index be78a27..2653d2a 100644
--- a/qmake/generators/symbian/initprojectdeploy_symbian.h
+++ b/qmake/generators/symbian/initprojectdeploy_symbian.h
@@ -51,6 +51,8 @@
#include <stdlib.h>
#define PLUGIN_STUB_DIR "qmakepluginstubs"
+#define ROM_DEPLOYMENT_PLATFORM "rom"
+#define EMULATOR_DEPLOYMENT_PLATFORM "emulator"
struct CopyItem
{
diff --git a/qmake/generators/symbian/symmake.cpp b/qmake/generators/symbian/symmake.cpp
index 5b230e4..a812e5f 100644
--- a/qmake/generators/symbian/symmake.cpp
+++ b/qmake/generators/symbian/symmake.cpp
@@ -63,7 +63,7 @@
#define BLD_INF_TAG_MMPFILES "prj_mmpfiles"
#define BLD_INF_TAG_TESTMMPFILES "prj_testmmpfiles"
#define BLD_INF_TAG_EXTENSIONS "prj_extensions"
-#define BLD_INF_TAG_EXPORTS "prj_exports"
+#define BLD_INF_TAG_TESTEXTENSIONS "prj_testextensions"
#define MMP_TARGET "TARGET"
#define MMP_TARGETTYPE "TARGETTYPE"
@@ -88,11 +88,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 += "/";
@@ -116,33 +118,26 @@ 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))
resultPath = QDir::fromNativeSeparators(epocRoot()) + resultPath.mid(1);
QFileInfo fi(fileInfo(resultPath));
- if (fi.isDir()) {
- resultPath = fi.canonicalFilePath();
+
+ // Since origPath can be something given in HEADERS, we need to check if we are dealing
+ // with a file or a directory. In case the origPath doesn't yet exist, isFile() returns
+ // false and we default to assuming it is a dir.
+ if (fi.isFile()) {
+ resultPath = fi.absolutePath();
} else {
- resultPath = fi.canonicalPath();
+ resultPath = fi.absoluteFilePath();
}
resultPath = QDir::cleanPath(resultPath);
- if (resultPath.isEmpty())
- resultPath = defaultPath;
-
return resultPath;
}
@@ -379,7 +374,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)));
@@ -387,10 +382,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);
}
}
}
@@ -404,7 +399,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);
}
@@ -446,15 +441,14 @@ void SymbianMakefileGenerator::initMmpVariables()
QStringList restrictedMmpKeywords;
bool inResourceBlock = false;
- overridableMmpKeywords << QLatin1String(MMP_TARGETTYPE);
+ overridableMmpKeywords << QLatin1String(MMP_TARGETTYPE) << QLatin1String(MMP_EPOCHEAPSIZE);
restrictableMmpKeywords << QLatin1String(MMP_TARGET) << QLatin1String(MMP_SECUREID)
<< QLatin1String(MMP_OPTION_CW) << QLatin1String(MMP_OPTION_ARMCC)
<< QLatin1String(MMP_OPTION_GCCE) << QLatin1String(MMP_LINKEROPTION_CW)
<< QLatin1String(MMP_LINKEROPTION_ARMCC) << QLatin1String(MMP_LINKEROPTION_GCCE)
<< QLatin1String(MMP_CAPABILITY) << QLatin1String(MMP_EPOCALLOWDLLDATA)
- << QLatin1String(MMP_EPOCHEAPSIZE) << QLatin1String(MMP_EPOCSTACKSIZE)
- << QLatin1String(MMP_UID) << QLatin1String(MMP_VENDORID)
- << QLatin1String(MMP_VERSION);
+ << QLatin1String(MMP_EPOCSTACKSIZE) << QLatin1String(MMP_UID)
+ << QLatin1String(MMP_VENDORID) << QLatin1String(MMP_VERSION);
foreach (QString item, project->values("MMP_RULES")) {
if (project->values(item).isEmpty()) {
@@ -624,6 +618,7 @@ void SymbianMakefileGenerator::addMacro(QTextStream& t, const QString& value)
void SymbianMakefileGenerator::writeMmpFileTargetPart(QTextStream& t)
{
bool skipTargetType = overriddenMmpKeywords.contains(MMP_TARGETTYPE);
+ bool skipEpocHeapSize = overriddenMmpKeywords.contains(MMP_EPOCHEAPSIZE);
if (targetType == TypeExe) {
t << MMP_TARGET "\t\t" << fixedTarget << ".exe" << endl;
@@ -675,7 +670,7 @@ void SymbianMakefileGenerator::writeMmpFileTargetPart(QTextStream& t)
if (0 != project->first("TARGET.EPOCSTACKSIZE").size())
t << MMP_EPOCSTACKSIZE "\t\t" << project->first("TARGET.EPOCSTACKSIZE") << endl;
- if (0 != project->values("TARGET.EPOCHEAPSIZE").size())
+ if (!skipEpocHeapSize && 0 != project->values("TARGET.EPOCHEAPSIZE").size())
t << MMP_EPOCHEAPSIZE "\t\t" << project->values("TARGET.EPOCHEAPSIZE").join(" ") << endl;
if (0 != project->values("TARGET.EPOCALLOWDLLDATA").size())
t << MMP_EPOCALLOWDLLDATA << endl;
@@ -1054,7 +1049,7 @@ void SymbianMakefileGenerator::writeBldInfContent(QTextStream &t, bool addDeploy
// Add project mmps and old style extension makefiles
QString mmpTag;
- if (project->isActiveConfig("symbian_test"))
+ if (project->isActiveConfig(SYMBIAN_TEST_CONFIG))
mmpTag = QLatin1String(BLD_INF_TAG_TESTMMPFILES);
else
mmpTag = QLatin1String(BLD_INF_TAG_MMPFILES);
@@ -1077,35 +1072,22 @@ void SymbianMakefileGenerator::writeBldInfContent(QTextStream &t, bool addDeploy
t << item << endl;
userBldInfRules.remove(mmpTag);
- t << endl << BLD_INF_TAG_EXTENSIONS << endl << endl;
+ QString extensionTag;
+ if (project->isActiveConfig(SYMBIAN_TEST_CONFIG))
+ extensionTag = QLatin1String(BLD_INF_TAG_TESTEXTENSIONS);
+ else
+ extensionTag = QLatin1String(BLD_INF_TAG_EXTENSIONS);
+
+ t << endl << extensionTag << endl << endl;
// Generate extension rules
writeBldInfExtensionRulesPart(t, iconFile);
- userItems = userBldInfRules.value(BLD_INF_TAG_EXTENSIONS);
- foreach(QString item, userItems)
- t << item << endl;
- userBldInfRules.remove(BLD_INF_TAG_EXTENSIONS);
-
- t << endl << BLD_INF_TAG_EXPORTS << endl << endl;
-
- // Generate export rules
-
- // Export any deployed plugin stubs under /epoc32/data/z to support ROM builds
- for (int i = 0; i < depList.size(); ++i) {
- int index = depList.at(i).from.indexOf(PLUGIN_STUB_DIR);
- if (index != -1) {
- t << QString("%1 /epoc32/data/z%2")
- .arg(QString(depList.at(i).from).mid(index).replace('\\','/'))
- .arg(QString(depList.at(i).to).mid(2).replace('\\','/')) << endl;
- }
- }
-
- userItems = userBldInfRules.value(BLD_INF_TAG_EXPORTS);
+ userItems = userBldInfRules.value(extensionTag);
foreach(QString item, userItems)
t << item << endl;
- userBldInfRules.remove(BLD_INF_TAG_EXPORTS);
+ userBldInfRules.remove(extensionTag);
// Add rest of the user defined content
diff --git a/qmake/generators/symbian/symmake.h b/qmake/generators/symbian/symmake.h
index b915ba7..a7610b0 100644
--- a/qmake/generators/symbian/symmake.h
+++ b/qmake/generators/symbian/symmake.h
@@ -50,9 +50,9 @@ QT_BEGIN_NAMESPACE
#define BLD_INF_FILENAME "bld.inf"
#define MAKEFILE_DEPENDENCY_SEPARATOR " \\\n\t"
-
#define QT_EXTRA_INCLUDE_DIR "tmp"
#define MAKE_CACHE_NAME ".make.cache"
+#define SYMBIAN_TEST_CONFIG "symbian_test"
class SymbianMakefileGenerator : public MakefileGenerator, public SymbianCommonGenerator
{
@@ -67,7 +67,7 @@ protected:
QStringList overriddenMmpKeywords;
QString fixPathForMmp(const QString& origPath, const QDir& parentDir);
- QString canonizePath(const QString& origPath);
+ QString absolutizePath(const QString& origPath);
virtual bool writeMakefile(QTextStream &t);
diff --git a/qmake/generators/symbian/symmake_abld.cpp b/qmake/generators/symbian/symmake_abld.cpp
index aec16fd..1fc87aa 100644
--- a/qmake/generators/symbian/symmake_abld.cpp
+++ b/qmake/generators/symbian/symmake_abld.cpp
@@ -59,6 +59,8 @@
#define FINALIZE_TARGET "finalize"
#define GENERATED_SOURCES_TARGET "generated_sources"
#define ALL_SOURCE_DEPS_TARGET "all_source_deps"
+#define DEPLOYMENT_TARGET "deployment"
+#define DEPLOYMENT_CLEAN_TARGET "deployment_clean"
#define WINSCW_DEPLOYMENT_TARGET "winscw_deployment"
#define WINSCW_DEPLOYMENT_CLEAN_TARGET "winscw_deployment_clean"
#define STORE_BUILD_TARGET "store_build"
@@ -112,25 +114,29 @@ void SymbianAbldMakefileGenerator::writeMkFile(const QString& wrapperFileName, b
QStringList wrapperTargets;
if (deploymentOnly) {
buildDeps.append(STORE_BUILD_TARGET);
- cleanDeps.append(DO_NOTHING_TARGET);
- cleanDepsWinscw.append(WINSCW_DEPLOYMENT_CLEAN_TARGET);
- finalDeps.append(DO_NOTHING_TARGET);
- finalDepsWinscw.append(WINSCW_DEPLOYMENT_TARGET);
+ cleanDeps.append(DEPLOYMENT_CLEAN_TARGET);
+ cleanDepsWinscw.append(WINSCW_DEPLOYMENT_CLEAN_TARGET " " DEPLOYMENT_CLEAN_TARGET);
+ finalDeps.append(DEPLOYMENT_TARGET);
+ finalDepsWinscw.append(WINSCW_DEPLOYMENT_TARGET " " DEPLOYMENT_TARGET);
wrapperTargets << WINSCW_DEPLOYMENT_TARGET
<< WINSCW_DEPLOYMENT_CLEAN_TARGET
+ << DEPLOYMENT_TARGET
+ << DEPLOYMENT_CLEAN_TARGET
<< STORE_BUILD_TARGET;
} else {
buildDeps.append(CREATE_TEMPS_TARGET " " PRE_TARGETDEPS_TARGET " " STORE_BUILD_TARGET);
- cleanDeps.append(EXTENSION_CLEAN);
- cleanDepsWinscw.append(EXTENSION_CLEAN " " WINSCW_DEPLOYMENT_CLEAN_TARGET);
- finalDeps.append(FINALIZE_TARGET);
- finalDepsWinscw.append(FINALIZE_TARGET " " WINSCW_DEPLOYMENT_TARGET);
+ cleanDeps.append(EXTENSION_CLEAN " " DEPLOYMENT_CLEAN_TARGET);
+ cleanDepsWinscw.append(EXTENSION_CLEAN " " WINSCW_DEPLOYMENT_CLEAN_TARGET " " DEPLOYMENT_CLEAN_TARGET);
+ finalDeps.append(FINALIZE_TARGET " " DEPLOYMENT_TARGET);
+ finalDepsWinscw.append(FINALIZE_TARGET " " WINSCW_DEPLOYMENT_TARGET " " DEPLOYMENT_TARGET);
wrapperTargets << PRE_TARGETDEPS_TARGET
<< CREATE_TEMPS_TARGET
<< EXTENSION_CLEAN
<< FINALIZE_TARGET
<< WINSCW_DEPLOYMENT_CLEAN_TARGET
<< WINSCW_DEPLOYMENT_TARGET
+ << DEPLOYMENT_CLEAN_TARGET
+ << DEPLOYMENT_TARGET
<< STORE_BUILD_TARGET;
}
@@ -175,7 +181,7 @@ void SymbianAbldMakefileGenerator::writeWrapperMakefile(QFile& wrapperFile, bool
releasePlatforms.removeAll("winscw"); // No release for emulator
QString testClause;
- if (project->isActiveConfig("symbian_test"))
+ if (project->isActiveConfig(SYMBIAN_TEST_CONFIG))
testClause = QLatin1String(" test");
else
testClause = QLatin1String("");
@@ -369,7 +375,9 @@ void SymbianAbldMakefileGenerator::writeWrapperMakefile(QFile& wrapperFile, bool
qDeleteAll(subtargets);
}
- writeDeploymentTargets(t);
+ // Deploymend targets for both emulator and rom deployment
+ writeDeploymentTargets(t, false);
+ writeDeploymentTargets(t, true);
generateDistcleanTargets(t);
@@ -410,13 +418,21 @@ void SymbianAbldMakefileGenerator::writeBldInfExtensionRulesPart(QTextStream& t,
Q_UNUSED(iconTargetFile);
}
-bool SymbianAbldMakefileGenerator::writeDeploymentTargets(QTextStream &t)
+bool SymbianAbldMakefileGenerator::writeDeploymentTargets(QTextStream &t, bool isRom)
{
- t << WINSCW_DEPLOYMENT_TARGET ":" << endl;
+ if (isRom)
+ t << DEPLOYMENT_TARGET ":" << endl;
+ else
+ t << WINSCW_DEPLOYMENT_TARGET ":" << endl;
- QString remoteTestPath = epocRoot() + QLatin1String("epoc32\\winscw\\c\\private\\") + privateDirUid; // default 4 OpenC; 4 all Symbian too
+ QString remoteTestPath = epocRoot()
+ + QLatin1String(isRom ? "epoc32\\data\\z\\private\\" : "epoc32\\winscw\\c\\private\\")
+ + privateDirUid;
DeploymentList depList;
- initProjectDeploySymbian(project, depList, remoteTestPath, false, true, QLatin1String("winscw"), QLatin1String("udeb"), generatedDirs, generatedFiles);
+
+ initProjectDeploySymbian(project, depList, remoteTestPath, false, true,
+ QLatin1String(isRom ? ROM_DEPLOYMENT_PLATFORM : EMULATOR_DEPLOYMENT_PLATFORM),
+ QString(), generatedDirs, generatedFiles);
if (depList.size())
t << "\t-echo Deploying changed files..." << endl;
@@ -425,12 +441,17 @@ bool SymbianAbldMakefileGenerator::writeDeploymentTargets(QTextStream &t)
// Xcopy prompts for selecting file or directory if target doesn't exist,
// and doesn't provide switch to force file selection. It does provide dir forcing, though,
// so strip the last part of the destination.
- t << "\t-$(XCOPY) \"" << depList.at(i).from << "\" \"" << depList.at(i).to.left(depList.at(i).to.lastIndexOf("\\") + 1) << "\"" << endl;
+ t << "\t-$(XCOPY) \"" << depList.at(i).from << "\" \""
+ << depList.at(i).to.left(depList.at(i).to.lastIndexOf("\\") + 1) << "\"" << endl;
}
t << endl;
- t << WINSCW_DEPLOYMENT_CLEAN_TARGET ":" << endl;
+ if (isRom)
+ t << DEPLOYMENT_CLEAN_TARGET ":" << endl;
+ else
+ t << WINSCW_DEPLOYMENT_CLEAN_TARGET ":" << endl;
+
QStringList cleanList;
for (int i = 0; i < depList.size(); ++i) {
cleanList.append(depList.at(i).to);
diff --git a/qmake/generators/symbian/symmake_abld.h b/qmake/generators/symbian/symmake_abld.h
index d0f38b0..f998b28 100644
--- a/qmake/generators/symbian/symmake_abld.h
+++ b/qmake/generators/symbian/symmake_abld.h
@@ -57,7 +57,7 @@ protected:
virtual void writeWrapperMakefile(QFile& wrapperFile, bool isPrimaryMakefile);
virtual void appendAbldTempDirs(QStringList& sysincspaths, QString includepath);
- bool writeDeploymentTargets(QTextStream &t);
+ bool writeDeploymentTargets(QTextStream &t, bool isRom);
public:
diff --git a/qmake/generators/symbian/symmake_sbsv2.cpp b/qmake/generators/symbian/symmake_sbsv2.cpp
index 7bbc73e..3d8b556 100644
--- a/qmake/generators/symbian/symmake_sbsv2.cpp
+++ b/qmake/generators/symbian/symmake_sbsv2.cpp
@@ -90,6 +90,23 @@ void SymbianSbsv2MakefileGenerator::exportFlm()
}
}
+void SymbianSbsv2MakefileGenerator::writeSbsDeploymentList(const DeploymentList& depList, QTextStream& t)
+{
+ for (int i = 0; i < depList.size(); ++i) {
+ t << "START EXTENSION qt/qmake_emulator_deployment" << endl;
+ QString fromItem = depList.at(i).from;
+ QString toItem = depList.at(i).to;
+ fromItem.replace("\\", "/");
+ toItem.replace("\\", "/");
+#if defined(Q_OS_WIN)
+ toItem.prepend(QDir::current().absolutePath().left(2)); // add drive
+#endif
+ t << "OPTION DEPLOY_SOURCE " << fromItem << endl;
+ t << "OPTION DEPLOY_TARGET " << toItem << endl;
+ t << "END" << endl;
+ }
+}
+
void SymbianSbsv2MakefileGenerator::writeMkFile(const QString& wrapperFileName, bool deploymentOnly)
{
// Can't use extension makefile with sbsv2
@@ -109,7 +126,7 @@ void SymbianSbsv2MakefileGenerator::writeWrapperMakefile(QFile& wrapperFile, boo
releasePlatforms.removeAll("winscw"); // No release for emulator
QString testClause;
- if (project->isActiveConfig("symbian_test"))
+ if (project->isActiveConfig(SYMBIAN_TEST_CONFIG))
testClause = QLatin1String(".test");
else
testClause = QLatin1String("");
@@ -343,7 +360,7 @@ void SymbianSbsv2MakefileGenerator::writeBldInfExtensionRulesPart(QTextStream& t
}
}
- t << "START EXTENSION qt/qmake_extra_pre_targetdep" << endl;
+ t << "START EXTENSION qt/qmake_extra_pre_targetdep.export" << endl;
t << "OPTION PREDEP_TARGET " << absoluteTarget << endl;
t << "OPTION DEPS " << absoluteDeps << endl;
@@ -363,27 +380,23 @@ void SymbianSbsv2MakefileGenerator::writeBldInfExtensionRulesPart(QTextStream& t
t << endl;
- // Write winscw deployment rules
+ // Write deployment rules
QString remoteTestPath = epocRoot() + QLatin1String("epoc32/winscw/c/private/") + privateDirUid;
DeploymentList depList;
- initProjectDeploySymbian(project, depList, remoteTestPath, false, true, QLatin1String("winscw"), QLatin1String("udeb"), generatedDirs, generatedFiles);
+ //write emulator deployment
t << "#if defined(WINSCW)" << endl;
- for (int i = 0; i < depList.size(); ++i) {
- t << "START EXTENSION qt/qmake_emulator_deployment" << endl;
- QString fromItem = depList.at(i).from;
- QString toItem = depList.at(i).to;
- fromItem.replace("\\", "/");
- toItem.replace("\\", "/");
-#if defined(Q_OS_WIN)
- toItem.prepend(QDir::current().absolutePath().left(2)); // add drive
-#endif
- t << "OPTION DEPLOY_SOURCE " << fromItem << endl;
- t << "OPTION DEPLOY_TARGET " << toItem << endl;
- t << "END" << endl;
- }
+ initProjectDeploySymbian(project, depList, remoteTestPath, false,
+ QLatin1String(EMULATOR_DEPLOYMENT_PLATFORM), QString(), generatedDirs, generatedFiles);
+ writeSbsDeploymentList(depList, t);
t << "#endif" << endl;
+ //write ROM deployment
+ remoteTestPath = epocRoot() + QLatin1String("epoc32/data/z/private/") + privateDirUid;
+ depList.clear();
+ initProjectDeploySymbian(project, depList, remoteTestPath, false, true,
+ QLatin1String(ROM_DEPLOYMENT_PLATFORM), QString(), generatedDirs, generatedFiles);
+ writeSbsDeploymentList(depList, t);
t << endl;
// Write post link rules
diff --git a/qmake/generators/symbian/symmake_sbsv2.h b/qmake/generators/symbian/symmake_sbsv2.h
index 5c31249..b8ccdbe 100644
--- a/qmake/generators/symbian/symmake_sbsv2.h
+++ b/qmake/generators/symbian/symmake_sbsv2.h
@@ -64,6 +64,7 @@ public:
private:
void exportFlm();
+ void writeSbsDeploymentList(const DeploymentList& depList, QTextStream& t);
QString extraTargetsCache;
QString extraCompilersCache;
diff --git a/qmake/option.h b/qmake/option.h
index 514e442..a2ca676 100644
--- a/qmake/option.h
+++ b/qmake/option.h
@@ -205,7 +205,8 @@ public:
TranslationsPath,
SettingsPath,
DemosPath,
- ExamplesPath
+ ExamplesPath,
+ ImportsPath
};
static QString location(LibraryLocation);
};
diff --git a/qmake/property.cpp b/qmake/property.cpp
index cab034f..fde7c65 100644
--- a/qmake/property.cpp
+++ b/qmake/property.cpp
@@ -95,6 +95,8 @@ QMakeProperty::value(QString v, bool just_check)
return QLibraryInfo::location(QLibraryInfo::BinariesPath);
else if(v == "QT_INSTALL_PLUGINS")
return QLibraryInfo::location(QLibraryInfo::PluginsPath);
+ else if(v == "QT_INSTALL_IMPORTS")
+ return QLibraryInfo::location(QLibraryInfo::ImportsPath);
else if(v == "QT_INSTALL_TRANSLATIONS")
return QLibraryInfo::location(QLibraryInfo::TranslationsPath);
else if(v == "QT_INSTALL_CONFIGURATION")
@@ -191,6 +193,7 @@ QMakeProperty::exec()
specialProps.append("QT_INSTALL_LIBS");
specialProps.append("QT_INSTALL_BINS");
specialProps.append("QT_INSTALL_PLUGINS");
+ specialProps.append("QT_INSTALL_IMPORTS");
specialProps.append("QT_INSTALL_TRANSLATIONS");
specialProps.append("QT_INSTALL_CONFIGURATION");
specialProps.append("QT_INSTALL_EXAMPLES");