Escape path names in qmake-generated Makefiles.
authorAndreas Hartmetz <andreas.hartmetz@kdab.com>
Mon, 30 Jan 2012 21:06:51 +0000 (22:06 +0100)
committerQt by Nokia <qt-info@nokia.com>
Tue, 31 Jan 2012 10:47:11 +0000 (11:47 +0100)
qmake-generated Makefiles since 4.6 (according to bug report) contain
recursive qmake invocations with absolute paths to .pro files, where the
absolute paths are not escaped.

Task-number: QTBUG-11776
Change-Id: I49772c7d9147efea3bb7b9623c61d92aa0bb6857
Reviewed-by: Jonas Gastal <jgastal@profusion.mobi>
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
qmake/generators/makefile.cpp

index 0d1a898..59e17b0 100644 (file)
@@ -2489,7 +2489,7 @@ MakefileGenerator::writeSubTargets(QTextStream &t, QList<MakefileGenerator::SubT
         //qmake it
         if(!subtarget->profile.isEmpty()) {
             QString out = subtarget->makefile;
-            QString in = fileFixify(in_directory + subtarget->profile, FileFixifyAbsolute);
+            QString in = escapeFilePath(fileFixify(in_directory + subtarget->profile, FileFixifyAbsolute));
             if(out.startsWith(in_directory))
                 out = out.mid(in_directory.length());
             t << mkfile << ": " << "\n\t";