source-build patches needed to get 6.0.2xx building (#12718)
* source-build patches needed to get 6.0.2xx building * Patch to address msbuild prebuilts * Remove conflicting backported patch * Additional patches * Additional vstest patch * Workaround dev-cert issue in smoke-tests
This commit is contained in:
parent
a2bb0dde82
commit
2ee0e6d76e
4 changed files with 236 additions and 2 deletions
|
@ -6,7 +6,7 @@ TARBALL_PREFIX=dotnet-sdk-
|
|||
VERSION_PREFIX=6.0
|
||||
# See https://github.com/dotnet/source-build/issues/579, this version
|
||||
# needs to be compatible with the runtime produced from source-build
|
||||
DEV_CERTS_VERSION_DEFAULT=6.0.0-preview.6.21355.2
|
||||
DEV_CERTS_VERSION_DEFAULT=6.0.0-rtm.21573.1
|
||||
__ROOT_REPO=$(sed 's/\r$//' "$SCRIPT_ROOT/artifacts/obj/rootrepo.txt") # remove CR if mounted repo on Windows drive
|
||||
executingUserHome=${HOME:-}
|
||||
|
||||
|
@ -49,7 +49,8 @@ configuration="Release"
|
|||
excludeNonWebTests=false
|
||||
excludeWebTests=false
|
||||
excludeWebNoHttpsTests=false
|
||||
excludeWebHttpsTests=false
|
||||
# Re-enable once https://github.com/dotnet/sdk/issues/22734 is fixed.
|
||||
excludeWebHttpsTests=true
|
||||
excludeLocalTests=false
|
||||
excludeOnlineTests=false
|
||||
devCertsVersion="$DEV_CERTS_VERSION_DEFAULT"
|
||||
|
|
|
@ -0,0 +1,164 @@
|
|||
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
||||
From: Michael Simons <msimons@microsoft.com>
|
||||
Date: Fri, 19 Nov 2021 13:50:52 -0600
|
||||
Subject: [PATCH] Update system-command-line version
|
||||
|
||||
Backported with https://github.com/dotnet/format/pull/1436
|
||||
---
|
||||
eng/Version.Details.xml | 8 ++++----
|
||||
eng/Versions.props | 4 ++--
|
||||
src/Commands/FormatAnalyzersCommand.cs | 4 ++--
|
||||
src/Commands/FormatCommandCommon.cs | 12 ++++++------
|
||||
src/Commands/FormatStyleCommand.cs | 4 ++--
|
||||
src/Commands/RootFormatCommand.cs | 4 ++--
|
||||
6 files changed, 18 insertions(+), 18 deletions(-)
|
||||
|
||||
diff --git a/eng/Version.Details.xml b/eng/Version.Details.xml
|
||||
index 48b181b..68c0b43 100644
|
||||
--- a/eng/Version.Details.xml
|
||||
+++ b/eng/Version.Details.xml
|
||||
@@ -5,13 +5,13 @@
|
||||
<Uri>https://github.com/dotnet/roslyn</Uri>
|
||||
<Sha>95b7a0198f8c805b367f17e4639020ec21c16705</Sha>
|
||||
</Dependency>
|
||||
- <Dependency Name="System.CommandLine" Version="2.0.0-beta1.21473.1">
|
||||
+ <Dependency Name="System.CommandLine" Version="2.0.0-beta1.21525.1">
|
||||
<Uri>https://github.com/dotnet/command-line-api</Uri>
|
||||
- <Sha>82273cb56c83b589e8e5b63da0ac9745ffc6e105</Sha>
|
||||
+ <Sha>09a24a79ef01a0c70655919ee3c59bb54a8574df</Sha>
|
||||
</Dependency>
|
||||
- <Dependency Name="System.CommandLine.Rendering" Version="0.3.0-alpha.21473.1">
|
||||
+ <Dependency Name="System.CommandLine.Rendering" Version="0.3.0-alpha.21525.1">
|
||||
<Uri>https://github.com/dotnet/command-line-api</Uri>
|
||||
- <Sha>82273cb56c83b589e8e5b63da0ac9745ffc6e105</Sha>
|
||||
+ <Sha>09a24a79ef01a0c70655919ee3c59bb54a8574df</Sha>
|
||||
</Dependency>
|
||||
</ProductDependencies>
|
||||
<ToolsetDependencies>
|
||||
diff --git a/eng/Versions.props b/eng/Versions.props
|
||||
index 2758207..6a02917 100644
|
||||
--- a/eng/Versions.props
|
||||
+++ b/eng/Versions.props
|
||||
@@ -18,8 +18,8 @@
|
||||
<!-- Dependencies from https://github.com/dotnet/roslyn -->
|
||||
<MicrosoftNETCoreCompilersPackageVersion>4.0.0-6.21515.3</MicrosoftNETCoreCompilersPackageVersion>
|
||||
<!-- Dependencies from https://github.com/dotnet/command-line-api -->
|
||||
- <SystemCommandLineVersion>2.0.0-beta1.21473.1</SystemCommandLineVersion>
|
||||
- <SystemCommandLineRenderingVersion>0.3.0-alpha.21473.1</SystemCommandLineRenderingVersion>
|
||||
+ <SystemCommandLineVersion>2.0.0-beta1.21525.1</SystemCommandLineVersion>
|
||||
+ <SystemCommandLineRenderingVersion>0.3.0-alpha.21525.1</SystemCommandLineRenderingVersion>
|
||||
</PropertyGroup>
|
||||
<!--
|
||||
Other Dependency versions
|
||||
diff --git a/src/Commands/FormatAnalyzersCommand.cs b/src/Commands/FormatAnalyzersCommand.cs
|
||||
index 322397e..0be3daf 100644
|
||||
--- a/src/Commands/FormatAnalyzersCommand.cs
|
||||
+++ b/src/Commands/FormatAnalyzersCommand.cs
|
||||
@@ -37,13 +37,13 @@ namespace Microsoft.CodeAnalysis.Tools.Commands
|
||||
formatOptions = parseResult.ParseWorkspaceOptions(formatOptions);
|
||||
|
||||
if (parseResult.HasOption(SeverityOption) &&
|
||||
- parseResult.ValueForOption(SeverityOption) is string { Length: > 0 } analyzerSeverity)
|
||||
+ parseResult.GetValueForOption(SeverityOption) is string { Length: > 0 } analyzerSeverity)
|
||||
{
|
||||
formatOptions = formatOptions with { AnalyzerSeverity = GetSeverity(analyzerSeverity) };
|
||||
}
|
||||
|
||||
if (parseResult.HasOption(DiagnosticsOption) &&
|
||||
- parseResult.ValueForOption(DiagnosticsOption) is string[] { Length: > 0 } diagnostics)
|
||||
+ parseResult.GetValueForOption(DiagnosticsOption) is string[] { Length: > 0 } diagnostics)
|
||||
{
|
||||
formatOptions = formatOptions with { Diagnostics = diagnostics.ToImmutableHashSet() };
|
||||
}
|
||||
diff --git a/src/Commands/FormatCommandCommon.cs b/src/Commands/FormatCommandCommon.cs
|
||||
index fb69853..565c2d1 100644
|
||||
--- a/src/Commands/FormatCommandCommon.cs
|
||||
+++ b/src/Commands/FormatCommandCommon.cs
|
||||
@@ -137,7 +137,7 @@ namespace Microsoft.CodeAnalysis.Tools
|
||||
public static FormatOptions ParseVerbosityOption(this ParseResult parseResult, FormatOptions formatOptions)
|
||||
{
|
||||
if (parseResult.HasOption(VerbosityOption) &&
|
||||
- parseResult.ValueForOption(VerbosityOption) is string { Length: > 0 } verbosity)
|
||||
+ parseResult.GetValueForOption(VerbosityOption) is string { Length: > 0 } verbosity)
|
||||
{
|
||||
formatOptions = formatOptions with { LogLevel = GetLogLevel(verbosity) };
|
||||
}
|
||||
@@ -169,8 +169,8 @@ namespace Microsoft.CodeAnalysis.Tools
|
||||
|
||||
if (parseResult.HasOption(IncludeOption) || parseResult.HasOption(ExcludeOption))
|
||||
{
|
||||
- var fileToInclude = parseResult.ValueForOption(IncludeOption) ?? Array.Empty<string>();
|
||||
- var fileToExclude = parseResult.ValueForOption(ExcludeOption) ?? Array.Empty<string>();
|
||||
+ var fileToInclude = parseResult.GetValueForOption(IncludeOption) ?? Array.Empty<string>();
|
||||
+ var fileToExclude = parseResult.GetValueForOption(ExcludeOption) ?? Array.Empty<string>();
|
||||
HandleStandardInput(logger, ref fileToInclude, ref fileToExclude);
|
||||
formatOptions = formatOptions with { FileMatcher = SourceFileMatcher.CreateMatcher(fileToInclude, fileToExclude) };
|
||||
}
|
||||
@@ -179,7 +179,7 @@ namespace Microsoft.CodeAnalysis.Tools
|
||||
{
|
||||
formatOptions = formatOptions with { ReportPath = string.Empty };
|
||||
|
||||
- if (parseResult.ValueForOption(ReportOption) is string { Length: > 0 } reportPath)
|
||||
+ if (parseResult.GetValueForOption(ReportOption) is string { Length: > 0 } reportPath)
|
||||
{
|
||||
formatOptions = formatOptions with { ReportPath = reportPath };
|
||||
}
|
||||
@@ -189,7 +189,7 @@ namespace Microsoft.CodeAnalysis.Tools
|
||||
{
|
||||
formatOptions = formatOptions with { BinaryLogPath = "format.binlog" };
|
||||
|
||||
- if (parseResult.ValueForOption(BinarylogOption) is string { Length: > 0 } binaryLogPath)
|
||||
+ if (parseResult.GetValueForOption(BinarylogOption) is string { Length: > 0 } binaryLogPath)
|
||||
{
|
||||
formatOptions = Path.GetExtension(binaryLogPath)?.Equals(".binlog") == false
|
||||
? (formatOptions with { BinaryLogPath = Path.ChangeExtension(binaryLogPath, ".binlog") })
|
||||
@@ -285,7 +285,7 @@ namespace Microsoft.CodeAnalysis.Tools
|
||||
{
|
||||
var currentDirectory = Environment.CurrentDirectory;
|
||||
|
||||
- if (parseResult.ValueForArgument<string>(SlnOrProjectArgument) is string { Length: > 0 } slnOrProject)
|
||||
+ if (parseResult.GetValueForArgument<string>(SlnOrProjectArgument) is string { Length: > 0 } slnOrProject)
|
||||
{
|
||||
if (parseResult.HasOption(FolderOption))
|
||||
{
|
||||
diff --git a/src/Commands/FormatStyleCommand.cs b/src/Commands/FormatStyleCommand.cs
|
||||
index b44398c..7839855 100644
|
||||
--- a/src/Commands/FormatStyleCommand.cs
|
||||
+++ b/src/Commands/FormatStyleCommand.cs
|
||||
@@ -37,13 +37,13 @@ namespace Microsoft.CodeAnalysis.Tools.Commands
|
||||
formatOptions = parseResult.ParseWorkspaceOptions(formatOptions);
|
||||
|
||||
if (parseResult.HasOption(SeverityOption) &&
|
||||
- parseResult.ValueForOption(SeverityOption) is string { Length: > 0 } styleSeverity)
|
||||
+ parseResult.GetValueForOption(SeverityOption) is string { Length: > 0 } styleSeverity)
|
||||
{
|
||||
formatOptions = formatOptions with { CodeStyleSeverity = GetSeverity(styleSeverity) };
|
||||
}
|
||||
|
||||
if (parseResult.HasOption(DiagnosticsOption) &&
|
||||
- parseResult.ValueForOption(DiagnosticsOption) is string[] { Length: > 0 } diagnostics)
|
||||
+ parseResult.GetValueForOption(DiagnosticsOption) is string[] { Length: > 0 } diagnostics)
|
||||
{
|
||||
formatOptions = formatOptions with { Diagnostics = diagnostics.ToImmutableHashSet() };
|
||||
}
|
||||
diff --git a/src/Commands/RootFormatCommand.cs b/src/Commands/RootFormatCommand.cs
|
||||
index 741effb..40f8cc8 100644
|
||||
--- a/src/Commands/RootFormatCommand.cs
|
||||
+++ b/src/Commands/RootFormatCommand.cs
|
||||
@@ -40,14 +40,14 @@ namespace Microsoft.CodeAnalysis.Tools.Commands
|
||||
formatOptions = parseResult.ParseWorkspaceOptions(formatOptions);
|
||||
|
||||
if (parseResult.HasOption(SeverityOption) &&
|
||||
- parseResult.ValueForOption(SeverityOption) is string { Length: > 0 } defaultSeverity)
|
||||
+ parseResult.GetValueForOption(SeverityOption) is string { Length: > 0 } defaultSeverity)
|
||||
{
|
||||
formatOptions = formatOptions with { AnalyzerSeverity = GetSeverity(defaultSeverity) };
|
||||
formatOptions = formatOptions with { CodeStyleSeverity = GetSeverity(defaultSeverity) };
|
||||
}
|
||||
|
||||
if (parseResult.HasOption(DiagnosticsOption) &&
|
||||
- parseResult.ValueForOption(DiagnosticsOption) is string[] { Length: > 0 } diagnostics)
|
||||
+ parseResult.GetValueForOption(DiagnosticsOption) is string[] { Length: > 0 } diagnostics)
|
||||
{
|
||||
formatOptions = formatOptions with { Diagnostics = diagnostics.ToImmutableHashSet() };
|
||||
}
|
|
@ -0,0 +1,28 @@
|
|||
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
||||
From: MichaelSimons <msimons@microsoft.com>
|
||||
Date: Tue, 23 Nov 2021 16:13:36 +0000
|
||||
Subject: [PATCH] Update System.Threading.Tasks.DataFlow version
|
||||
|
||||
Addresses:
|
||||
NuGet.Build.Tasks.csproj : error NU1605: Detected package downgrade: System.Threading.Tasks.Dataflow from 6.0.0 to 4.9.0. Reference the package directly from the project to select a different version. [src/nuget-client.a998efecd431ec8a41536b5ac0152c16f1e2e646/build/restorehelper.targets]
|
||||
NuGet.Build.Tasks.csproj : error NU1605: NuGet.Build.Tasks -> Microsoft.Build.Tasks.Core 17.1.0-preview-21572-15 -> System.Threading.Tasks.Dataflow (>= 6.0.0) [src/nuget-client.a998efecd431ec8a41536b5ac0152c16f1e2e646/build/restorehelper.targets]
|
||||
NuGet.Build.Tasks.csproj : error NU1605: NuGet.Build.Tasks -> System.Threading.Tasks.Dataflow (>= 4.9.0) [src/nuget-client.a998efecd431ec8a41536b5ac0152c16f1e2e646/build/restorehelper.targets]
|
||||
|
||||
Backport issue: https://github.com/dotnet/source-build/issues/2311
|
||||
---
|
||||
build/packages.targets | 2 +-
|
||||
1 file changed, 1 insertions(+), 1 deletions(-)
|
||||
|
||||
diff --git a/build/packages.targets b/build/packages.targets
|
||||
index a0aa4cc..ef5a1cc 100644
|
||||
--- a/build/packages.targets
|
||||
+++ b/build/packages.targets
|
||||
@@ -58,7 +59,7 @@
|
||||
<PackageReference Update="System.Security.Cryptography.Cng" Version="$(CryptographyPackagesVersion)" />
|
||||
<PackageReference Update="System.Security.Cryptography.Pkcs" Version="$(CryptographyPackagesVersion)" />
|
||||
<PackageReference Update="System.Security.Cryptography.ProtectedData" Version="4.4.0" />
|
||||
- <PackageReference Update="System.Threading.Tasks.Dataflow" Version="4.9.0" />
|
||||
+ <PackageReference Update="System.Threading.Tasks.Dataflow" Version="6.0.0" />
|
||||
<PackageReference Update="VSSDK.TemplateWizardInterface" Version="12.0.4" />
|
||||
<PackageReference Update="VsWebSite.Interop" Version="$(VSFrameworkVersion)" />
|
||||
<PackageReference Update="Microsoft.Net.Compilers.Toolset" Version="3.9.0" />
|
|
@ -0,0 +1,41 @@
|
|||
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
||||
From: MichaelSimons <msimons@microsoft.com>
|
||||
Date: Tue, 23 Nov 2021 17:45:25 +0000
|
||||
Subject: [PATCH] Update nuspec project target frameworks for source-build
|
||||
|
||||
This patch removes prebuilts caused from targetting netcoreapp1.0
|
||||
|
||||
Backported with https://github.com/microsoft/vstest/pull/3188
|
||||
---
|
||||
src/package/nuspec/Microsoft.TestPlatform.Build.csproj | 3 ++-
|
||||
src/package/nuspec/Microsoft.TestPlatform.CLI.csproj | 3 ++-
|
||||
2 files changed, 4 insertions(+), 2 deletions(-)
|
||||
|
||||
diff --git a/src/package/nuspec/Microsoft.TestPlatform.Build.csproj b/src/package/nuspec/Microsoft.TestPlatform.Build.csproj
|
||||
index 038fbf8..57cde8e 100644
|
||||
--- a/src/package/nuspec/Microsoft.TestPlatform.Build.csproj
|
||||
+++ b/src/package/nuspec/Microsoft.TestPlatform.Build.csproj
|
||||
@@ -1,7 +1,8 @@
|
||||
<Project Sdk="Microsoft.NET.Sdk">
|
||||
<PropertyGroup>
|
||||
<OutputType>Exe</OutputType>
|
||||
- <TargetFramework>netcoreapp1.0</TargetFramework>
|
||||
+ <TargetFramework Condition=" '$(DotNetBuildFromSource)' != 'true' ">netcoreapp1.0</TargetFramework>
|
||||
+ <TargetFramework Condition=" '$(DotNetBuildFromSource)' == 'true' ">net6.0</TargetFramework>
|
||||
<CheckEolTargetFramework>false</CheckEolTargetFramework>
|
||||
<NuspecFile>TestPlatform.Build.nuspec</NuspecFile>
|
||||
<NuspecProperties>version=$(Version)</NuspecProperties>
|
||||
diff --git a/src/package/nuspec/Microsoft.TestPlatform.CLI.csproj b/src/package/nuspec/Microsoft.TestPlatform.CLI.csproj
|
||||
index 29198ba..19386eb 100644
|
||||
--- a/src/package/nuspec/Microsoft.TestPlatform.CLI.csproj
|
||||
+++ b/src/package/nuspec/Microsoft.TestPlatform.CLI.csproj
|
||||
@@ -1,7 +1,8 @@
|
||||
<Project Sdk="Microsoft.NET.Sdk">
|
||||
<PropertyGroup>
|
||||
<OutputType>Exe</OutputType>
|
||||
- <TargetFramework>netcoreapp1.0</TargetFramework>
|
||||
+ <TargetFramework Condition=" '$(DotNetBuildFromSource)' != 'true' ">netcoreapp1.0</TargetFramework>
|
||||
+ <TargetFramework Condition=" '$(DotNetBuildFromSource)' == 'true' ">net6.0</TargetFramework>
|
||||
<CheckEolTargetFramework>false</CheckEolTargetFramework>
|
||||
<NuspecFile>TestPlatform.CLI.nuspec</NuspecFile>
|
||||
<NuspecProperties>version=$(Version)</NuspecProperties>
|
Loading…
Add table
Reference in a new issue