Build: Copy resources when building for ARM64 with MSBuild

This commit is contained in:
TheLastRar 2024-08-02 12:58:31 +01:00 committed by Ty
parent c3ed4faec1
commit e25cb92041
3 changed files with 34 additions and 0 deletions

View File

@ -0,0 +1,32 @@
<?xml version="1.0" encoding="utf-8"?>
<Project DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<!-- Copy resources for ARM -->
<ItemGroup>
<BinRes Include="$(SolutionDir)bin\resources\**\*" />
</ItemGroup>
<ItemGroup>
<BinDocs Include="$(SolutionDir)bin\docs\**\*" />
</ItemGroup>
<Target Name="CopyBinResources"
AfterTargets="Build"
Inputs="@(BinRes)"
Outputs="@(BinRes -> '$(OutDir)resources\%(RecursiveDir)%(Filename)%(Extension)')">
<Message Text="Copying Resources" Importance="High" />
<Copy
SourceFiles="@(BinRes)"
DestinationFolder="$(OutDir)resources\%(RecursiveDir)"
SkipUnchangedFiles="true"
/>
</Target>
<Target Name="CopyBinDocs"
AfterTargets="Build"
Inputs="@(BinDocs)"
Outputs="@(BinDocs -> '$(OutDir)docs\%(RecursiveDir)%(Filename)%(Extension)')">
<Message Text="Copying Docs" Importance="High" />
<Copy
SourceFiles="@(BinDocs)"
DestinationFolder="$(OutDir)docs\%(RecursiveDir)"
SkipUnchangedFiles="true"
/>
</Target>
</Project>

View File

@ -22,6 +22,7 @@
<Import Project="$(SolutionDir)common\vsprops\BaseProperties.props" /> <Import Project="$(SolutionDir)common\vsprops\BaseProperties.props" />
<Import Project="$(SolutionDir)common\vsprops\GenerateSCMVersion.props" /> <Import Project="$(SolutionDir)common\vsprops\GenerateSCMVersion.props" />
<Import Project="$(SolutionDir)common\vsprops\LinkPCSX2Deps.props" /> <Import Project="$(SolutionDir)common\vsprops\LinkPCSX2Deps.props" />
<Import Condition="'$(Platform)'=='ARM64'" Project="$(SolutionDir)common\vsprops\CopyResources.props" />
<Import Condition="$(Configuration.Contains(Debug))" Project="$(SolutionDir)common\vsprops\CodeGen_Debug.props" /> <Import Condition="$(Configuration.Contains(Debug))" Project="$(SolutionDir)common\vsprops\CodeGen_Debug.props" />
<Import Condition="$(Configuration.Contains(Devel))" Project="$(SolutionDir)common\vsprops\CodeGen_Devel.props" /> <Import Condition="$(Configuration.Contains(Devel))" Project="$(SolutionDir)common\vsprops\CodeGen_Devel.props" />
<Import Condition="$(Configuration.Contains(Release))" Project="$(SolutionDir)common\vsprops\CodeGen_Release.props" /> <Import Condition="$(Configuration.Contains(Release))" Project="$(SolutionDir)common\vsprops\CodeGen_Release.props" />

View File

@ -23,6 +23,7 @@
<Import Project="$(SolutionDir)common\vsprops\GenerateSCMVersion.props" /> <Import Project="$(SolutionDir)common\vsprops\GenerateSCMVersion.props" />
<Import Project="$(SolutionDir)common\vsprops\QtCompile.props" /> <Import Project="$(SolutionDir)common\vsprops\QtCompile.props" />
<Import Project="$(SolutionDir)common\vsprops\LinkPCSX2Deps.props" /> <Import Project="$(SolutionDir)common\vsprops\LinkPCSX2Deps.props" />
<Import Condition="'$(Platform)'=='ARM64'" Project="$(SolutionDir)common\vsprops\CopyResources.props" />
<Import Condition="$(Configuration.Contains(Debug))" Project="$(SolutionDir)common\vsprops\CodeGen_Debug.props" /> <Import Condition="$(Configuration.Contains(Debug))" Project="$(SolutionDir)common\vsprops\CodeGen_Debug.props" />
<Import Condition="$(Configuration.Contains(Devel))" Project="$(SolutionDir)common\vsprops\CodeGen_Devel.props" /> <Import Condition="$(Configuration.Contains(Devel))" Project="$(SolutionDir)common\vsprops\CodeGen_Devel.props" />
<Import Condition="$(Configuration.Contains(Release))" Project="$(SolutionDir)common\vsprops\CodeGen_Release.props" /> <Import Condition="$(Configuration.Contains(Release))" Project="$(SolutionDir)common\vsprops\CodeGen_Release.props" />