Enable CsWinRT AOT generator, fix IIDOptimizer errors
このコミットが含まれているのは:
1 親
bac700d170
コミット
b8ef998686
3ファイル変更
+34
検索条件に一致するファイルはありません
@@ -12,6 +12,12 @@
|
||||
|
||||
<PropertyGroup>
|
||||
|
||||
<!--
|
||||
Generate a .pdb file to avoid IIDOptimizer build errors.
|
||||
See: https://github.com/microsoft/CsWinRT/issues/1478.
|
||||
-->
|
||||
<DebugType>full</DebugType>
|
||||
|
||||
<!-- Suppress warnings for using directives inside namespaces (needed to avoid some WinRT conflicts) -->
|
||||
<NoWarn>$(NoWarn);IDE0065</NoWarn>
|
||||
|
||||
@@ -44,6 +50,12 @@
|
||||
|
||||
<ItemGroup>
|
||||
<PackageReference Include="TerraFX.Interop.Windows" Version="10.0.22621.6" />
|
||||
|
||||
<!--
|
||||
Reference CsWinRT locally for the source generators (see comments in ComputeSharp.D2D1.WinUI).
|
||||
Note that this is an executable and not a library, so we must drop the 'PrivateAssets' here.
|
||||
-->
|
||||
<PackageReference Include="Microsoft.Windows.CsWinRT" Version="2.0.6" />
|
||||
</ItemGroup>
|
||||
|
||||
<!-- Note: using SetPlatform="Platform=AnyCPU" for the analyzers to avoid issues (see https://github.com/dotnet/roslyn/issues/70148) -->
|
||||
|
||||
@@ -8,6 +8,13 @@
|
||||
|
||||
<PropertyGroup>
|
||||
|
||||
<!--
|
||||
Disable IIDOptimizer, as it's causing a build error when the debug mode is set to embedded.
|
||||
This is only needed when generating projections anyway, and not in normal C# class libraries.
|
||||
See: https://github.com/microsoft/CsWinRT/issues/1478.
|
||||
-->
|
||||
<CsWinRTIIDOptimizerOptOut>true</CsWinRTIIDOptimizerOptOut>
|
||||
|
||||
<!--
|
||||
Ignore some warnings about ambiguous cref attribute references. These are because the assembly defines
|
||||
blittable bindings for several ABI types from Win2D, in the same namespace as the ABI types from the
|
||||
@@ -26,6 +33,12 @@
|
||||
|
||||
<ItemGroup>
|
||||
<PackageReference Include="Microsoft.Graphics.Win2D" Version="1.2.0" />
|
||||
|
||||
<!--
|
||||
We need the CsWinRT reference for the generator to kick in and generate all necessary supporting code
|
||||
to make the exposed types AOT compatible. Since we only need the generator, we can mark this as private.
|
||||
-->
|
||||
<PackageReference Include="Microsoft.Windows.CsWinRT" Version="2.0.6" PrivateAssets="all" />
|
||||
</ItemGroup>
|
||||
|
||||
<ItemGroup>
|
||||
|
||||
@@ -6,8 +6,17 @@
|
||||
<RuntimeIdentifiers>win-x64;win-arm64</RuntimeIdentifiers>
|
||||
</PropertyGroup>
|
||||
|
||||
<PropertyGroup>
|
||||
|
||||
<!-- Disable IIDOptimizer, as it's not needed (see comments in ComputeSharp.D2D1.WinUI)-->
|
||||
<CsWinRTIIDOptimizerOptOut>true</CsWinRTIIDOptimizerOptOut>
|
||||
</PropertyGroup>
|
||||
|
||||
<ItemGroup>
|
||||
<PackageReference Include="Microsoft.WindowsAppSDK" Version="1.5.240428000" />
|
||||
|
||||
<!-- Reference CsWinRT locally for the source generators (see comments in ComputeSharp.D2D1.WinUI) -->
|
||||
<PackageReference Include="Microsoft.Windows.CsWinRT" Version="2.0.6" PrivateAssets="all" />
|
||||
</ItemGroup>
|
||||
|
||||
<ItemGroup>
|
||||
|
||||
新しいイシューから参照
ユーザーをブロックする