aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAli Can Demiralp <ali.demiralp@qt.io>2024-01-10 15:47:33 +0100
committerAli Can Demiralp <ali.demiralp@qt.io>2024-01-15 11:17:44 +0000
commite942e8e3dccf8805494822d321352b0bac9861ef (patch)
treeb0ad5e04c303efaddc7d9ca80c75335b6b759033
parent2f53ab04f58558b503542169a933e66ea38631b9 (diff)
Ensure parameters of MakeRelative are quoted
This prevents cases where commas in filepaths interfere with the commas that are used to split the function parameters. Fixes: QTVSADDINBUG-1124 Change-Id: I83863d708f9bcacc45ba7b1de7af81af90248235 Reviewed-by: Karsten Heimrich <karsten.heimrich@qt.io>
-rw-r--r--QtMSBuild/QtMsBuild/moc/qtmoc.targets4
-rw-r--r--QtMSBuild/QtMsBuild/qml/qtqml_cache.targets6
-rw-r--r--QtMSBuild/QtMsBuild/rcc/qtrcc.targets2
3 files changed, 6 insertions, 6 deletions
diff --git a/QtMSBuild/QtMsBuild/moc/qtmoc.targets b/QtMSBuild/QtMsBuild/moc/qtmoc.targets
index f54a4d4b..d283ff30 100644
--- a/QtMSBuild/QtMsBuild/moc/qtmoc.targets
+++ b/QtMSBuild/QtMsBuild/moc/qtmoc.targets
@@ -424,11 +424,11 @@
<!--// Get relative path to output -->
<output_relative
->$([MSBuild]::MakeRelative($(ProjectDir), %(QtMoc.OutputFile)).TrimStart('\'))</output_relative>
+>$([MSBuild]::MakeRelative('$(ProjectDir)', '%(QtMoc.OutputFile)').TrimStart('\'))</output_relative>
<!--// Get relative path to input -->
<input_relative
->$([MSBuild]::MakeRelative($(ProjectDir), %(QtMoc.InputFile)).TrimStart('\'))</input_relative>
+>$([MSBuild]::MakeRelative('$(ProjectDir)', '%(QtMoc.InputFile)').TrimStart('\'))</input_relative>
</PropertyGroup>
<!--
diff --git a/QtMSBuild/QtMsBuild/qml/qtqml_cache.targets b/QtMSBuild/QtMsBuild/qml/qtqml_cache.targets
index d16fbc31..78126c1a 100644
--- a/QtMSBuild/QtMsBuild/qml/qtqml_cache.targets
+++ b/QtMSBuild/QtMsBuild/qml/qtqml_cache.targets
@@ -250,7 +250,7 @@
<!--
// $(relative_path) ::= path of filtered file, relative to project directory -->
<relative_path Condition="'%(QtRccFilter.QtQmlCacheItems)' != ''"
->$([MSBuild]::MakeRelative($(MSBuildProjectDirectory),$(full_path)).TrimStart('\'))</relative_path>
+>$([MSBuild]::MakeRelative('$(MSBuildProjectDirectory)', '$(full_path)').TrimStart('\'))</relative_path>
<!--
// $(run_parallel) ::= run qmlcachegen in a parallel process
// $(run_single) ::= run qmlcachegen in single process mode -->
@@ -410,7 +410,7 @@
<!--// Get relative path to output -->
<cache_loader_path>@(loader->'%(QmlCacheLoaderFile)')</cache_loader_path>
<output_relative
->$([MSBuild]::MakeRelative($(ProjectDir), $(cache_loader_path)).TrimStart('\'))</output_relative>
+>$([MSBuild]::MakeRelative('$(ProjectDir)', '$(cache_loader_path)').TrimStart('\'))</output_relative>
</PropertyGroup>
<ItemGroup>
<!--
@@ -540,7 +540,7 @@
<!--// Get relative path to output -->
<output_relative
->$([MSBuild]::MakeRelative($(ProjectDir), %(QtQmlCacheItem.OutputFile)).TrimStart('\'))</output_relative>
+>$([MSBuild]::MakeRelative('$(ProjectDir)', '%(QtQmlCacheItem.OutputFile)').TrimStart('\'))</output_relative>
</PropertyGroup>
<ItemGroup>
<!--
diff --git a/QtMSBuild/QtMsBuild/rcc/qtrcc.targets b/QtMSBuild/QtMsBuild/rcc/qtrcc.targets
index 184bbe96..049ca2c7 100644
--- a/QtMSBuild/QtMsBuild/rcc/qtrcc.targets
+++ b/QtMSBuild/QtMsBuild/rcc/qtrcc.targets
@@ -465,7 +465,7 @@
<!--// Get relative path to output -->
<output_relative
->$([MSBuild]::MakeRelative($(ProjectDir), %(QtRcc.OutputFile)).TrimStart('\'))</output_relative>
+>$([MSBuild]::MakeRelative('$(ProjectDir)', '%(QtRcc.OutputFile)').TrimStart('\'))</output_relative>
</PropertyGroup>
<!--