summaryrefslogtreecommitdiffstats
path: root/qmake
diff options
context:
space:
mode:
authorKurt Korbatits <kurt.korbatits@nokia.com>2012-01-12 11:17:21 +1000
committerQt by Nokia <qt-info@nokia.com>2012-01-14 05:36:54 +0100
commit0d128aded5e06f98fd8957ee79d5cb588f252914 (patch)
treec7cfddc241d20174145b6ddf9154599bb66ff6dc /qmake
parente97d77d5bc72c92f007b51d84f3fab7d16e62d21 (diff)
qmake wasn't handling spaces in names when dealing with extra installs.
When installing extra binaries the paths where not being escaped, causing stripping and deleting to fail when dealing with filenames that contained one or more spaces. Change-Id: Iba4517b1110f6af30f7e2662cb86024a8b7b81f7 Reviewed-by: Kurt Korbatits <kurt.korbatits@nokia.com> Reviewed-by: Lincoln Ramsay <lincoln.ramsay@nokia.com> Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
Diffstat (limited to 'qmake')
-rw-r--r--qmake/generators/makefile.cpp16
1 files changed, 8 insertions, 8 deletions
diff --git a/qmake/generators/makefile.cpp b/qmake/generators/makefile.cpp
index 84525bce5d..564d44d98f 100644
--- a/qmake/generators/makefile.cpp
+++ b/qmake/generators/makefile.cpp
@@ -1300,15 +1300,15 @@ MakefileGenerator::writeInstalls(QTextStream &t, const QString &installs, bool n
cmd = "-$(INSTALL_PROGRAM)";
else
cmd = "-$(INSTALL_FILE)";
- cmd += " " + escapeFilePath(wild) + " " + dst_file + "\n";
+ cmd += " " + escapeFilePath(wild) + " " + escapeFilePath(dst_file) + "\n";
target += cmd;
if(!project->isActiveConfig("debug") && !project->isActiveConfig("nostrip") &&
!fi.isDir() && fi.isExecutable() && !project->isEmpty("QMAKE_STRIP"))
target += QString("\t-") + var("QMAKE_STRIP") + " " +
- filePrefixRoot(root, fileFixify(dst + filestr, FileFixifyAbsolute, false)) + "\n";
+ escapeFilePath(filePrefixRoot(root, fileFixify(dst + filestr, FileFixifyAbsolute, false))) + "\n";
if(!uninst.isEmpty())
uninst.append("\n\t");
- uninst.append(rm_dir_contents + " " + filePrefixRoot(root, fileFixify(dst + filestr, FileFixifyAbsolute, false)));
+ uninst.append(rm_dir_contents + " " + escapeFilePath(filePrefixRoot(root, fileFixify(dst + filestr, FileFixifyAbsolute, false))));
continue;
}
QString local_dirstr = Option::fixPathToLocalOS(dirstr, true);
@@ -1332,11 +1332,11 @@ MakefileGenerator::writeInstalls(QTextStream &t, const QString &installs, bool n
} else {
cmd = QString(fi.isExecutable() ? "-$(INSTALL_PROGRAM)" : "-$(INSTALL_FILE)");
}
- cmd += " " + wild + " " + dst_file + "\n";
+ cmd += " " + escapeFilePath(wild) + " " + escapeFilePath(dst_file) + "\n";
target += cmd;
if(!uninst.isEmpty())
uninst.append("\n\t");
- uninst.append(rm_dir_contents + " " + filePrefixRoot(root, fileFixify(dst + filestr, FileFixifyAbsolute, false)));
+ uninst.append(rm_dir_contents + " " + escapeFilePath(filePrefixRoot(root, fileFixify(dst + filestr, FileFixifyAbsolute, false))));
}
for(int x = 0; x < files.count(); x++) {
QString file = files[x];
@@ -1344,7 +1344,7 @@ MakefileGenerator::writeInstalls(QTextStream &t, const QString &installs, bool n
continue;
if(!uninst.isEmpty())
uninst.append("\n\t");
- uninst.append(rm_dir_contents + " " + filePrefixRoot(root, fileFixify(dst + file, FileFixifyAbsolute, false)));
+ uninst.append(rm_dir_contents + " " + escapeFilePath(filePrefixRoot(root, fileFixify(dst + file, FileFixifyAbsolute, false))));
QFileInfo fi(fileInfo(dirstr + file));
if(!target.isEmpty())
target += "\t";
@@ -1355,12 +1355,12 @@ MakefileGenerator::writeInstalls(QTextStream &t, const QString &installs, bool n
dst_file += fi.fileName();
}
QString cmd = QString(fi.isDir() ? "-$(INSTALL_DIR)" : "-$(INSTALL_FILE)") + " " +
- dirstr + file + " " + dst_file + "\n";
+ escapeFilePath(dirstr + file) + " " + escapeFilePath(dst_file) + "\n";
target += cmd;
if(!project->isActiveConfig("debug") && !project->isActiveConfig("nostrip") &&
!fi.isDir() && fi.isExecutable() && !project->isEmpty("QMAKE_STRIP"))
target += QString("\t-") + var("QMAKE_STRIP") + " " +
- filePrefixRoot(root, fileFixify(dst + file, FileFixifyAbsolute, false)) +
+ escapeFilePath(filePrefixRoot(root, fileFixify(dst + file, FileFixifyAbsolute, false))) +
"\n";
}
}