aboutsummaryrefslogtreecommitdiffstats
path: root/src/qtmsbuild/qtrcc.targets
diff options
context:
space:
mode:
authorMiguel Costa <miguel.costa@qt.io>2019-02-05 11:20:28 +0100
committerMiguel Costa <miguel.costa@qt.io>2019-02-08 13:13:30 +0000
commitc182b06ae34e91838261e391f5f1d3daa2d9293e (patch)
treebeb567ed6852ab1aaf0feb85776bf0611a0104ab /src/qtmsbuild/qtrcc.targets
parent31cf36b0543c32b186ff54df908c4dd7abbbe228 (diff)
Use relative paths for output of Qt tools
If the output of a Qt tool is given as an absolute path, this will now be converted during build to a path relative to the project directory This allows the use of %(RelativeDir) when referencing Qt outputs. Task-number: QTVSADDINBUG-611 Change-Id: I9643200ac43fe19b9908d06d100d59237ecc7a4e Reviewed-by: Oliver Wolff <oliver.wolff@qt.io>
Diffstat (limited to 'src/qtmsbuild/qtrcc.targets')
-rw-r--r--src/qtmsbuild/qtrcc.targets7
1 files changed, 6 insertions, 1 deletions
diff --git a/src/qtmsbuild/qtrcc.targets b/src/qtmsbuild/qtrcc.targets
index 0d95d1ac..71358cba 100644
--- a/src/qtmsbuild/qtrcc.targets
+++ b/src/qtmsbuild/qtrcc.targets
@@ -323,6 +323,10 @@
AND ('%(QtRcc.ParallelProcess)' != 'true'
OR '$(SelectedFiles)' != '')"
>true</run_single>
+
+ <!--// Get relative path to output -->
+ <output_relative
+>$([MSBuild]::MakeRelative($(ProjectDir), %(QtRcc.OutputFile)).TrimStart('\'))</output_relative>
</PropertyGroup>
<!--
@@ -342,7 +346,7 @@
<!--
///////////////////////////////////////////////////////////////////////////////////////////
// C++ dynamic source -->
- <ClCompile Condition="'%(QtRcc.DynamicSource)' == 'output'">%(QtRcc.OutputFile)</ClCompile>
+ <ClCompile Condition="'%(QtRcc.DynamicSource)' == 'output'">$(output_relative)</ClCompile>
<PrecompiledHeader>NotUsing</PrecompiledHeader>
</QtWork>
</ItemGroup>
@@ -357,6 +361,7 @@
<input_changed/>
<run_parallel/>
<run_single/>
+ <output_relative/>
</PropertyGroup>
<ItemGroup>
<rcc_InputFile Remove="@(rcc_InputFile)"/>