зеркало из https://github.com/dotnet/sdk.git
Update to Unified Build controls (#38506)
Co-authored-by: Viktor Hofer <viktor.hofer@microsoft.com>
This commit is contained in:
Родитель
1f5a946a99
Коммит
8155f00f05
|
@ -18,21 +18,21 @@
|
|||
may target a lower version of .NET -->
|
||||
<ResolverTargetFramework>net8.0</ResolverTargetFramework>
|
||||
<!-- Source build does not need to worry about running on VS for Mac -->
|
||||
<ResolverTargetFramework Condition="'$(DotNetBuildFromSource)' == 'true'">$(SdkTargetFramework)</ResolverTargetFramework>
|
||||
<ResolverTargetFramework Condition="'$(DotNetBuildSourceOnly)' == 'true'">$(SdkTargetFramework)</ResolverTargetFramework>
|
||||
|
||||
<!-- NU1701 Disable implicit package target fallback, and disable warning for when we explicitly add it (currently needed for
|
||||
Microsoft.ApplicationInsights) -->
|
||||
<!-- NU1507 Disable multi-feed check as .NET uses multiple internal feeds intentionally -->
|
||||
<NoWarn>$(NoWarn);NU1701;NU1507</NoWarn>
|
||||
<!-- do not enable analyzers on source build-->
|
||||
<EnforceCodeStyleInBuild Condition="'$(DotNetBuildFromSource)' != 'true'">true</EnforceCodeStyleInBuild>
|
||||
<EnforceCodeStyleInBuild Condition="'$(DotNetBuildSourceOnly)' != 'true'">true</EnforceCodeStyleInBuild>
|
||||
<DisableImplicitPackageTargetFallback>true</DisableImplicitPackageTargetFallback>
|
||||
|
||||
<!-- <ArtifactsShippingSymbolsDir>$(ArtifactsDir)symbols\$(Configuration)\Shipping</ArtifactsShippingSymbolsDir> -->
|
||||
|
||||
<DefineConstants Condition="'$(ContinuousIntegrationBuild)' == 'true'">$(DefineConstants);CI_BUILD</DefineConstants>
|
||||
<DefineConstants Condition="'$(OfficialBuilder)' == 'Microsoft'">$(DefineConstants);MICROSOFT_ENABLE_TELEMETRY</DefineConstants>
|
||||
<DefineConstants Condition="'$(DotNetBuildFromSource)' == 'true'">$(DefineConstants);DOT_NET_BUILD_FROM_SOURCE</DefineConstants>
|
||||
<DefineConstants Condition="'$(DotNetBuildSourceOnly)' == 'true'">$(DefineConstants);DOT_NET_BUILD_FROM_SOURCE</DefineConstants>
|
||||
|
||||
<ManagePackageVersionsCentrally>true</ManagePackageVersionsCentrally>
|
||||
<CentralPackageTransitivePinningEnabled>true</CentralPackageTransitivePinningEnabled>
|
||||
|
|
|
@ -10,14 +10,8 @@
|
|||
<PackageVersion Include="Microsoft.AspNetCore.Mvc.Razor.Extensions.Tooling.Internal" Version="$(MicrosoftAspNetCoreMvcRazorExtensionsToolingInternalPackageVersion)" />
|
||||
<PackageVersion Include="Microsoft.AspNetCore.TestHost" Version="$(MicrosoftAspNetCoreTestHostPackageVersion)" />
|
||||
<PackageVersion Include="Microsoft.Bcl.AsyncInterfaces" Version="$(MicrosoftNETCoreAppRefPackageVersion)"/>
|
||||
<PackageVersion Include="Microsoft.Build" Version="$(MicrosoftBuildPackageVersion)" />
|
||||
<PackageVersion Include="Microsoft.Build.Framework" Version="$(MicrosoftBuildFrameworkPackageVersion)" />
|
||||
<PackageVersion Include="Microsoft.Build.Localization" Version="$(MicrosoftBuildLocalizationPackageVersion)" />
|
||||
<PackageVersion Include="Microsoft.Build.Locator" Version="$(MicrosoftBuildLocatorPackageVersion)" />
|
||||
<PackageVersion Include="Microsoft.Build.NuGetSdkResolver" Version="$(MicrosoftBuildNuGetSdkResolverPackageVersion)" />
|
||||
<PackageVersion Include="Microsoft.Build.Runtime" Version="$(MicrosoftBuildRuntimePackageVersion)" />
|
||||
<PackageVersion Include="Microsoft.Build.Tasks.Core" Version="$(MicrosoftBuildPackageVersion)" />
|
||||
<PackageVersion Include="Microsoft.Build.Utilities.Core" Version="$(MicrosoftBuildUtilitiesCorePackageVersion)" />
|
||||
<PackageVersion Include="Microsoft.CodeAnalysis.CSharp" Version="$(MicrosoftCodeAnalysisCSharpPackageVersion)" />
|
||||
<PackageVersion Include="Microsoft.CodeAnalysis.CSharp.CodeStyle" Version="$(MicrosoftNetCompilersToolsetPackageVersion)" />
|
||||
<PackageVersion Include="Microsoft.CodeAnalysis.CSharp.Features" Version="$(MicrosoftCodeAnalysisCSharpFeaturesPackageVersion)" />
|
||||
|
@ -41,7 +35,6 @@
|
|||
<PackageVersion Include="Microsoft.FSharp.Compiler" Version="$(MicrosoftFSharpCompilerPackageVersion)" />
|
||||
<PackageVersion Include="Microsoft.NET.HostModel" Version="$(MicrosoftNETHostModelVersion)" />
|
||||
<PackageVersion Include="Microsoft.NET.Sdk.Razor.SourceGenerators.Transport" Version="$(MicrosoftNETSdkRazorSourceGeneratorsTransportPackageVersion)" />
|
||||
<PackageVersion Include="Microsoft.NET.StringTools" Version="$(MicrosoftNETStringToolsPackageVersion)" />
|
||||
<PackageVersion Include="Microsoft.NETCore.DotNetHostResolver" Version="$(MicrosoftNETCoreDotNetHostResolverPackageVersion)" />
|
||||
<PackageVersion Include="Microsoft.NETCore.Targets" Version="2.1.0" />
|
||||
<PackageVersion Include="Microsoft.TemplateEngine.Authoring.TemplateVerifier" Version="$(MicrosoftTemplateEngineAuthoringTemplateVerifierVersion)" />
|
||||
|
@ -109,4 +102,29 @@
|
|||
<PackageVersion Include="Xunit.Combinatorial" Version="$(XunitCombinatorialVersion)" />
|
||||
<PackageVersion Include="xunit.console" Version="$(XUnitVersion)"/>
|
||||
</ItemGroup>
|
||||
|
||||
<!-- Use different versions of Microsoft.Build.* depending on whether we are building in source-only
|
||||
modes or normal modes. In normal modes we use MicrosoftBuildMinimumVersion, otherwise
|
||||
we use MicrosoftBuildVersion. Note: This is not abstracted in Versions.props because source-only
|
||||
modes will import a version override file after Versions.props. -->
|
||||
<ItemGroup Condition="'$(DotNetBuildSourceOnly)' == 'true'">
|
||||
<PackageVersion Include="Microsoft.Build" Version="$(MicrosoftBuildVersion)" />
|
||||
<PackageVersion Include="Microsoft.Build.Framework" Version="$(MicrosoftBuildVersion)" />
|
||||
<!-- Localization is the same between source-only and regular modes. Always taken from latest. Duplicated between the itemgroups for clarity. -->
|
||||
<PackageVersion Include="Microsoft.Build.Localization" Version="$(MicrosoftBuildLocalizationVersion)" />
|
||||
<PackageVersion Include="Microsoft.Build.Runtime" Version="$(MicrosoftBuildVersion)" />
|
||||
<PackageVersion Include="Microsoft.Build.Tasks.Core" Version="$(MicrosoftBuildVersion)" />
|
||||
<PackageVersion Include="Microsoft.Build.Utilities.Core" Version="$(MicrosoftBuildVersion)" />
|
||||
<PackageVersion Include="Microsoft.NET.StringTools" Version="$(MicrosoftBuildVersion)" />
|
||||
</ItemGroup>
|
||||
<ItemGroup Condition="'$(DotNetBuildSourceOnly)' != 'true'">
|
||||
<PackageVersion Include="Microsoft.Build" Version="$(MicrosoftBuildMinimumVersion)" />
|
||||
<PackageVersion Include="Microsoft.Build.Framework" Version="$(MicrosoftBuildMinimumVersion)" />
|
||||
<!-- Localization is the same between source-only and regular modes. Always taken from latest. Duplicated between the itemgroups for clarity. -->
|
||||
<PackageVersion Include="Microsoft.Build.Localization" Version="$(MicrosoftBuildLocalizationVersion)" />
|
||||
<PackageVersion Include="Microsoft.Build.Runtime" Version="$(MicrosoftBuildMinimumVersion)" />
|
||||
<PackageVersion Include="Microsoft.Build.Tasks.Core" Version="$(MicrosoftBuildMinimumVersion)" />
|
||||
<PackageVersion Include="Microsoft.Build.Utilities.Core" Version="$(MicrosoftBuildMinimumVersion)" />
|
||||
<PackageVersion Include="Microsoft.NET.StringTools" Version="$(MicrosoftBuildMinimumVersion)" />
|
||||
</ItemGroup>
|
||||
</Project>
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
<Project>
|
||||
<ItemGroup Condition="'$(DotNetBuildFromSource)' != 'true'">
|
||||
<ItemGroup Condition="'$(DotNetBuildSourceOnly)' != 'true'">
|
||||
<PackageReference Include="StyleCop.Analyzers" PrivateAssets="all" Condition="'$(EnableStyleCopAnalyzer)' == 'true'" />
|
||||
</ItemGroup>
|
||||
</Project>
|
|
@ -3,7 +3,7 @@
|
|||
<!-- Override package versions in dependabot\Packages.props for source build -->
|
||||
<!-- Packages must be set to their package version property if it exists (ex. BenchmarkDotNetVersion) since source-build uses
|
||||
these properties to override package versions if necessary. -->
|
||||
<ItemGroup Condition="'$(DotNetBuildFromSource)' == 'true'">
|
||||
<ItemGroup Condition="'$(DotNetBuildSourceOnly)' == 'true'">
|
||||
<PackageVersion Update="Verify.XUnit" Condition="'$(VerifyXUnitVersion)' != ''" Version="$(VerifyXUnitVersion)" />
|
||||
<PackageVersion Update="Verify.DiffPlex" Condition="'$(VerifyDiffPlexVersion)' != ''" Version="$(VerifyDiffPlexVersion)" />
|
||||
<PackageVersion Update="FakeItEasy" Condition="'$(FakeItEasyVersion)' != ''" Version="$(FakeItEasyVersion)" />
|
||||
|
|
|
@ -103,20 +103,22 @@
|
|||
</PropertyGroup>
|
||||
<PropertyGroup>
|
||||
<!-- Dependencies from https://github.com/Microsoft/msbuild -->
|
||||
<MicrosoftBuildPackageVersion>17.10.0-preview-24106-02</MicrosoftBuildPackageVersion>
|
||||
<MicrosoftBuildCurrentPackageVersion>$(MicrosoftBuildPackageVersion)</MicrosoftBuildCurrentPackageVersion>
|
||||
<!-- Some tasks and the resolver will need to run in an MSBuild that is older than the very latest,
|
||||
so target one that matches the version in minimumMSBuildVersion.
|
||||
|
||||
This avoids the need to juggle references to packages that have been updated in newer MSBuild. -->
|
||||
<MicrosoftBuildPackageVersion Condition="exists('$(RepoRoot)\src\Layout\redist\minimumMSBuildVersion') and '$(DotNetBuildFromSource)' != 'true'">$([System.IO.File]::ReadAllText('$(RepoRoot)\src\Layout\redist\minimumMSBuildVersion').Trim())</MicrosoftBuildPackageVersion>
|
||||
<MicrosoftBuildFrameworkPackageVersion>$(MicrosoftBuildPackageVersion)</MicrosoftBuildFrameworkPackageVersion>
|
||||
<MicrosoftBuildRuntimePackageVersion>$(MicrosoftBuildPackageVersion)</MicrosoftBuildRuntimePackageVersion>
|
||||
<MicrosoftBuildLocalizationPackageVersion>17.10.0-preview-24106-02</MicrosoftBuildLocalizationPackageVersion>
|
||||
<MicrosoftBuildUtilitiesCorePackageVersion>$(MicrosoftBuildPackageVersion)</MicrosoftBuildUtilitiesCorePackageVersion>
|
||||
<MicrosoftBuildTasksCorePackageVersion>$(MicrosoftBuildPackageVersion)</MicrosoftBuildTasksCorePackageVersion>
|
||||
<MicrosoftBuildTasksCoreVersion>$(MicrosoftBuildTasksCorePackageVersion)</MicrosoftBuildTasksCoreVersion>
|
||||
<MicrosoftNETStringToolsPackageVersion>$(MicrosoftBuildPackageVersion)</MicrosoftNETStringToolsPackageVersion>
|
||||
<!-- In VMR modes, MicrosoftBuildVersion and MicrosoftBuildLocalizationVersion will end
|
||||
up overwritten by properties flowing the newest version that are imported after this file.
|
||||
These should be used in places where we always want to target the latest. This includes source-only modes (always use the latest)
|
||||
as well as some additional cases like the msbuild that is redistributed in the SDK.
|
||||
|
||||
In non-source-only modes, some tasks and the resolver will need to run in an MSBuild that is older
|
||||
than the very latest, based on what we want the SDK to support. So use a version that matches the version
|
||||
in minimumMSBuildVersion. In these cases, we don't want to use MicrosoftBuildVersion and other
|
||||
associated properties that are updated by the VMR infrastructure. So, we read this version
|
||||
from the 'minimumMSBuildVersion' file in non-source-only cases into MicrosoftBuildMinimumVersion,
|
||||
then use that in Directory.Packages.props.
|
||||
|
||||
At usage sites, either we use MicrosoftBuildMinimumVersion, or MicrosoftBuildVersion in source-only modes. -->
|
||||
<MicrosoftBuildVersion>17.10.0-preview-24106-02</MicrosoftBuildVersion>
|
||||
<MicrosoftBuildLocalizationVersion>17.10.0-preview-24106-02</MicrosoftBuildLocalizationVersion>
|
||||
<MicrosoftBuildMinimumVersion Condition="Exists('$(RepoRoot)src\Layout\redist\minimumMSBuildVersion') and '$(DotNetBuildSourceOnly)' != 'true'">$([System.IO.File]::ReadAllText('$(RepoRoot)src\Layout\redist\minimumMSBuildVersion').Trim())</MicrosoftBuildMinimumVersion>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup>
|
||||
<!-- Dependencies from https://github.com/dotnet/templating -->
|
||||
|
|
|
@ -10,7 +10,7 @@ function InitializeCustomSDKToolset {
|
|||
|
||||
# The following frameworks and tools are used only for testing.
|
||||
# Do not attempt to install them in source build.
|
||||
if ($env:DotNetBuildFromSource -eq "true") {
|
||||
if ($env:DotNetBuildFromSource -eq "true" -or $productBuild -or $properties -like "*DotNetBuildRepo=true*") {
|
||||
return
|
||||
}
|
||||
|
||||
|
|
|
@ -7,7 +7,7 @@ function InitializeCustomSDKToolset {
|
|||
|
||||
# The following frameworks and tools are used only for testing.
|
||||
# Do not attempt to install them in source build.
|
||||
if [[ $properties == *"ArcadeBuildFromSource=true"* ]]; then
|
||||
if [[ $properties == *"ArcadeBuildFromSource=true"* || $product_build == true || $properties == *"DotNetBuildRepo=true"* ]]; then
|
||||
return
|
||||
fi
|
||||
|
||||
|
|
|
@ -14,7 +14,7 @@
|
|||
<EmbeddedResource Include="BlazorHotReload.js" />
|
||||
</ItemGroup>
|
||||
|
||||
<ItemGroup Condition="'$(DotNetBuildFromSource)' == 'true'">
|
||||
<ItemGroup Condition="'$(DotNetBuildSourceOnly)' == 'true'">
|
||||
<!-- Reference 6.0.2 targeting packs in Source Build - this was the earliest version after the API surface stabilized -->
|
||||
<FrameworkReference
|
||||
Update="Microsoft.AspNetCore.App"
|
||||
|
|
|
@ -7,7 +7,6 @@
|
|||
|
||||
<PropertyGroup>
|
||||
<TargetFrameworks>$(ResolverTargetFramework);net472</TargetFrameworks>
|
||||
<TargetFrameworks Condition=" '$(DotNetBuildFromSource)' == 'true' ">$(ResolverTargetFramework)</TargetFrameworks>
|
||||
<TreatWarningsAsErrors>true</TreatWarningsAsErrors>
|
||||
<StrongNameKeyId>MicrosoftAspNetCore</StrongNameKeyId>
|
||||
<SignAssembly>true</SignAssembly>
|
||||
|
@ -26,7 +25,7 @@
|
|||
the latest version, which targets NetCurrent. -->
|
||||
<PropertyGroup>
|
||||
<MSBuildPathInPackage>$(PkgMicrosoft_Build_Runtime)\contentFiles\any\net8.0\MSBuild.dll</MSBuildPathInPackage>
|
||||
<MSBuildPathInPackage Condition="'$(DotNetBuildFromSource)' == 'true' and !Exists($(MSBuildPathInPackage))">$(PkgMicrosoft_Build_Runtime)\contentFiles\any\$(NetCurrent)\MSBuild.dll</MSBuildPathInPackage>
|
||||
<MSBuildPathInPackage Condition="'$(DotNetBuildSourceOnly)' == 'true' and !Exists($(MSBuildPathInPackage))">$(PkgMicrosoft_Build_Runtime)\contentFiles\any\$(NetCurrent)\MSBuild.dll</MSBuildPathInPackage>
|
||||
</PropertyGroup>
|
||||
<Error Condition="!Exists('$(MSBuildPathInPackage)')" Text="Something moved around in Microsoft.Build.Runtime, adjust code here accordingly." />
|
||||
<ItemGroup>
|
||||
|
|
|
@ -22,8 +22,8 @@
|
|||
<Compile Include="$(RepoRoot)src\Common\EnvironmentVariableNames.cs" LinkBase="Common" />
|
||||
<Compile Include="$(RepoRoot)src\Common\MSBuildPropertyNames.cs" LinkBase="Common" />
|
||||
<Compile Include="$(RepoRoot)src\Common\WorkloadFileBasedInstall.cs" LinkBase="Common" />
|
||||
<Compile Remove="commands\dotnet-workload\list\VisualStudioWorkloads.cs" Condition="'$(DotNetBuildFromSource)' == 'true'" />
|
||||
<Compile Remove="$(RepoRoot)\src\Cli\dotnet\Installer\Windows\Security\*.cs" Condition="'$(DotNetBuildFromSource)' == 'true'" />
|
||||
<Compile Remove="commands\dotnet-workload\list\VisualStudioWorkloads.cs" Condition="'$(DotNetBuildSourceOnly)' == 'true'" />
|
||||
<Compile Remove="$(RepoRoot)\src\Cli\dotnet\Installer\Windows\Security\*.cs" Condition="'$(DotNetBuildSourceOnly)' == 'true'" />
|
||||
<EmbeddedResource Include="commands\dotnet-new\*.zip" />
|
||||
<EmbeddedResource Update="**\*.resx" GenerateSource="true" />
|
||||
<EmbeddedResource Update="*.resx" Namespace="Microsoft.DotNet.Tools" />
|
||||
|
@ -100,8 +100,8 @@
|
|||
<PackageReference Include="System.CommandLine" />
|
||||
<PackageReference Include="Microsoft.Deployment.DotNet.Releases" />
|
||||
<PackageReference Include="System.ServiceProcess.ServiceController" />
|
||||
<PackageReference Include="Microsoft.VisualStudio.Setup.Configuration.Interop" PrivateAssets="All" ExcludeAssets="Runtime" Condition="'$(DotNetBuildFromSource)' != 'true'" />
|
||||
<PackageReference Include="Microsoft.Windows.CsWin32" IncludeAssets="all" Condition="'$(DotNetBuildFromSource)' != 'true'" />
|
||||
<PackageReference Include="Microsoft.VisualStudio.Setup.Configuration.Interop" PrivateAssets="All" ExcludeAssets="Runtime" Condition="'$(DotNetBuildSourceOnly)' != 'true'" />
|
||||
<PackageReference Include="Microsoft.Windows.CsWin32" IncludeAssets="all" Condition="'$(DotNetBuildSourceOnly)' != 'true'" />
|
||||
</ItemGroup>
|
||||
<ItemGroup Condition=" '$(IncludeAspNetCoreRuntime)' != 'false' ">
|
||||
<PackageReference Include="Microsoft.AspNetCore.DeveloperCertificates.XPlat" />
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
|
||||
<Import Project="..\..\Directory.Packages.props" />
|
||||
|
||||
<ItemGroup Condition="'$(DotNetBuildFromSource)' != 'true' and '$(SkipMicrosoftCodeAnalysisCSharpPinning)' != 'true'">
|
||||
<ItemGroup Condition="'$(DotNetBuildSourceOnly)' != 'true' and '$(SkipMicrosoftCodeAnalysisCSharpPinning)' != 'true'">
|
||||
<!-- We pin the code analysis version when not in source build as we need to support running on older
|
||||
SDKs when the OOB package is used. -->
|
||||
<PackageVersion Update="Microsoft.CodeAnalysis.CSharp" Version="4.4.0" />
|
||||
|
|
|
@ -2,7 +2,6 @@
|
|||
|
||||
<PropertyGroup>
|
||||
<TargetFrameworks>$(SdkTargetFramework);net472</TargetFrameworks>
|
||||
<TargetFrameworks Condition=" '$(DotNetBuildFromSource)' == 'true' ">$(SdkTargetFramework)</TargetFrameworks>
|
||||
<ImplicitUsings Condition="'$(TargetFramework)' != 'net472'">enable</ImplicitUsings>
|
||||
|
||||
<TargetsForTfmSpecificBuildOutput>
|
||||
|
@ -29,7 +28,7 @@
|
|||
|
||||
<ItemGroup>
|
||||
<PackageReference Include="Microsoft.Build.Utilities.Core" PrivateAssets="all" ExcludeAssets="runtime" />
|
||||
<PackageReference Include="Microsoft.CodeAnalysis.PublicApiAnalyzers" Condition=" '$(DotNetBuildFromSource)' != 'true' ">
|
||||
<PackageReference Include="Microsoft.CodeAnalysis.PublicApiAnalyzers" Condition=" '$(DotNetBuildSourceOnly)' != 'true' ">
|
||||
<PrivateAssets>all</PrivateAssets>
|
||||
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
|
||||
</PackageReference>
|
||||
|
|
|
@ -34,9 +34,9 @@
|
|||
|
||||
<ProjectReference Include="../Microsoft.NET.Build.Containers/Microsoft.NET.Build.Containers.csproj"
|
||||
SetTargetFramework="TargetFramework=$(VSCompatTargetFramework)"
|
||||
OutputItemType="ContainerLibraryOutputNet472" Condition="'$(DotNetBuildFromSource)' != 'true'" />
|
||||
OutputItemType="ContainerLibraryOutputNet472" Condition="'$(DotNetBuildSourceOnly)' != 'true'" />
|
||||
|
||||
<ProjectReference Include="../containerize/containerize.csproj" PrivateAssets="all" IncludeAssets="runtime" ReferenceOutputAssembly="true" Condition="'$(DotNetBuildFromSource)' != 'true'" />
|
||||
<ProjectReference Include="../containerize/containerize.csproj" PrivateAssets="all" IncludeAssets="runtime" ReferenceOutputAssembly="true" Condition="'$(DotNetBuildSourceOnly)' != 'true'" />
|
||||
</ItemGroup>
|
||||
|
||||
<Target Name="PreparePackageReleaseNotesFromFile" BeforeTargets="GenerateNuspec">
|
||||
|
@ -47,10 +47,10 @@
|
|||
</Target>
|
||||
|
||||
<Target Name="AddItemsForPackaging" AfterTargets="Build">
|
||||
<MSBuild Projects="../Microsoft.NET.Build.Containers/Microsoft.NET.Build.Containers.csproj" Properties="TargetFramework=$(VSCompatTargetFramework)" Targets="ResolveAssemblyReferences" Condition="'$(DotNetBuildFromSource)' != 'true'">
|
||||
<MSBuild Projects="../Microsoft.NET.Build.Containers/Microsoft.NET.Build.Containers.csproj" Properties="TargetFramework=$(VSCompatTargetFramework)" Targets="ResolveAssemblyReferences" Condition="'$(DotNetBuildSourceOnly)' != 'true'">
|
||||
<Output TaskParameter="TargetOutputs" ItemName="_AllNet472ContainerTaskDependencies" />
|
||||
</MSBuild>
|
||||
<ItemGroup Condition="'$(DotNetBuildFromSource)' != 'true'">
|
||||
<ItemGroup Condition="'$(DotNetBuildSourceOnly)' != 'true'">
|
||||
<NecessaryNet472ContainerTaskDependencies Include="@(_AllNet472ContainerTaskDependencies)" Condition="(
|
||||
$([MSBuild]::ValueOrDefault('%(_AllNet472ContainerTaskDependencies.NuGetPackageId)', '').Contains('NuGet')) or
|
||||
$([MSBuild]::ValueOrDefault('%(_AllNet472ContainerTaskDependencies.NuGetPackageId)', '').Contains('Newtonsoft')) or
|
||||
|
|
|
@ -22,7 +22,7 @@
|
|||
<Import Project="targets\PublishDotnetWatch.targets" />
|
||||
<Import Project="targets\GenerateLayout.targets" />
|
||||
<Import Project="targets\GenerateArchive.targets" />
|
||||
<Import Project="targets\OverlaySdkOnLKG.targets" Condition="'$(DotNetBuildFromSource)' != 'true'" />
|
||||
<Import Project="targets\OverlaySdkOnLKG.targets" Condition="'$(DotNetBuildSourceOnly)' != 'true'" />
|
||||
<Import Project="targets\MSBuildExtensions.targets" />
|
||||
|
||||
<ItemGroup>
|
||||
|
@ -33,7 +33,7 @@
|
|||
<PackageReference Include="Microsoft.Build.NuGetSdkResolver" />
|
||||
<PackageReference Include="Microsoft.TestPlatform.CLI" ExcludeAssets="All" />
|
||||
<PackageReference Include="Microsoft.TestPlatform.Build" />
|
||||
<PackageReference Condition=" '$(DotNetBuildFromSource)' != 'true' " Include="NuGet.Localization" />
|
||||
<PackageReference Condition=" '$(DotNetBuildSourceOnly)' != 'true' " Include="NuGet.Localization" />
|
||||
<PackageReference Include="NuGet.ProjectModel" />
|
||||
<PackageReference Include="Microsoft.CodeAnalysis.NetAnalyzers" ExcludeAssets="All" GeneratePathProperty="true"/>
|
||||
<PackageReference Include="Microsoft.CodeAnalysis.CSharp.CodeStyle" ExcludeAssets="All" GeneratePathProperty="true"/>
|
||||
|
@ -46,12 +46,13 @@
|
|||
<PackageReference Include="System.Text.Encoding.CodePages" />
|
||||
<PackageReference Include="System.Security.Cryptography.ProtectedData" />
|
||||
<PackageReference Include="System.Resources.Extensions" />
|
||||
<PackageReference Include="Microsoft.Build.Runtime" VersionOverride="$(MicrosoftBuildCurrentPackageVersion)" />
|
||||
<PackageReference Include="Microsoft.Build" VersionOverride="$(MicrosoftBuildCurrentPackageVersion)" />
|
||||
<PackageReference Include="Microsoft.Build.Tasks.Core" VersionOverride="$(MicrosoftBuildCurrentPackageVersion)" />
|
||||
<PackageReference Include="Microsoft.Build.Framework" VersionOverride="$(MicrosoftBuildCurrentPackageVersion)" />
|
||||
<PackageReference Include="Microsoft.Build.Utilities.Core" VersionOverride="$(MicrosoftBuildCurrentPackageVersion)" />
|
||||
<PackageReference Include="Microsoft.NET.StringTools" VersionOverride="$(MicrosoftBuildCurrentPackageVersion)" />
|
||||
<!-- Override to use the newest version. In source-only modes this will be a no-diff change. -->
|
||||
<PackageReference Include="Microsoft.Build.Runtime" VersionOverride="$(MicrosoftBuildVersion)" />
|
||||
<PackageReference Include="Microsoft.Build" VersionOverride="$(MicrosoftBuildVersion)" />
|
||||
<PackageReference Include="Microsoft.Build.Tasks.Core" VersionOverride="$(MicrosoftBuildVersion)" />
|
||||
<PackageReference Include="Microsoft.Build.Framework" VersionOverride="$(MicrosoftBuildVersion)" />
|
||||
<PackageReference Include="Microsoft.Build.Utilities.Core" VersionOverride="$(MicrosoftBuildVersion)" />
|
||||
<PackageReference Include="Microsoft.NET.StringTools" VersionOverride="$(MicrosoftBuildVersion)" />
|
||||
</ItemGroup>
|
||||
|
||||
<ItemGroup>
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
<Project ToolsVersion="15.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<ItemGroup>
|
||||
<BundledSdk Include="NuGet.Build.Tasks.Pack" Version="$(NuGetBuildTasksPackPackageVersion)" />
|
||||
<BundledSdk Include="Microsoft.NET.Sdk.WindowsDesktop" Version="$(MicrosoftNETSdkWindowsDesktopPackageVersion)" Condition="'$(DotNetBuildFromSource)' != 'true'" />
|
||||
<BundledSdk Include="Microsoft.NET.Sdk.WindowsDesktop" Version="$(MicrosoftNETSdkWindowsDesktopPackageVersion)" Condition="'$(DotNetBuildSourceOnly)' != 'true'" />
|
||||
<BundledSdk Include="FSharp.NET.Sdk" Version="1.0.4-bundled-0100" />
|
||||
<BundledSdk Include="Microsoft.Docker.Sdk" Version="1.1.0" />
|
||||
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
<Target Name="PublishPortableRuntimeIdentifierGraph"
|
||||
BeforeTargets="Build">
|
||||
|
||||
<ItemGroup Condition="'$(DotNetBuildFromSource)' == 'true' AND '$(TargetRid)' != '' AND '$(PortableRid)' != '' AND '$(TargetRid)' != '$(PortableRid)'">
|
||||
<ItemGroup Condition="'$(DotNetBuildSourceOnly)' == 'true' AND '$(TargetRid)' != '' AND '$(PortableRid)' != '' AND '$(TargetRid)' != '$(PortableRid)'">
|
||||
<AdditionalRuntimeIdentifier Include="$(TargetRid)" Imports="$(PortableRid)" />
|
||||
</ItemGroup>
|
||||
|
||||
|
@ -177,8 +177,8 @@
|
|||
<Target Name="PublishTestCli"
|
||||
BeforeTargets="Build">
|
||||
<PropertyGroup>
|
||||
<TestCliNuGetDirectoryTargetFramework Condition="'$(DotNetBuildFromSource)' != 'true'" >netcoreapp3.1</TestCliNuGetDirectoryTargetFramework>
|
||||
<TestCliNuGetDirectoryTargetFramework Condition="'$(DotNetBuildFromSource)' == 'true'" >net9.0</TestCliNuGetDirectoryTargetFramework>
|
||||
<TestCliNuGetDirectoryTargetFramework Condition="'$(DotNetBuildSourceOnly)' != 'true'" >netcoreapp3.1</TestCliNuGetDirectoryTargetFramework>
|
||||
<TestCliNuGetDirectoryTargetFramework Condition="'$(DotNetBuildSourceOnly)' == 'true'" >net9.0</TestCliNuGetDirectoryTargetFramework>
|
||||
<TestCliNuGetDirectory>$(NuGetPackageRoot)/microsoft.testplatform.cli/$(MicrosoftTestPlatformCLIPackageVersion)/contentFiles/any/$(TestCliNuGetDirectoryTargetFramework)/</TestCliNuGetDirectory>
|
||||
</PropertyGroup>
|
||||
<ItemGroup>
|
||||
|
@ -217,7 +217,7 @@
|
|||
Targets="Publish"
|
||||
Projects="$(RepoRoot)/src/Containers/Microsoft.NET.Build.Containers/Microsoft.NET.Build.Containers.csproj"
|
||||
Properties="Configuration=$(Configuration);PublishDir=$(OutputPath)/Containers/tasks/net472;TargetFramework=net472"
|
||||
Condition="'$(DotNetBuildFromSource)' != 'true'" />
|
||||
Condition="'$(DotNetBuildSourceOnly)' != 'true'" />
|
||||
<MSBuild
|
||||
Targets="Publish"
|
||||
Projects="$(RepoRoot)/src/Containers/Microsoft.NET.Build.Containers/Microsoft.NET.Build.Containers.csproj"
|
||||
|
@ -226,7 +226,7 @@
|
|||
Targets="Publish"
|
||||
Projects="$(RepoRoot)/src/Containers/containerize/containerize.csproj"
|
||||
Properties="Configuration=$(Configuration);PublishDir=$(OutputPath)/Containers/containerize"
|
||||
Condition="'$(DotNetBuildFromSource)' != 'true'" />
|
||||
Condition="'$(DotNetBuildSourceOnly)' != 'true'" />
|
||||
</Target>
|
||||
|
||||
<Target Name="GenerateCliRuntimeConfigurationFiles"
|
||||
|
|
|
@ -17,10 +17,14 @@
|
|||
<PropertyGroup>
|
||||
<FSharpCorePath Condition="'$(DotNetFinalVersionKind)'!='release'">Shipping</FSharpCorePath>
|
||||
<FSharpCorePath Condition="'$(DotNetFinalVersionKind)'=='release'">Release</FSharpCorePath>
|
||||
<FSharpTfm>net8.0</FSharpTfm>
|
||||
<!-- In full product source-only mode, fsharp currently builds net9.0. In repo source-only modes, non VMR builds, or MSFT VMR builds,
|
||||
it's net8.0. -->
|
||||
<FSharpTfm Condition="'$(DotNetBuildSourceOnly)' == 'true' and '$(DotNetOrchestrator)' == 'true'">net9.0</FSharpTfm>
|
||||
</PropertyGroup>
|
||||
<ItemGroup>
|
||||
<ResolvedFileToPublish
|
||||
Include="$(PkgMicrosoft_FSharp_Compiler)/lib/net8.0/FSharp.Core.xml"
|
||||
Include="$(PkgMicrosoft_FSharp_Compiler)/lib/$(FSharpTfm)/FSharp.Core.xml"
|
||||
CopyToPublishDirectory="PreserveNewest"
|
||||
DestinationSubPath="FSharp.Core.xml"
|
||||
RelativePath="FSharp.Core.xml"
|
||||
|
|
|
@ -7,13 +7,13 @@
|
|||
</PropertyGroup>
|
||||
|
||||
<ItemGroup>
|
||||
<PackageReference Include="Microsoft.Build.Runtime" VersionOverride="$(MicrosoftBuildCurrentPackageVersion)" />
|
||||
<PackageReference Include="Microsoft.Build.Framework" VersionOverride="$(MicrosoftBuildCurrentPackageVersion)" />
|
||||
<PackageReference Include="Microsoft.Build" VersionOverride="$(MicrosoftBuildCurrentPackageVersion)" />
|
||||
<PackageReference Include="Microsoft.Build.Tasks.Core" VersionOverride="$(MicrosoftBuildCurrentPackageVersion)" />
|
||||
<PackageReference Include="Microsoft.Build.Utilities.Core" VersionOverride="$(MicrosoftBuildCurrentPackageVersion)" />
|
||||
<PackageReference Include="Microsoft.Build.Runtime" VersionOverride="$(MicrosoftBuildVersion)" />
|
||||
<PackageReference Include="Microsoft.Build.Framework" VersionOverride="$(MicrosoftBuildVersion)" />
|
||||
<PackageReference Include="Microsoft.Build" VersionOverride="$(MicrosoftBuildVersion)" />
|
||||
<PackageReference Include="Microsoft.Build.Tasks.Core" VersionOverride="$(MicrosoftBuildVersion)" />
|
||||
<PackageReference Include="Microsoft.Build.Utilities.Core" VersionOverride="$(MicrosoftBuildVersion)" />
|
||||
<PackageReference Include="Microsoft.Build.Localization" />
|
||||
<PackageReference Include="Microsoft.NET.StringTools" VersionOverride="$(MicrosoftBuildCurrentPackageVersion)" />
|
||||
<PackageReference Include="Microsoft.NET.StringTools" VersionOverride="$(MicrosoftBuildVersion)" />
|
||||
<PackageReference Include="System.Resources.Extensions" />
|
||||
</ItemGroup>
|
||||
</Project>
|
||||
|
|
|
@ -64,7 +64,7 @@
|
|||
</ItemGroup>
|
||||
|
||||
<!-- Packages that are in-box for .NET Core, so we only need to reference them for .NET Framework -->
|
||||
<ItemGroup Condition="'$(TargetFrameworkIdentifier)' == '.NETFramework' and '$(DotNetBuildFromSource)' != 'true'">
|
||||
<ItemGroup Condition="'$(TargetFrameworkIdentifier)' == '.NETFramework'">
|
||||
<!--
|
||||
Microsoft.NET.HostModel also uses System.Reflection.Metadata. Don't move ahead of the version of System.Reflection.Metadata
|
||||
that MSBuild supports with the binding redirect to ensure that both this project and Microsoft.NET.HostModel can load
|
||||
|
|
|
@ -11,7 +11,6 @@
|
|||
|
||||
<PropertyGroup>
|
||||
<TargetFrameworks>$(SdkTargetFramework);net472</TargetFrameworks>
|
||||
<TargetFrameworks Condition=" '$(DotNetBuildFromSource)' == 'true' ">$(SdkTargetFramework)</TargetFrameworks>
|
||||
<PlatformTarget>AnyCPU</PlatformTarget>
|
||||
</PropertyGroup>
|
||||
|
||||
|
|
|
@ -5,7 +5,7 @@
|
|||
<MSBuildAllProjects>$(MSBuildAllProjects);$(MSBuildThisFileFullPath)</MSBuildAllProjects>
|
||||
</PropertyGroup>
|
||||
|
||||
<PropertyGroup Condition="'$(IsTestProject)' == 'true' AND '$(OutputType)' == 'Exe' AND '$(DotNetBuildFromSource)' != 'true'">
|
||||
<PropertyGroup Condition="'$(IsTestProject)' == 'true' AND '$(OutputType)' == 'Exe' AND '$(DotNetBuildSourceOnly)' != 'true'">
|
||||
<IsPackable>true</IsPackable>
|
||||
<PackAsTool>true</PackAsTool>
|
||||
<ToolCommandName>$(PackageId)</ToolCommandName>
|
||||
|
|
Загрузка…
Ссылка в новой задаче