Skip to content

Commit 9713fda

Browse files
authored
Use IsAotCompatible for libraries (#118149)
Instead of EnableAOTAnalyzer. This is necessary for the AssemblyMetadata IsAotCompatible="True" to make it into our libraries.
1 parent 73d13d9 commit 9713fda

File tree

20 files changed

+20
-21
lines changed

20 files changed

+20
-21
lines changed

src/libraries/Directory.Build.props

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -48,8 +48,8 @@
4848
<!-- Nullability is enabled by default except for test projects, which instead default to annotations. -->
4949
<Nullable Condition="'$(Nullable)' == '' and '$(IsTestProject)' != 'true'">enable</Nullable>
5050
<Nullable Condition="'$(Nullable)' == '' and '$(IsTestProject)' == 'true'">annotations</Nullable>
51-
<!-- EnableAOTAnalyzer is enabled by default for src projects. -->
52-
<EnableAOTAnalyzer Condition="'$(EnableAOTAnalyzer)' == '' and '$(IsSourceProject)' == 'true'">true</EnableAOTAnalyzer>
51+
<!-- AOT compatibility is enabled by default for src projects. -->
52+
<IsAotCompatible Condition="'$(IsAotCompatible)' == '' and '$(IsSourceProject)' == 'true'">true</IsAotCompatible>
5353
</PropertyGroup>
5454

5555
<!-- Set up common paths -->

src/libraries/Microsoft.CSharp/src/Microsoft.CSharp.csproj

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313
<DefineConstants Condition="'$(EnableComBinder)' == 'true'">$(DefineConstants);ENABLECOMBINDER</DefineConstants>
1414
<AllowUnsafeBlocks Condition="'$(EnableComBinder)' == 'true'">true</AllowUnsafeBlocks>
1515
<DefineConstants>$(DefineConstants);LEGACY_GETRESOURCESTRING_USER</DefineConstants>
16-
<EnableAOTAnalyzer>true</EnableAOTAnalyzer>
16+
<IsAotCompatible>true</IsAotCompatible>
1717
</PropertyGroup>
1818

1919
<ItemGroup>

src/libraries/Microsoft.Extensions.DependencyInjection.Specification.Tests/src/Microsoft.Extensions.DependencyInjection.Specification.Tests.csproj

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
<EnableDefaultItems>true</EnableDefaultItems>
88
<CLSCompliant>false</CLSCompliant>
99
<IsTrimmable>false</IsTrimmable>
10-
<EnableAOTAnalyzer>false</EnableAOTAnalyzer>
10+
<IsAotCompatible>false</IsAotCompatible>
1111
<NoWarn>$(NoWarn);CA1852</NoWarn>
1212
<!-- Public API in this assembly is only for tests and don't need to be documented. -->
1313
<NoWarn>$(NoWarn);1591</NoWarn>

src/libraries/System.ComponentModel.Composition/src/System.ComponentModel.Composition.csproj

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
<PropertyGroup>
44
<TargetFrameworks>$(NetCoreAppCurrent);$(NetCoreAppPrevious);$(NetCoreAppMinimum);netstandard2.0</TargetFrameworks>
5-
<EnableAOTAnalyzer>false</EnableAOTAnalyzer>
5+
<IsAotCompatible>false</IsAotCompatible>
66
<UseCompilerGeneratedDocXmlFile>false</UseCompilerGeneratedDocXmlFile>
77
<IsPackable>true</IsPackable>
88
<AddNETFrameworkPlaceholderFileToPackage>true</AddNETFrameworkPlaceholderFileToPackage>

src/libraries/System.Composition.Hosting/src/System.Composition.Hosting.csproj

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
<PropertyGroup>
44
<TargetFrameworks>$(NetCoreAppCurrent);$(NetCoreAppPrevious);$(NetCoreAppMinimum);netstandard2.0;$(NetFrameworkMinimum)</TargetFrameworks>
55
<IsTrimmable>false</IsTrimmable>
6-
<EnableAOTAnalyzer>false</EnableAOTAnalyzer>
6+
<IsAotCompatible>false</IsAotCompatible>
77
<StrongNameKeyId>Microsoft</StrongNameKeyId>
88
<UseCompilerGeneratedDocXmlFile>false</UseCompilerGeneratedDocXmlFile>
99
<IsPackable>true</IsPackable>

src/libraries/System.Composition.Runtime/src/System.Composition.Runtime.csproj

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
<PropertyGroup>
44
<TargetFrameworks>$(NetCoreAppCurrent);$(NetCoreAppPrevious);$(NetCoreAppMinimum);netstandard2.0;$(NetFrameworkMinimum)</TargetFrameworks>
55
<RootNamespace>System.Composition</RootNamespace>
6-
<EnableAOTAnalyzer>false</EnableAOTAnalyzer>
6+
<IsAotCompatible>false</IsAotCompatible>
77
<StrongNameKeyId>Microsoft</StrongNameKeyId>
88
<UseCompilerGeneratedDocXmlFile>false</UseCompilerGeneratedDocXmlFile>
99
<IsPackable>true</IsPackable>

src/libraries/System.Composition.TypedParts/src/System.Composition.TypedParts.csproj

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
<TargetFrameworks>$(NetCoreAppCurrent);$(NetCoreAppPrevious);$(NetCoreAppMinimum);netstandard2.0;$(NetFrameworkMinimum)</TargetFrameworks>
55
<RootNamespace>System.Composition</RootNamespace>
66
<IsTrimmable>false</IsTrimmable>
7-
<EnableAOTAnalyzer>false</EnableAOTAnalyzer>
7+
<IsAotCompatible>false</IsAotCompatible>
88
<StrongNameKeyId>Microsoft</StrongNameKeyId>
99
<UseCompilerGeneratedDocXmlFile>false</UseCompilerGeneratedDocXmlFile>
1010
<IsPackable>true</IsPackable>

src/libraries/System.Configuration.ConfigurationManager/src/System.Configuration.ConfigurationManager.csproj

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
<PropertyGroup>
44
<TargetFrameworks>$(NetCoreAppCurrent);$(NetCoreAppPrevious);$(NetCoreAppMinimum);netstandard2.0;$(NetFrameworkMinimum)</TargetFrameworks>
55
<NoWarn>$(NoWarn);CA2249</NoWarn>
6-
<EnableAOTAnalyzer>false</EnableAOTAnalyzer>
6+
<IsAotCompatible>false</IsAotCompatible>
77
<IncludeInternalObsoleteAttribute>true</IncludeInternalObsoleteAttribute>
88
<UseCompilerGeneratedDocXmlFile>false</UseCompilerGeneratedDocXmlFile>
99
<IsPackable>true</IsPackable>

src/libraries/System.Data.Odbc/src/System.Data.Odbc.csproj

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
<TargetFrameworks Condition="'$(NetCoreAppPrevious)' != ''">$(TargetFrameworks);$(NetCoreAppPrevious)-windows;$(NetCoreAppPrevious)-unix;$(NetCoreAppPrevious)</TargetFrameworks>
66
<AllowUnsafeBlocks>true</AllowUnsafeBlocks>
77
<NoWarn>$(NoWarn);CA2249;CA1838</NoWarn>
8-
<EnableAOTAnalyzer>false</EnableAOTAnalyzer>
8+
<IsAotCompatible>false</IsAotCompatible>
99
<UseCompilerGeneratedDocXmlFile>false</UseCompilerGeneratedDocXmlFile>
1010
<IsPackable>true</IsPackable>
1111
<PackageDescription>Provides a collection of classes used to access an ODBC data source in the managed space

src/libraries/System.Data.OleDb/src/System.Data.OleDb.csproj

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
<NoWarn>$(NoWarn);CA2249</NoWarn>
99
<!-- Suppress SYSLIB0004: 'RuntimeHelpers.PrepareConstrainedRegions()' is obsolete to avoid ifdefs. -->
1010
<NoWarn>$(NoWarn);SYSLIB0004</NoWarn>
11-
<EnableAOTAnalyzer>false</EnableAOTAnalyzer>
11+
<IsAotCompatible>false</IsAotCompatible>
1212
<UseCompilerGeneratedDocXmlFile>false</UseCompilerGeneratedDocXmlFile>
1313
<IsPackable>true</IsPackable>
1414
<PackageDescription>Provides a collection of classes for OLEDB.

0 commit comments

Comments
 (0)