summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAndy Shaw <qt-info@nokia.com>2010-03-01 14:16:41 +0100
committerAndy Shaw <qt-info@nokia.com>2010-03-01 14:16:41 +0100
commitf3af7b746221cb44899f3e433659791f75255f21 (patch)
tree2d5f526696ea10ca2349c6bb6489d6f40ccfc654
parent8599a1002a6ed9ab8571d80f7e704b73de853f34 (diff)
Ensure that a library path with a space in it gets quoted on Windows
This was not happening when -L and -l was used and the path specified with -L was quoted. It would lose the quotes when combining it to get the full path for the library it found. Task-number: QTBUG-2433 Reviewed-by: Marius Storm-Olsen
-rw-r--r--qmake/generators/win32/winmakefile.cpp5
1 files changed, 4 insertions, 1 deletions
diff --git a/qmake/generators/win32/winmakefile.cpp b/qmake/generators/win32/winmakefile.cpp
index 9d3b4c62c6..0d03fa39e4 100644
--- a/qmake/generators/win32/winmakefile.cpp
+++ b/qmake/generators/win32/winmakefile.cpp
@@ -150,7 +150,10 @@ Win32MakefileGenerator::findLibraries(const QString &where)
if(QMakeMetaInfo::libExists((*it).local() + Option::dir_sep + lib) ||
exists((*it).local() + Option::dir_sep + lib + extension)) {
out = (*it).real() + Option::dir_sep + lib + extension;
- break;
+ if (out.contains(QLatin1Char(' '))) {
+ out.prepend(QLatin1Char('\"'));
+ out.append(QLatin1Char('\"'));
+ }
}
}
}