summaryrefslogtreecommitdiffstats
path: root/qmake/generators/symbian/symmake_abld.cpp
diff options
context:
space:
mode:
authoraxis <qt-info@nokia.com>2010-02-16 12:53:07 +0100
committeraxis <qt-info@nokia.com>2010-02-16 12:53:07 +0100
commit15b08dffc1354bc816b04901a7442679382b0935 (patch)
tree783af85b75f9de3ab10902c5ba66cf5e22b2fe61 /qmake/generators/symbian/symmake_abld.cpp
parent9f5b02406f38fe02a27de7843b9f8a11232d2064 (diff)
parent9d174f13e48730ac06aa429e0f011a02b333025e (diff)
Merge branch 'master' of scm.dev.nokia.troll.no:qt/qt-s60-public
Conflicts: configure mkspecs/common/symbian/symbian.conf mkspecs/features/symbian/application_icon.prf qmake/generators/makefile.cpp qmake/generators/symbian/initprojectdeploy_symbian.cpp qmake/generators/symbian/symmake.cpp tools/assistant/tools/assistant/assistant.pro
Diffstat (limited to 'qmake/generators/symbian/symmake_abld.cpp')
-rw-r--r--qmake/generators/symbian/symmake_abld.cpp48
1 files changed, 36 insertions, 12 deletions
diff --git a/qmake/generators/symbian/symmake_abld.cpp b/qmake/generators/symbian/symmake_abld.cpp
index 572c742af7..00c05b74fb 100644
--- a/qmake/generators/symbian/symmake_abld.cpp
+++ b/qmake/generators/symbian/symmake_abld.cpp
@@ -195,16 +195,21 @@ void SymbianAbldMakefileGenerator::writeWrapperMakefile(QFile& wrapperFile, bool
t << "DEL_FILE = " << var("QMAKE_DEL_FILE") << endl;
t << "DEL_DIR = " << var("QMAKE_DEL_DIR") << endl;
t << "MOVE = " << var("QMAKE_MOVE") << endl;
+#ifdef Q_OS_WIN32
t << "XCOPY = xcopy /d /f /h /r /y /i" << endl;
t << "ABLD = ABLD.BAT" << endl;
+#else
+ t << "XCOPY = cp -u -v" << endl;
+ t << "ABLD = abld" << endl;
+#endif
t << "DEBUG_PLATFORMS = " << debugPlatforms.join(" ") << endl;
t << "RELEASE_PLATFORMS = " << releasePlatforms.join(" ") << endl;
t << "MAKE = make" << endl;
t << endl;
t << "ifeq (WINS,$(findstring WINS, $(PLATFORM)))" << endl;
- t << "ZDIR=$(EPOCROOT)epoc32\\release\\$(PLATFORM)\\$(CFG)\\Z" << endl;
+ t << "ZDIR=$(EPOCROOT)" << QDir::toNativeSeparators("epoc32/release/$(PLATFORM)/$(CFG)/z") << endl;
t << "else" << endl;
- t << "ZDIR=$(EPOCROOT)epoc32\\data\\z" << endl;
+ t << "ZDIR=$(EPOCROOT)" << QDir::toNativeSeparators("epoc32/data/z") << endl;
t << "endif" << endl;
t << endl;
t << "DEFINES" << '\t' << " = "
@@ -304,8 +309,13 @@ void SymbianAbldMakefileGenerator::writeWrapperMakefile(QFile& wrapperFile, bool
if (values.at(i).endsWith("/" QT_EXTRA_INCLUDE_DIR)) {
QString fixedValue(QDir::toNativeSeparators(values.at(i)));
dirsToClean << fixedValue;
+#ifdef Q_OS_WIN32
t << "\t-@ if NOT EXIST \"" << fixedValue << "\" mkdir \""
<< fixedValue << "\"" << endl;
+#else
+ t << "\t-@ if test ! -d \"" << fixedValue << "\"; then mkdir \""
+ << fixedValue << "\"" << "; fi" <<endl;
+#endif
}
}
}
@@ -314,7 +324,11 @@ void SymbianAbldMakefileGenerator::writeWrapperMakefile(QFile& wrapperFile, bool
// Note: EXTENSION_CLEAN will get called many times when doing reallyclean
// This is why the "2> NUL" gets appended to generated clean targets in makefile.cpp.
t << EXTENSION_CLEAN ": " COMPILER_CLEAN_TARGET << endl;
+#ifdef Q_OS_WIN32
generateCleanCommands(t, dirsToClean, var("QMAKE_DEL_DIR"), " /S /Q ", "", "");
+#else
+ generateCleanCommands(t, dirsToClean, "rm", " -rf ", "", "");
+#endif
t << endl;
t << PRE_TARGETDEPS_TARGET ":"
@@ -441,21 +455,31 @@ bool SymbianAbldMakefileGenerator::writeDeploymentTargets(QTextStream &t)
void SymbianAbldMakefileGenerator::writeStoreBuildTarget(QTextStream &t)
{
+#ifdef Q_OS_WIN
+#define HASH "#"
+#define EMPTYECHO "."
+#else
+#define HASH "\\#"
+#define EMPTYECHO
+#endif
+
t << STORE_BUILD_TARGET ":" << endl;
- t << "\t@echo # ============================================================================== > " MAKE_CACHE_NAME << endl;
- t << "\t@echo # This file is generated by make and should not be modified by the user >> " MAKE_CACHE_NAME << endl;
- t << "\t@echo # Name : " << MAKE_CACHE_NAME << " >> " MAKE_CACHE_NAME << endl;
- t << "\t@echo # Part of : " << project->values("TARGET").join(" ") << " >> " MAKE_CACHE_NAME << endl;
- t << "\t@echo # Description : This file is used to cache last build target for >> " MAKE_CACHE_NAME << endl;
- t << "\t@echo # make sis target. >> " MAKE_CACHE_NAME << endl;
- t << "\t@echo # Version : >> " MAKE_CACHE_NAME << endl;
- t << "\t@echo # >> " MAKE_CACHE_NAME << endl;
- t << "\t@echo # ============================================================================== >> " MAKE_CACHE_NAME << endl;
- t << "\t@echo. >> " MAKE_CACHE_NAME << endl;
+ t << "\t@echo " HASH " ============================================================================== > " MAKE_CACHE_NAME << endl;
+ t << "\t@echo " HASH " This file is generated by make and should not be modified by the user >> " MAKE_CACHE_NAME << endl;
+ t << "\t@echo " HASH " Name : " << MAKE_CACHE_NAME << " >> " MAKE_CACHE_NAME << endl;
+ t << "\t@echo " HASH " Part of : " << project->values("TARGET").join(" ") << " >> " MAKE_CACHE_NAME << endl;
+ t << "\t@echo " HASH " Description : This file is used to cache last build target for >> " MAKE_CACHE_NAME << endl;
+ t << "\t@echo " HASH " make sis target. >> " MAKE_CACHE_NAME << endl;
+ t << "\t@echo " HASH " Version : >> " MAKE_CACHE_NAME << endl;
+ t << "\t@echo " HASH " >> " MAKE_CACHE_NAME << endl;
+ t << "\t@echo " HASH " ============================================================================== >> " MAKE_CACHE_NAME << endl;
+ t << "\t@echo" EMPTYECHO " >> " MAKE_CACHE_NAME << endl;
t << "\t@echo QT_SIS_TARGET ?= $(QT_SIS_TARGET) >> " MAKE_CACHE_NAME << endl;
t << endl;
generatedFiles << MAKE_CACHE_NAME;
+#undef HASH
+#undef EMPTYECHO
}
void SymbianAbldMakefileGenerator::writeBldInfMkFilePart(QTextStream& t, bool addDeploymentExtension)