11<Project >
22
3- <Import Project =" ..\Directory.Build.targets " />
3+ <Import Project =" ..\$(MSBuildThisFile) " />
44
5- <!-- Define NETSTANDARD2_1_OR_GREATER for .NET Standard 2.1 targets and above -->
6- <PropertyGroup Condition =" '$(TargetFramework)' == 'net6.0' OR '$(TargetFramework)' == 'net7.0'" >
7- <DefineConstants >NETSTANDARD2_1_OR_GREATER</DefineConstants >
8- </PropertyGroup >
9-
10- <!-- Configure trimming for projects on .NET 6 and above -->
11- <PropertyGroup Condition =" '$(TargetFramework)' == 'net6.0' OR '$(TargetFramework)' == 'net7.0'" >
12- <EnableTrimAnalyzer >true</EnableTrimAnalyzer >
5+ <PropertyGroup Condition =" '$(_NET_6_OR_GREATER)' == 'true'" >
136 <IsTrimmable >true</IsTrimmable >
7+ <EnableTrimAnalyzer >true</EnableTrimAnalyzer >
8+ <DefineConstants >NETSTANDARD2_1_OR_GREATER</DefineConstants >
149 </PropertyGroup >
1510
16- <!--
17- The following target has been ported from TerraFX.Interop.Windows.
18- See: https://github.com/terrafx/terrafx.interop.windows.
19- Using [module: SkipLocalsInit] suppresses the .init flag for local variables for the entire module.
20- This doesn't affect the correctness of methods in this assembly, as none of them are relying on the
21- JIT ensuring that all local memory is zeroed out to work. Doing this can provide some minor
22- performance benefits, depending on the workload.
23- -->
24- <PropertyGroup >
25- <GeneratedSkipLocalsInitFile Condition =" '$(GeneratedSkipLocalsInitFile)' == ''" >$(IntermediateOutputPath)$(MSBuildProjectName).SkipLocalsInit.g.cs</GeneratedSkipLocalsInitFile >
26- <GeneratedSkipLocalsInitFileLines >
27- <![CDATA[ //------------------------------------------------------------------------------
28- // <auto-generated>
29- // This code was generated by a tool.
30- //
31- // Changes to this file may cause incorrect behavior and will be lost if
32- // the code is regenerated.
33- // </auto-generated>
34- //------------------------------------------------------------------------------
35-
36- [module: global::System.Runtime.CompilerServices.SkipLocalsInitAttribute]]]>
37- </GeneratedSkipLocalsInitFileLines >
38- </PropertyGroup >
39-
40- <Target Name =" GenerateSkipLocalsInit"
41- BeforeTargets =" BeforeCompile;CoreCompile"
42- DependsOnTargets =" PrepareForBuild"
43- Condition =" '$(Language)' == 'C#'"
44- Inputs =" $(MSBuildAllProjects)"
45- Outputs =" $(GeneratedSkipLocalsInitFile)" >
46-
47- <!-- Write the file with the attribute -->
48- <WriteLinesToFile Lines =" $(GeneratedSkipLocalsInitFileLines)" Overwrite =" true" WriteOnlyWhenDifferent =" true" File =" $(GeneratedSkipLocalsInitFile)" />
11+ <ItemGroup >
12+ <Compile Include =" $(BuildToolsDirectory)AssemblyInfo.Shared.cs" LinkBase =" Properties" Visible =" False" />
13+ </ItemGroup >
4914
50- <!-- Include the generated file in the list of files to compile -->
51- <ItemGroup >
52- <Compile Include =" $(GeneratedSkipLocalsInitFile)" />
53- </ItemGroup >
54- </Target >
15+ <ItemGroup >
16+ <InternalsVisibleTo Update =" @(InternalsVisibleTo)" PublicKey =" $(AssemblySignPublicKey)" Condition =" @(InternalsVisibleTo->Count()) != 0" />
17+ </ItemGroup >
5518
5619</Project >
0 commit comments