54 行
3.0 KiB
XML
54 行
3.0 KiB
XML
<Project>
|
|
|
|
<!-- Get the analyzer from the ComputeSharp.Pix NuGet package -->
|
|
<Target Name="_ComputeSharpPixLinkNativeLibraries"
|
|
AfterTargets="ResolvePackageDependenciesForBuild;ResolveNuGetPackageAssets"
|
|
BeforeTargets="CheckForDuplicateItems;PrepareForBuild">
|
|
<PropertyGroup>
|
|
|
|
<!-- PIX version (this needs to be kept in sync with the one in the .csproj) -->
|
|
<ComputeSharpPixWinPixEventRuntimeVersion>winpixeventruntime.1.0.220810001</ComputeSharpPixWinPixEventRuntimeVersion>
|
|
|
|
<!-- Detect whether the target project is UWP-->
|
|
<ComputeSharpPixShouldUnpackUapPixNativeLibraries>false</ComputeSharpPixShouldUnpackUapPixNativeLibraries>
|
|
<ComputeSharpPixShouldUnpackUapPixNativeLibraries Condition="'$(TargetFrameworkIdentifier)' == 'UAP'">true</ComputeSharpPixShouldUnpackUapPixNativeLibraries>
|
|
|
|
<!-- Detect the target project CPU architecture -->
|
|
<ComputeSharpPixShouldUnpackArm64PixNativeLibraries>false</ComputeSharpPixShouldUnpackArm64PixNativeLibraries>
|
|
<ComputeSharpPixShouldUnpackArm64PixNativeLibraries Condition="'$(Platform)' == 'arm64'">true</ComputeSharpPixShouldUnpackArm64PixNativeLibraries>
|
|
</PropertyGroup>
|
|
|
|
<!-- Win32, x64 -->
|
|
<ItemGroup Condition="'$(ComputeSharpPixShouldUnpackUapPixNativeLibraries)' == 'False' AND '$(ComputeSharpPixShouldUnpackArm64PixNativeLibraries)' == 'False'">
|
|
<None Include="$(MSBuildThisFileDirectory)..\$(ComputeSharpPixWinPixEventRuntimeVersion)\x64\WinPixEventRuntime.dll"
|
|
Link="WinPixEventRuntime.dll"
|
|
Visible="False"
|
|
CopyToOutputDirectory="PreserveNewest" />
|
|
</ItemGroup>
|
|
|
|
<!-- Win32, arm64 -->
|
|
<ItemGroup Condition="'$(ComputeSharpPixShouldUnpackUapPixNativeLibraries)' == 'False' AND '$(ComputeSharpPixShouldUnpackArm64PixNativeLibraries)' == 'True'">
|
|
<None Include="$(MSBuildThisFileDirectory)..\$(ComputeSharpPixWinPixEventRuntimeVersion)\arm64\WinPixEventRuntime.dll"
|
|
Link="WinPixEventRuntime.dll"
|
|
Visible="False"
|
|
CopyToOutputDirectory="PreserveNewest" />
|
|
</ItemGroup>
|
|
|
|
<!-- UWP, x64 -->
|
|
<ItemGroup Condition="'$(ComputeSharpPixShouldUnpackUapPixNativeLibraries)' == 'True' AND '$(ComputeSharpPixShouldUnpackArm64PixNativeLibraries)' == 'False'">
|
|
<None Include="$(MSBuildThisFileDirectory)..\$(ComputeSharpPixWinPixEventRuntimeVersion)\x64\WinPixEventRuntime_UAP.dll"
|
|
Link="WinPixEventRuntime.dll"
|
|
Visible="False"
|
|
CopyToOutputDirectory="PreserveNewest" />
|
|
</ItemGroup>
|
|
|
|
<!-- UWP, arm64 -->
|
|
<ItemGroup Condition="'$(ComputeSharpPixShouldUnpackUapPixNativeLibraries)' == 'True' AND '$(ComputeSharpPixShouldUnpackArm64PixNativeLibraries)' == 'True'">
|
|
<None Include="$(MSBuildThisFileDirectory)..\$(ComputeSharpPixWinPixEventRuntimeVersion)\arm64\WinPixEventRuntime_UAP.dll"
|
|
Link="WinPixEventRuntime.dll"
|
|
Visible="False"
|
|
CopyToOutputDirectory="PreserveNewest" />
|
|
</ItemGroup>
|
|
</Target>
|
|
</Project>
|