summaryrefslogtreecommitdiffstats
path: root/qmake/generators
diff options
context:
space:
mode:
authorJoerg Bornemann <joerg.bornemann@qt.io>2021-10-22 15:38:47 +0200
committerJoerg Bornemann <joerg.bornemann@qt.io>2021-10-25 10:10:08 +0200
commit1a44090df533de10d456f82bcbac61dd5ae66831 (patch)
tree1d21e89109d10905c4336847e2985169fc25d711 /qmake/generators
parent6bf41058a64ad86b8f3a54652bf2132c08a336e0 (diff)
qmake/vcxproj: Fix malformed <Message> tags
Extra compilers and the command set to "\n" would result in malformed <Message> tags in vcxproj files. Those tags are used to display the name of the extra compiler when building. Setting the extra compiler's command to "\n" is a common trick to force the creation of the rule. Make sure to trim the command name that is created from the extra compiler's command to avoid such new-line-only bogus message tags. Pick-to: 6.2 5.15 Change-Id: I1bae28ed14c438d777f96280c6b2cf5ca315b51c Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
Diffstat (limited to 'qmake/generators')
-rw-r--r--qmake/generators/win32/msvc_objectmodel.cpp1
1 files changed, 1 insertions, 0 deletions
diff --git a/qmake/generators/win32/msvc_objectmodel.cpp b/qmake/generators/win32/msvc_objectmodel.cpp
index ef00e0d9e8..c8b25fe61d 100644
--- a/qmake/generators/win32/msvc_objectmodel.cpp
+++ b/qmake/generators/win32/msvc_objectmodel.cpp
@@ -2437,6 +2437,7 @@ bool VCFilter::addExtraCompiler(const VCFilterFile &info)
cmd_name = cmd.left(space);
else
cmd_name = cmd;
+ cmd_name = cmd_name.trimmed();
}
// Fixify paths