summaryrefslogtreecommitdiffstats
path: root/qmake
diff options
context:
space:
mode:
Diffstat (limited to 'qmake')
-rw-r--r--qmake/generators/symbian/initprojectdeploy_symbian.cpp53
-rw-r--r--qmake/project.cpp17
-rw-r--r--qmake/project.h6
3 files changed, 32 insertions, 44 deletions
diff --git a/qmake/generators/symbian/initprojectdeploy_symbian.cpp b/qmake/generators/symbian/initprojectdeploy_symbian.cpp
index 4552185..2750ecb 100644
--- a/qmake/generators/symbian/initprojectdeploy_symbian.cpp
+++ b/qmake/generators/symbian/initprojectdeploy_symbian.cpp
@@ -50,6 +50,7 @@
#include <symbian/epocroot.h>
#define SYSBIN_DIR "/sys/bin"
+#define HW_Z_DIR "epoc32/data/z"
#define SUFFIX_DLL "dll"
#define SUFFIX_EXE "exe"
@@ -65,10 +66,11 @@ static bool isPlugin(const QFileInfo& info, const QString& devicePath)
{
// Libraries are plugins if deployment path is something else than
// SYSBIN_DIR with or without drive letter
- if (0 == info.suffix().compare(QLatin1String(SUFFIX_DLL), Qt::CaseInsensitive) &&
- (devicePath.size() < 8 ||
- (0 != devicePath.compare(QLatin1String(SYSBIN_DIR), Qt::CaseInsensitive) &&
- 0 != devicePath.mid(1).compare(QLatin1String(":" SYSBIN_DIR), Qt::CaseInsensitive)))) {
+ if (0 == info.suffix().compare(QLatin1String(SUFFIX_DLL), Qt::CaseInsensitive)
+ && (devicePath.size() < 8
+ || (0 != devicePath.compare(QLatin1String(SYSBIN_DIR), Qt::CaseInsensitive)
+ && 0 != devicePath.mid(1).compare(QLatin1String(":" SYSBIN_DIR), Qt::CaseInsensitive)
+ && 0 != devicePath.compare(epocRoot() + QLatin1String(HW_Z_DIR SYSBIN_DIR))))) {
return true;
} else {
return false;
@@ -172,7 +174,13 @@ void initProjectDeploySymbian(QMakeProject* project,
if (targetPath.size() > 1) {
targetPathHasDriveLetter = targetPath.at(1) == QLatin1Char(':');
}
- QString deploymentDrive = targetPathHasDriveLetter ? targetPath.left(2) : QLatin1String("c:");
+
+ QString deploymentDrive;
+ if (0 == platform.compare(QLatin1String(ROM_DEPLOYMENT_PLATFORM))) {
+ deploymentDrive = epocRoot() + HW_Z_DIR;
+ } else {
+ deploymentDrive = targetPathHasDriveLetter ? targetPath.left(2) : QLatin1String("c:");
+ }
foreach(QString item, project->values("DEPLOYMENT")) {
QString devicePath = project->first(item + ".path");
@@ -209,35 +217,29 @@ void initProjectDeploySymbian(QMakeProject* project,
// Create output path
devicePath = Option::fixPathToLocalOS(QDir::cleanPath(targetPath + QLatin1Char('/') + devicePath));
} else {
- if (!platform.compare(QLatin1String(EMULATOR_DEPLOYMENT_PLATFORM))) {
+ if (0 == platform.compare(QLatin1String(EMULATOR_DEPLOYMENT_PLATFORM))) {
if (devicePathHasDriveLetter) {
devicePath = epocRoot() + "epoc32/winscw/" + devicePath.remove(1, 1);
} else {
devicePath = epocRoot() + "epoc32/winscw/c" + devicePath;
}
} else {
- 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;
- }
+ if (devicePathHasDriveLetter
+ && 0 == platform.compare(QLatin1String(ROM_DEPLOYMENT_PLATFORM))) {
+ devicePath.remove(0,2);
+ }
+ if (0 == platform.compare(QLatin1String(ROM_DEPLOYMENT_PLATFORM))
+ || (!devicePathHasDriveLetter && targetPathHasDriveLetter)) {
+ devicePath = deploymentDrive + devicePath;
}
}
}
devicePath.replace(QLatin1String("\\"), QLatin1String("/"));
- if (!deployBinaries &&
- 0 == devicePath.right(8).compare(QLatin1String(SYSBIN_DIR), Qt::CaseInsensitive)) {
+ if (!deployBinaries
+ && 0 == devicePath.right(8).compare(QLatin1String(SYSBIN_DIR), Qt::CaseInsensitive)
+ && 0 != platform.compare(QLatin1String(ROM_DEPLOYMENT_PLATFORM))) {
// Skip deploying to SYSBIN_DIR for anything but binary deployments
// Note: Deploying pre-built binaries also follow this rule, so emulator builds
// will not get those deployed. Since there is no way to differentiate currently
@@ -281,7 +283,7 @@ void initProjectDeploySymbian(QMakeProject* project,
deploymentList.append(CopyItem(
Option::fixPathToLocalOS(targetPath.absolutePath() + "/" + info.fileName(),
false, true),
- fixPathToEpocOS(deploymentDrive + QLatin1String(SYSBIN_DIR "/")
+ fixPathToEpocOS(deploymentDrive + QLatin1String("/" SYSBIN_DIR "/")
+ info.fileName())));
}
}
@@ -314,7 +316,8 @@ void initProjectDeploySymbian(QMakeProject* project,
if (isPlugin(iterator.fileInfo(), devicePath)) {
// This deploys pre-built plugins. Other pre-built binaries will deploy normally,
// as they have SYSBIN_DIR target path.
- if (deployBinaries) {
+ if (deployBinaries
+ || (0 == platform.compare(QLatin1String(ROM_DEPLOYMENT_PLATFORM)))) {
if (devicePathHasDriveLetter) {
deploymentList.append(CopyItem(
Option::fixPathToLocalOS(absoluteItemPath + "/" + iterator.fileName()),
@@ -323,7 +326,7 @@ void initProjectDeploySymbian(QMakeProject* project,
} else {
deploymentList.append(CopyItem(
Option::fixPathToLocalOS(absoluteItemPath + "/" + iterator.fileName()),
- fixPathToEpocOS(deploymentDrive + QLatin1String(SYSBIN_DIR "/")
+ fixPathToEpocOS(deploymentDrive + QLatin1String("/" SYSBIN_DIR "/")
+ iterator.fileName())));
}
}
diff --git a/qmake/project.cpp b/qmake/project.cpp
index 9cf6a6f..cb02923 100644
--- a/qmake/project.cpp
+++ b/qmake/project.cpp
@@ -1406,16 +1406,6 @@ QMakeProject::read(uchar cmd)
return false;
}
- if(cmd & ReadPostFiles) { // parse post files
- const QStringList l = vars["QMAKE_POST_INCLUDE_FILES"];
- for(QStringList::ConstIterator it = l.begin(); it != l.end(); ++it) {
- if(read((*it), vars)) {
- if(vars["QMAKE_INTERNAL_INCLUDED_FILES"].indexOf((*it)) == -1)
- vars["QMAKE_INTERNAL_INCLUDED_FILES"].append((*it));
- }
- }
- }
-
if(cmd & ReadCmdLine) {
parser.file = "(internal)";
parser.from_file = false;
@@ -1720,7 +1710,6 @@ QMakeProject::doProjectInclude(QString file, uchar flags, QMap<QString, QStringL
fprintf(stderr, "Cannot find directory: %s\n", file.left(di).toLatin1().constData());
return IncludeFailure;
}
- file = file.right(file.length() - di - 1);
}
bool parsed = false;
parser_info pi = parser;
@@ -1740,9 +1729,9 @@ QMakeProject::doProjectInclude(QString file, uchar flags, QMap<QString, QStringL
if(proj.doProjectInclude("default_pre", IncludeFlagFeature, proj.variables()) == IncludeNoExist)
proj.doProjectInclude("default", IncludeFlagFeature, proj.variables());
#endif
- parsed = proj.read(file, proj.variables());
+ parsed = proj.read(file, proj.variables()); // parse just that file (fromfile, infile)
} else {
- parsed = proj.read(file);
+ parsed = proj.read(file); // parse all aux files (load/include into)
}
place = proj.variables();
} else {
@@ -2191,7 +2180,7 @@ QMakeProject::doProjectExpand(QString func, QList<QStringList> args_list,
if(args.count() != 1) {
fprintf(stderr, "%s:%d prompt(question) requires one argument.\n",
parser.file.toLatin1().constData(), parser.line_no);
- } else if(projectFile() == "-") {
+ } else if(pfile == "-") {
fprintf(stderr, "%s:%d prompt(question) cannot be used when '-o -' is used.\n",
parser.file.toLatin1().constData(), parser.line_no);
} else {
diff --git a/qmake/project.h b/qmake/project.h
index fd8ced1..1d9ec04 100644
--- a/qmake/project.h
+++ b/qmake/project.h
@@ -118,7 +118,7 @@ public:
~QMakeProject();
enum { ReadCache=0x01, ReadConf=0x02, ReadCmdLine=0x04, ReadProFile=0x08,
- ReadPostFiles=0x10, ReadFeatures=0x20, ReadConfigs=0x40, ReadAll=0xFF };
+ ReadFeatures=0x20, ReadConfigs=0x40, ReadAll=0xFF };
inline bool parse(const QString &text) { return parse(text, vars); }
bool read(const QString &project, uchar cmd=ReadAll);
bool read(uchar cmd=ReadAll);
@@ -127,7 +127,6 @@ public:
QStringList userTestFunctions() { return testFunctions.keys(); }
QString projectFile();
- QString configFile();
inline QMakeProperty *properties() { return prop; }
bool doProjectTest(QString str, QMap<QString, QStringList> &place);
@@ -174,9 +173,6 @@ inline QString QMakeProject::projectFile()
return pfile;
}
-inline QString QMakeProject::configFile()
-{ return cfile; }
-
inline QStringList &QMakeProject::values(const QString &v)
{ return values(v, vars); }