From 96159b2e5ee2e7fcf4087b4d46e5d69fbb71ec38 Mon Sep 17 00:00:00 2001 From: Matt Mitchell Date: Thu, 15 Feb 2024 09:48:18 -0800 Subject: [PATCH] Update unified build controls (#98330) Generally a straight port. Removed ArcadeBuildFromSource and ArcadeBuildVertical and replaced with DotNetBuild. --- Build.proj | 2 +- Directory.Build.props | 24 +++++++++---------- Directory.Build.targets | 4 ++-- eng/Analyzers.targets | 2 +- eng/DiaSymReaderNative.targets | 2 +- eng/DotNetBuild.props | 9 ++++--- eng/Subsets.props | 18 +++++++------- eng/Tools.props | 2 +- eng/Versions.props | 4 ++-- eng/codeOptimization.targets | 2 +- eng/nativepgo.targets | 2 +- eng/packaging.targets | 8 +++---- eng/resolveContract.targets | 4 ++-- src/coreclr/.nuget/coreclr-packages.proj | 8 +++---- src/coreclr/crossgen-corelib.proj | 2 +- .../SuperFileCheck/SuperFileCheck.csproj | 2 +- .../ILCompiler.Compiler.csproj | 4 ++-- .../ILCompiler.ReadyToRun.csproj | 4 ++-- .../ILCompiler.TypeSystem.csproj | 4 ++-- .../tools/aot/ILCompiler/ILCompiler.csproj | 2 +- .../tools/aot/ILCompiler/ILCompiler.props | 4 ++-- src/coreclr/tools/r2rdump/R2RDump.csproj | 2 +- .../pkg/projects/Directory.Build.props | 2 +- .../Directory.Build.props | 2 +- .../Microsoft.NETCore.App.Crossgen2.sfxproj | 4 ++-- .../Microsoft.NETCore.App.Runtime.sfxproj | 2 +- ...oft.Extensions.Logging.Abstractions.csproj | 2 +- .../src/Microsoft.NETCore.Platforms.csproj | 2 +- .../src/System.Net.Quic.csproj | 4 ++-- .../src/System.Text.Json.csproj | 2 +- src/libraries/oob-all.proj | 2 +- src/libraries/oob-src.proj | 2 +- src/libraries/oob.proj | 2 +- src/libraries/tests.proj | 4 ++-- src/mono/nuget/mono-packages.proj | 2 +- .../WorkloadBuildTasks.csproj | 2 +- src/tasks/tasks.proj | 2 +- src/tests/Common/Directory.Build.targets | 2 +- .../ILLink.CodeFixProvider.csproj | 4 ++-- .../ILLink.RoslynAnalyzer.csproj | 8 +++---- .../illink/src/linker/Mono.Linker.csproj | 6 ++--- 41 files changed, 85 insertions(+), 86 deletions(-) diff --git a/Build.proj b/Build.proj index baa240685ae5d..0957ae6846e57 100644 --- a/Build.proj +++ b/Build.proj @@ -8,7 +8,7 @@ - + diff --git a/Directory.Build.props b/Directory.Build.props index 0db4a1cc3d3d1..26e112fab56e1 100644 --- a/Directory.Build.props +++ b/Directory.Build.props @@ -5,12 +5,12 @@ false - true + leg only, so we also take DotNetBuildSourceOnly into account. --> + true - true + true @@ -94,7 +94,7 @@ net8.0 - $(NetCoreAppCurrent) + $(NetCoreAppCurrent) - - - + + + 8.0.0 @@ -176,7 +176,7 @@ $([MSBuild]::NormalizePath('$(MonoTargetsTasksDir)', 'MonoTargetsTasks.dll')) $([MSBuild]::NormalizePath('$(TestExclusionListTasksDir)', 'TestExclusionListTasks.dll')) $([MSBuild]::NormalizeDirectory('$(ArtifactsBinDir)', 'coreclr', '$(TargetOS).$(TargetArchitecture).$(RuntimeConfiguration)')) - $(CoreCLRToolPath) + $(CoreCLRToolPath) $(WASMTIME_PATH) $([MSBuild]::NormalizeDirectory($(ArtifactsObjDir), 'wasmtime')) true @@ -184,7 +184,7 @@ - false + false true @@ -298,8 +298,8 @@ - true - false + true + false true true @@ -380,7 +380,7 @@ portable true - true + true false Properties diff --git a/Directory.Build.targets b/Directory.Build.targets index 43564d362554b..f731eedc390c3 100644 --- a/Directory.Build.targets +++ b/Directory.Build.targets @@ -21,7 +21,7 @@ When .NET gets built from source, make the SDK aware there are bootstrap packages for Microsoft.NETCore.App.Runtime. and Microsoft.NETCore.App.Crossgen2.. --> - + %(RuntimePackRuntimeIdentifiers);$(PackageRID) @@ -88,7 +88,7 @@ - $(SystemReflectionMetadataLoadContextVersion) + $(SystemReflectionMetadataLoadContextVersion) - false + false $(RunAnalyzers) diff --git a/eng/DiaSymReaderNative.targets b/eng/DiaSymReaderNative.targets index caa482f4b6e80..ac8dc7e36a06d 100644 --- a/eng/DiaSymReaderNative.targets +++ b/eng/DiaSymReaderNative.targets @@ -18,7 +18,7 @@ package can't be referenced directly but rather has to have it's assets manually copied out. This logic is responsible for doing that. --> - + PreserveNewest false diff --git a/eng/DotNetBuild.props b/eng/DotNetBuild.props index fbad52bdac7d6..8527ec175ad88 100644 --- a/eng/DotNetBuild.props +++ b/eng/DotNetBuild.props @@ -38,9 +38,9 @@ - + $(InnerBuildArgs) $(FlagParameterPrefix)arch $(TargetArch) $(InnerBuildArgs) $(FlagParameterPrefix)os $(TargetOS) $(InnerBuildArgs) $(FlagParameterPrefix)cross @@ -63,8 +63,7 @@ $(InnerBuildArgs) $(FlagParameterPrefix)s clr.nativeaotlibs+clr.nativeaotruntime+libs+packs /p:BuildNativeAOTRuntimePack=true /p:SkipLibrariesNativeRuntimePackages=true - $(InnerBuildArgs) /p:ArcadeBuildFromSource=true - $(InnerBuildArgs) /p:ArcadeBuildVertical=true + $(InnerBuildArgs) /p:DotNetBuildRepo=true $(InnerBuildArgs) /p:OfficialBuildId=$(OfficialBuildId) $(InnerBuildArgs) /p:ContinuousIntegrationBuild=$(ContinuousIntegrationBuild) $(InnerBuildArgs) /p:PortableBuild=$(PortableBuild) diff --git a/eng/Subsets.props b/eng/Subsets.props index 9088b48f285de..cd4532699b10e 100644 --- a/eng/Subsets.props +++ b/eng/Subsets.props @@ -40,7 +40,7 @@ mono+libs+packs mono+libs+host+packs - clr+libs+tools+host+packs + clr+libs+tools+host+packs @@ -85,13 +85,13 @@ tools.illink host.native+host.tools+host.pkg - $(DefaultHostSubsets)+host.pretest+host.tests + $(DefaultHostSubsets)+host.pretest+host.tests host.native packs.product - $(DefaultPacksSubsets)+packs.tests - $(DefaultPacksSubsets)+packs.installers + $(DefaultPacksSubsets)+packs.tests + $(DefaultPacksSubsets)+packs.installers $(DefaultPacksSubsets)+mono.manifests @@ -341,7 +341,7 @@ $(CoreClrProjectRoot)tools\aot\ILCompiler\repro\repro.csproj; $(CoreClrProjectRoot)tools\r2rtest\R2RTest.csproj; $(CoreClrProjectRoot)tools\PdbChecker\PdbChecker.csproj; - $(CoreClrProjectRoot)tools\AssemblyChecker\AssemblyChecker.csproj" Category="clr" Condition="'$(DotNetBuildFromSource)' != 'true'"/> + $(CoreClrProjectRoot)tools\AssemblyChecker\AssemblyChecker.csproj" Category="clr" Condition="'$(DotNetBuildSourceOnly)' != 'true'"/> @@ -355,11 +355,11 @@ + Test="true" Category="clr" Condition="'$(DotNetBuildSourceOnly)' != 'true'"/> + Test="true" Category="clr" Condition="'$(DotNetBuildSourceOnly)' != 'true' and '$(NativeAotSupported)' == 'true'"/> + Test="true" Category="clr" Condition="'$(DotNetBuildSourceOnly)' != 'true' and '$(NativeAotSupported)' == 'true'"/> @@ -393,7 +393,7 @@ - + diff --git a/eng/Tools.props b/eng/Tools.props index 01cae1f2b2303..3baa40f4f32e0 100644 --- a/eng/Tools.props +++ b/eng/Tools.props @@ -11,7 +11,7 @@ - + diff --git a/eng/Versions.props b/eng/Versions.props index 29ede69058eb3..ea03f538ca3c8 100644 --- a/eng/Versions.props +++ b/eng/Versions.props @@ -26,8 +26,8 @@ true true - - true + + true diff --git a/eng/codeOptimization.targets b/eng/codeOptimization.targets index d42a39e3dfd2a..5f990a983476d 100644 --- a/eng/codeOptimization.targets +++ b/eng/codeOptimization.targets @@ -30,7 +30,7 @@ - true + true diff --git a/eng/nativepgo.targets b/eng/nativepgo.targets index 9f5984efdb633..99344e20b8e2b 100644 --- a/eng/nativepgo.targets +++ b/eng/nativepgo.targets @@ -9,7 +9,7 @@ <_NativeOptimizationDataPackageTarget Condition="'$(TargetOS)' == 'windows'">windows_nt-$(TargetArchitecture.ToLower()) - + diff --git a/eng/packaging.targets b/eng/packaging.targets index fde0ccb624b89..554e705e1887b 100644 --- a/eng/packaging.targets +++ b/eng/packaging.targets @@ -4,12 +4,12 @@ true + '$(DotNetBuildSourceOnly)' != 'true'">true true + '$(DotNetBuildSourceOnly)' == 'true'">true $(ApiCompatNetCoreAppBaselineVersion) $(BeforePack);IncludeAnalyzersInPackage;AddNETStandardCompatErrorFileForPackaging @@ -39,7 +39,7 @@ true + '$(DotNetBuildSourceOnly)' == 'true'">true false @@ -307,7 +307,7 @@ diff --git a/eng/resolveContract.targets b/eng/resolveContract.targets index bd6fc7de7fc5c..fb93fcd09e9a6 100644 --- a/eng/resolveContract.targets +++ b/eng/resolveContract.targets @@ -76,7 +76,7 @@ all the inputs available, some suppressions might only apply to one or the other and hence unnecessary suppressions can't be determined. Disable the validation under source build as that might use an out-of-date SDK and not the ApiCompat.Task package. --> - + true true @@ -137,7 +137,7 @@ Version="$(MicrosoftDotNetGenApiVersion)" PrivateAssets="all" IsImplicitlyDefined="true" - Condition="'$(DotNetBuildFromSource)' != 'true'" /> + Condition="'$(DotNetBuildSourceOnly)' != 'true'" /> diff --git a/src/coreclr/tools/aot/ILCompiler.ReadyToRun/ILCompiler.ReadyToRun.csproj b/src/coreclr/tools/aot/ILCompiler.ReadyToRun/ILCompiler.ReadyToRun.csproj index 9db169fb6dae0..f240269e0ad7f 100644 --- a/src/coreclr/tools/aot/ILCompiler.ReadyToRun/ILCompiler.ReadyToRun.csproj +++ b/src/coreclr/tools/aot/ILCompiler.ReadyToRun/ILCompiler.ReadyToRun.csproj @@ -16,7 +16,7 @@ false Debug;Release;Checked false - $(NoWarn);CS8524 + $(NoWarn);CS8524 @@ -24,7 +24,7 @@ - + all contentfiles diff --git a/src/coreclr/tools/aot/ILCompiler.TypeSystem/ILCompiler.TypeSystem.csproj b/src/coreclr/tools/aot/ILCompiler.TypeSystem/ILCompiler.TypeSystem.csproj index 268e2e6b1248d..663dadfd936f5 100644 --- a/src/coreclr/tools/aot/ILCompiler.TypeSystem/ILCompiler.TypeSystem.csproj +++ b/src/coreclr/tools/aot/ILCompiler.TypeSystem/ILCompiler.TypeSystem.csproj @@ -9,7 +9,7 @@ x64;x86 AnyCPU false - true + true $(DefineConstants);DISABLE_UNMANAGED_PDB_SYMBOLS - false + false false false diff --git a/src/coreclr/tools/aot/ILCompiler/ILCompiler.props b/src/coreclr/tools/aot/ILCompiler/ILCompiler.props index 6b419773911a8..70994509d4007 100644 --- a/src/coreclr/tools/aot/ILCompiler/ILCompiler.props +++ b/src/coreclr/tools/aot/ILCompiler/ILCompiler.props @@ -47,10 +47,10 @@ true - true + true - + diff --git a/src/coreclr/tools/r2rdump/R2RDump.csproj b/src/coreclr/tools/r2rdump/R2RDump.csproj index 103d8160d0b53..3f5a93c94fbeb 100644 --- a/src/coreclr/tools/r2rdump/R2RDump.csproj +++ b/src/coreclr/tools/r2rdump/R2RDump.csproj @@ -15,7 +15,7 @@ false - + diff --git a/src/installer/pkg/projects/Directory.Build.props b/src/installer/pkg/projects/Directory.Build.props index 2917964afb8aa..a07b360efc07a 100644 --- a/src/installer/pkg/projects/Directory.Build.props +++ b/src/installer/pkg/projects/Directory.Build.props @@ -35,7 +35,7 @@ true - false + false dotnet-crossgen2 crossgen2 - linux-x64;linux-musl-x64;linux-arm;linux-musl-arm;linux-arm64;linux-musl-arm64;freebsd-x64;freebsd-arm64;osx-x64;osx-arm64;win-x64;win-x86;win-arm64 + linux-x64;linux-musl-x64;linux-arm;linux-musl-arm;linux-arm64;linux-musl-arm64;freebsd-x64;freebsd-arm64;osx-x64;osx-arm64;win-x64;win-x86;win-arm64 false tools/ true @@ -21,7 +21,7 @@ false - false + false diff --git a/src/installer/pkg/sfx/Microsoft.NETCore.App/Microsoft.NETCore.App.Runtime.sfxproj b/src/installer/pkg/sfx/Microsoft.NETCore.App/Microsoft.NETCore.App.Runtime.sfxproj index 988b59bcecec6..1f6b55038026d 100644 --- a/src/installer/pkg/sfx/Microsoft.NETCore.App/Microsoft.NETCore.App.Runtime.sfxproj +++ b/src/installer/pkg/sfx/Microsoft.NETCore.App/Microsoft.NETCore.App.Runtime.sfxproj @@ -19,7 +19,7 @@ true - true + true diff --git a/src/libraries/Microsoft.Extensions.Logging.Abstractions/src/Microsoft.Extensions.Logging.Abstractions.csproj b/src/libraries/Microsoft.Extensions.Logging.Abstractions/src/Microsoft.Extensions.Logging.Abstractions.csproj index 085cade3966b9..28d8bcddd1851 100644 --- a/src/libraries/Microsoft.Extensions.Logging.Abstractions/src/Microsoft.Extensions.Logging.Abstractions.csproj +++ b/src/libraries/Microsoft.Extensions.Logging.Abstractions/src/Microsoft.Extensions.Logging.Abstractions.csproj @@ -44,7 +44,7 @@ Microsoft.Extensions.Logging.Abstractions.NullLogger + Condition="'$(DotNetBuildSourceOnly)' != 'true'" /> diff --git a/src/libraries/Microsoft.NETCore.Platforms/src/Microsoft.NETCore.Platforms.csproj b/src/libraries/Microsoft.NETCore.Platforms/src/Microsoft.NETCore.Platforms.csproj index 958cf0e65df49..24aa038645aec 100644 --- a/src/libraries/Microsoft.NETCore.Platforms/src/Microsoft.NETCore.Platforms.csproj +++ b/src/libraries/Microsoft.NETCore.Platforms/src/Microsoft.NETCore.Platforms.csproj @@ -23,7 +23,7 @@ - + diff --git a/src/libraries/System.Net.Quic/src/System.Net.Quic.csproj b/src/libraries/System.Net.Quic/src/System.Net.Quic.csproj index 4035186461801..16d83c57fe466 100644 --- a/src/libraries/System.Net.Quic/src/System.Net.Quic.csproj +++ b/src/libraries/System.Net.Quic/src/System.Net.Quic.csproj @@ -161,7 +161,7 @@ + '$(DotNetBuildSourceOnly)' != 'true'"> + '$(DotNetBuildSourceOnly)' != 'true'"> - + diff --git a/src/libraries/oob-all.proj b/src/libraries/oob-all.proj index 07b063fab4094..b8d20924522d7 100644 --- a/src/libraries/oob-all.proj +++ b/src/libraries/oob-all.proj @@ -29,7 +29,7 @@ + Condition="'$(DotNetBuildSourceOnly)' == 'true'" /> diff --git a/src/libraries/oob-src.proj b/src/libraries/oob-src.proj index bb571ebc35f19..48bc4897a2679 100644 --- a/src/libraries/oob-src.proj +++ b/src/libraries/oob-src.proj @@ -37,7 +37,7 @@ + Condition="'$(DotNetBuildSourceOnly)' == 'true'" /> diff --git a/src/libraries/oob.proj b/src/libraries/oob.proj index 34823cd1ba4fe..d49efa6e61681 100644 --- a/src/libraries/oob.proj +++ b/src/libraries/oob.proj @@ -13,7 +13,7 @@ + Condition="'$(DotNetBuildSourceOnly)' != 'true' and '$(ApiCompatValidateAssemblies)' != 'false'" /> diff --git a/src/libraries/tests.proj b/src/libraries/tests.proj index ec9b4a7706a62..42afa2ece4fba 100644 --- a/src/libraries/tests.proj +++ b/src/libraries/tests.proj @@ -99,8 +99,8 @@ - - + + diff --git a/src/mono/nuget/mono-packages.proj b/src/mono/nuget/mono-packages.proj index 025c6666db712..10add92c17efc 100644 --- a/src/mono/nuget/mono-packages.proj +++ b/src/mono/nuget/mono-packages.proj @@ -30,7 +30,7 @@ - + diff --git a/src/tasks/WorkloadBuildTasks/WorkloadBuildTasks.csproj b/src/tasks/WorkloadBuildTasks/WorkloadBuildTasks.csproj index 4e91a40280ca4..50249f07c44e0 100644 --- a/src/tasks/WorkloadBuildTasks/WorkloadBuildTasks.csproj +++ b/src/tasks/WorkloadBuildTasks/WorkloadBuildTasks.csproj @@ -2,7 +2,7 @@ $(NetCoreAppToolCurrent) - $(TargetFrameworks);net8.0 + $(TargetFrameworks);net8.0 enable $(NoWarn),CA1050,CA1850 diff --git a/src/tasks/tasks.proj b/src/tasks/tasks.proj index ab54991791ba7..504f3caad0947 100644 --- a/src/tasks/tasks.proj +++ b/src/tasks/tasks.proj @@ -6,7 +6,7 @@ + Condition="'$(DotNetBuildSourceOnly)' == 'true'" /> true diff --git a/src/tools/illink/src/ILLink.CodeFix/ILLink.CodeFixProvider.csproj b/src/tools/illink/src/ILLink.CodeFix/ILLink.CodeFixProvider.csproj index 3771de91b840d..5dd13cb777215 100644 --- a/src/tools/illink/src/ILLink.CodeFix/ILLink.CodeFixProvider.csproj +++ b/src/tools/illink/src/ILLink.CodeFix/ILLink.CodeFixProvider.csproj @@ -9,8 +9,8 @@ - - + + diff --git a/src/tools/illink/src/ILLink.RoslynAnalyzer/ILLink.RoslynAnalyzer.csproj b/src/tools/illink/src/ILLink.RoslynAnalyzer/ILLink.RoslynAnalyzer.csproj index 80fd6a902203c..7db05c1cde9af 100644 --- a/src/tools/illink/src/ILLink.RoslynAnalyzer/ILLink.RoslynAnalyzer.csproj +++ b/src/tools/illink/src/ILLink.RoslynAnalyzer/ILLink.RoslynAnalyzer.csproj @@ -7,7 +7,7 @@ false false Latest - $(NoWarn);CS8524 + $(NoWarn);CS8524 cs @@ -16,9 +16,9 @@ - - - + + + all contentfiles diff --git a/src/tools/illink/src/linker/Mono.Linker.csproj b/src/tools/illink/src/linker/Mono.Linker.csproj index e5cdbb86c5eb7..d1a4bdbf0570c 100644 --- a/src/tools/illink/src/linker/Mono.Linker.csproj +++ b/src/tools/illink/src/linker/Mono.Linker.csproj @@ -15,7 +15,7 @@ true false - $(NoWarn);CS8524 + $(NoWarn);CS8524 $(MSBuildThisFileDirectory)ref\Mono.Linker.csproj Major false @@ -76,7 +76,7 @@ - + all contentfiles @@ -84,7 +84,7 @@ - + runtime; build; native; contentfiles; analyzers; buildtransitive all