Skip to content

Commit

Permalink
Build: Copy resources when building for ARM64 with MSBuild
Browse files Browse the repository at this point in the history
  • Loading branch information
TheLastRar authored and F0bes committed Aug 10, 2024
1 parent c3ed4fa commit e25cb92
Show file tree
Hide file tree
Showing 3 changed files with 34 additions and 0 deletions.
32 changes: 32 additions & 0 deletions common/vsprops/CopyResources.props
Original file line number Diff line number Diff line change
@@ -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>
1 change: 1 addition & 0 deletions pcsx2-gsrunner/pcsx2-gsrunner.vcxproj
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@
<Import Project="$(SolutionDir)common\vsprops\BaseProperties.props" />
<Import Project="$(SolutionDir)common\vsprops\GenerateSCMVersion.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(Devel))" Project="$(SolutionDir)common\vsprops\CodeGen_Devel.props" />
<Import Condition="$(Configuration.Contains(Release))" Project="$(SolutionDir)common\vsprops\CodeGen_Release.props" />
Expand Down
1 change: 1 addition & 0 deletions pcsx2-qt/pcsx2-qt.vcxproj
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@
<Import Project="$(SolutionDir)common\vsprops\GenerateSCMVersion.props" />
<Import Project="$(SolutionDir)common\vsprops\QtCompile.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(Devel))" Project="$(SolutionDir)common\vsprops\CodeGen_Devel.props" />
<Import Condition="$(Configuration.Contains(Release))" Project="$(SolutionDir)common\vsprops\CodeGen_Release.props" />
Expand Down

0 comments on commit e25cb92

Please sign in to comment.