Correctly package managed runtime-only files (#2741)

This commit is contained in:
Matthew Leibowitz 2024-02-05 23:31:09 +02:00 коммит произвёл GitHub
Родитель 7e4dc6959d
Коммит 8396031c40
Не найден ключ, соответствующий данной подписи
Идентификатор ключа GPG: B5690EEEBB952194
2 изменённых файлов: 11 добавлений и 7 удалений

Просмотреть файл

@ -33,16 +33,20 @@
</PropertyGroup>
<ItemGroup Condition="'$(IsWindowsNativeAssets)' == 'true'">
<None Include="@(NativeWindowsPackageFile)" Link="runtimes\%(RuntimeIdentifier)\native\%(Filename)%(Extension)" />
<_NativeWindowsPackageFileToUse Include="@(NativeWindowsPackageFile->HasMetadata('Folder'))" />
<_NativeWindowsPackageFileWithNoFolder Include="@(NativeWindowsPackageFile)" />
<_NativeWindowsPackageFileWithNoFolder Remove="@(_NativeWindowsPackageFileToUse)" />
<_NativeWindowsPackageFileToUse Include="@(_NativeWindowsPackageFileWithNoFolder)" Folder="native" />
<None Include="@(_NativeWindowsPackageFileToUse)" Link="runtimes\%(RuntimeIdentifier)\%(Folder)\%(Filename)%(Extension)" />
</ItemGroup>
<Target Name="_IncludeRuntimesPackageFiles" BeforeTargets="_GetPackageFiles" Condition="'$(IsWindowsNativeAssets)' == 'true'">
<ItemGroup>
<_CompletedNativeWindowsPackageFile
Include="@(NativeWindowsPackageFile)"
Include="@(_NativeWindowsPackageFileToUse)"
TargetFramework="%(RuntimeIdentifier)"
TargetPath="native\%(Filename)%(Extension)"
PackagePath="runtimes\%(RuntimeIdentifier)\native\%(Filename)%(Extension)" />
TargetPath="%(Folder)\%(Filename)%(Extension)"
PackagePath="runtimes\%(RuntimeIdentifier)\%(Folder)\%(Filename)%(Extension)" />
<_BuildOutputInPackage Remove="@(_BuildOutputInPackage)" />
<_BuildOutputInPackage Include="@(_CompletedNativeWindowsPackageFile)" Condition="'%(Extension)' != '.pdb'" />
<_TargetPathsToSymbols Remove="@(_TargetPathsToSymbols)" />

Просмотреть файл

@ -6,11 +6,11 @@
<IsWindowsNativeAssets>true</IsWindowsNativeAssets>
</PropertyGroup>
<ItemGroup>
<NativeWindowsPackageFile Include="..\..\output\native\winui\any\*" RuntimeIdentifier="win-x64" />
<NativeWindowsPackageFile Include="..\..\output\native\winui\any\*" RuntimeIdentifier="win-x64" Folder="lib\$(WindowsTargetFrameworksCurrent)" />
<NativeWindowsPackageFile Include="..\..\output\native\winui\x64\*" RuntimeIdentifier="win-x64" />
<NativeWindowsPackageFile Include="..\..\output\native\winui\any\*" RuntimeIdentifier="win-x86" />
<NativeWindowsPackageFile Include="..\..\output\native\winui\any\*" RuntimeIdentifier="win-x86" Folder="lib\$(WindowsTargetFrameworksCurrent)" />
<NativeWindowsPackageFile Include="..\..\output\native\winui\x86\*" RuntimeIdentifier="win-x86" />
<NativeWindowsPackageFile Include="..\..\output\native\winui\any\*" RuntimeIdentifier="win-arm64" />
<NativeWindowsPackageFile Include="..\..\output\native\winui\any\*" RuntimeIdentifier="win-arm64" Folder="lib\$(WindowsTargetFrameworksCurrent)" />
<NativeWindowsPackageFile Include="..\..\output\native\winui\arm64\*" RuntimeIdentifier="win-arm64" />
</ItemGroup>
</Project>