summaryrefslogtreecommitdiffstats
path: root/qmake
diff options
context:
space:
mode:
authorMartin Storsjo <martin@martin.st>2010-10-18 08:44:29 (GMT)
committerOswald Buddenhagen <oswald.buddenhagen@nokia.com>2010-10-18 08:44:29 (GMT)
commitb9de3553ad6f26e96c5432df8b1b6be02fa5f9ca (patch)
tree57fa58527779855b9760b5f6cd367d9ad972297b /qmake
parent3fcb43ac278ba50278f3141f1b7924b514723bf7 (diff)
downloadQt-b9de3553ad6f26e96c5432df8b1b6be02fa5f9ca.zip
Qt-b9de3553ad6f26e96c5432df8b1b6be02fa5f9ca.tar.gz
Qt-b9de3553ad6f26e96c5432df8b1b6be02fa5f9ca.tar.bz2
qmake/symbian: Make sure the destination directory exists before copying
cp on unix doesn't create the destination directory if it doesn't exist, as xcopy on windows does. This also requires QMAKE_MKDIR to use mkdir -p to be able to create directories recursively. Merge-request: 861 Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
Diffstat (limited to 'qmake')
-rw-r--r--qmake/generators/symbian/symmake_abld.cpp5
1 files changed, 5 insertions, 0 deletions
diff --git a/qmake/generators/symbian/symmake_abld.cpp b/qmake/generators/symbian/symmake_abld.cpp
index 4f645af..f895109 100644
--- a/qmake/generators/symbian/symmake_abld.cpp
+++ b/qmake/generators/symbian/symmake_abld.cpp
@@ -450,6 +450,11 @@ bool SymbianAbldMakefileGenerator::writeDeploymentTargets(QTextStream &t, bool i
t << "\t-$(XCOPY) \"" << depList.at(i).from << "\" \""
<< depList.at(i).to.left(depList.at(i).to.lastIndexOf("\\") + 1) << "\"" << endl;
#else
+ QString dirExists = var("QMAKE_CHK_DIR_EXISTS");
+ QString mkdir = var("QMAKE_MKDIR");
+ QString dir = QFileInfo(depList.at(i).to).dir().path();
+ t << "\t-@ " << dirExists << " \"" << dir << "\" || "
+ << mkdir << " \"" << dir << "\"" << endl;
t << "\t-$(XCOPY) \"" << QDir::toNativeSeparators(depList.at(i).from) << "\" \""
<< QDir::toNativeSeparators(depList.at(i).to) << "\"" << endl;
#endif