[release/6.0.1xx] Remove/Replace NuGet.Client source build patches (#12504)
* Remove NuGet.Client source build patches After the latest flow from nuget, I am fairly sure after examining and attempting to apply these patches that they all are no longer necessary. There are some slight diffs (they don't all apply as no-ops), but the code in question appears to be okay on inspection. * Port missing parts of the patch. * Don't remove necessary files in Roslyn patch. Co-authored-by: Chris Rummel <crummel@microsoft.com>
This commit is contained in:
parent
172b5673bf
commit
626c3886e7
10 changed files with 325 additions and 635 deletions
|
@ -1,31 +0,0 @@
|
|||
From 335f32e48fd5604cdb1340ec04d6503a3e43d783 Mon Sep 17 00:00:00 2001
|
||||
From: Michael Simons <msimons@microsoft.com>
|
||||
Date: Tue, 17 Aug 2021 21:09:35 +0000
|
||||
Subject: [PATCH] Don't use PublicApiAnalyzer on source-build
|
||||
|
||||
CSC : warning AD0001: Analyzer 'Microsoft.CodeAnalysis.PublicApiAnalyzers.DeclarePublicApiAnalyzer' threw an exception of type 'System.NullReferenceException' with message 'Object reference not set to an instance of an object.'.
|
||||
CSC : error CS2001: Source file '/repos/installer2/artifacts/tarball/src/nuget-client.7363366401b43f4ea250394db8dad3707e9a9636/src/NuGet.Core/NuGet.Common/PublicAPI/net6.0/PublicAPI.Shipped.txt' could not be found.
|
||||
|
||||
---
|
||||
build/common.targets | 5 +++++
|
||||
1 file changed, 5 insertions(+)
|
||||
|
||||
diff --git a/build/common.targets b/build/common.targets
|
||||
index 2c387f576..cf5a70c62 100644
|
||||
--- a/build/common.targets
|
||||
+++ b/build/common.targets
|
||||
@@ -65,6 +65,11 @@
|
||||
<None Include="$(MSBuildThisFileDirectory)..\icon.png" Pack="true" PackagePath="\" Visible="false" />
|
||||
</ItemGroup>
|
||||
|
||||
+ <!-- Don't use PublicApiAnalyzer on source-build .NET -->
|
||||
+ <PropertyGroup Condition=" '$(IsBuildOnlyXPLATProjects)' == 'true' ">
|
||||
+ <UsePublicApiAnalyzer>false</UsePublicApiAnalyzer>
|
||||
+ </PropertyGroup>
|
||||
+
|
||||
<!-- Projects we pack become public APIs that others can use -->
|
||||
<PropertyGroup Condition=" '$(IsBuildOnlyXPLATProjects)' != 'true' and '$(PackProject)' == 'true' ">
|
||||
<UsePublicApiAnalyzer Condition=" '$(UsePublicApiAnalyzer)' == '' " >true</UsePublicApiAnalyzer>
|
||||
--
|
||||
2.29.2
|
||||
|
|
@ -0,0 +1,296 @@
|
|||
From 157de59d479f2ed179b9b777eaf2b769871e3bf6 Mon Sep 17 00:00:00 2001
|
||||
From: Matt Mitchell <mmitche@microsoft.com>
|
||||
Date: Sat, 23 Oct 2021 16:41:24 -0700
|
||||
Subject: [PATCH] Remove uneeded source build patches and re-patch
|
||||
|
||||
---
|
||||
build/common.project.props | 16 ++++++----------
|
||||
build/packages.targets | 3 ++-
|
||||
.../NuGet.Build.Tasks.Pack.csproj | 4 ++--
|
||||
.../NuGet.CommandLine.XPlat.csproj | 2 +-
|
||||
.../SignCommand/CertificateProvider.cs | 4 ++--
|
||||
src/NuGet.Core/NuGet.Common/NuGet.Common.csproj | 1 -
|
||||
.../NuGet.Configuration.csproj | 3 +--
|
||||
.../NuGet.Frameworks/NuGet.Frameworks.csproj | 3 +--
|
||||
.../NuGet.PackageManagement.csproj | 2 +-
|
||||
.../Signing/Authoring/SignPackageRequest.cs | 2 ++
|
||||
.../NuGet.Packaging/Signing/Cms/NativeUtility.cs | 2 ++
|
||||
.../HttpSource/HttpRequestMessageExtensions.cs | 6 +++---
|
||||
.../HttpSource/HttpRetryHandler.cs | 2 +-
|
||||
.../HttpSourceAuthenticationHandler.cs | 2 +-
|
||||
.../NuGet.Versioning/NuGet.Versioning.csproj | 1 -
|
||||
15 files changed, 25 insertions(+), 28 deletions(-)
|
||||
|
||||
diff --git a/build/common.project.props b/build/common.project.props
|
||||
index 79a935391..65e482b83 100644
|
||||
--- a/build/common.project.props
|
||||
+++ b/build/common.project.props
|
||||
@@ -10,24 +10,20 @@
|
||||
|
||||
<!-- Common -->
|
||||
<PropertyGroup>
|
||||
- <IsBuildOnlyXPLATProjects>$(DotNetBuildFromSource)</IsBuildOnlyXPLATProjects>
|
||||
<RestoreProjectStyle>PackageReference</RestoreProjectStyle>
|
||||
<NETFXTargetFrameworkVersion>v4.7.2</NETFXTargetFrameworkVersion>
|
||||
<NETFXTargetFramework>net472</NETFXTargetFramework>
|
||||
- <NETCoreTargetFramework>netcoreapp2.1</NETCoreTargetFramework>
|
||||
- <NETCoreTargetFramework Condition="'$(DotNetBuildFromSource)' == 'true'">net6.0</NETCoreTargetFramework>
|
||||
+ <NETCoreTargetFramework>net6.0</NETCoreTargetFramework>
|
||||
<NETCoreTestTargetFramework>netcoreapp5.0</NETCoreTestTargetFramework>
|
||||
- <NetStandardVersion>netstandard2.0</NetStandardVersion>
|
||||
- <NetStandardVersion Condition="'$(DotNetBuildFromSource)' == 'true'">net6.0</NetStandardVersion>
|
||||
+ <IsBuildOnlyXPLATProjects>$(DotNetBuildFromSource)</IsBuildOnlyXPLATProjects>
|
||||
+ <NetStandardVersion>netstandard2.0;net6.0</NetStandardVersion>
|
||||
<TargetFrameworksExe>$(NETFXTargetFramework);$(NETCoreTargetFramework)</TargetFrameworksExe>
|
||||
<TargetFrameworksExe Condition="'$(IsBuildOnlyXPLATProjects)' == 'true' OR '$(IsXPlat)' == 'true'">$(NETCoreTargetFramework)</TargetFrameworksExe>
|
||||
- <TargetFrameworksExeForSigning>$(TargetFrameworksExe);netcoreapp5.0</TargetFrameworksExeForSigning>
|
||||
- <TargetFrameworksExeForSigning Condition=" '$(IsXPlat)' == 'true' ">$(NETCoreTargetFramework);netcoreapp5.0</TargetFrameworksExeForSigning>
|
||||
- <TargetFrameworksExeForSigning Condition="'$(DotNetBuildFromSource)' == 'true'">$(TargetFrameworksExe);net6.0</TargetFrameworksExeForSigning>
|
||||
+ <TargetFrameworksExeForSigning>$(TargetFrameworksExe);net6.0</TargetFrameworksExeForSigning>
|
||||
+ <TargetFrameworksExeForSigning Condition=" '$(IsXPlat)' == 'true' ">$(NETCoreTargetFramework);net6.0</TargetFrameworksExeForSigning>
|
||||
<TargetFrameworksLibrary>$(NETFXTargetFramework);$(NetStandardVersion)</TargetFrameworksLibrary>
|
||||
<TargetFrameworksLibrary Condition="'$(IsBuildOnlyXPLATProjects)' == 'true'">$(NetStandardVersion)</TargetFrameworksLibrary>
|
||||
- <TargetFrameworksLibraryForSigning>$(TargetFrameworksLibrary);netcoreapp5.0</TargetFrameworksLibraryForSigning>
|
||||
- <TargetFrameworksLibraryForSigning Condition="'$(DotNetBuildFromSource)' == 'true'">$(TargetFrameworksLibrary);net6.0</TargetFrameworksLibraryForSigning>
|
||||
+ <TargetFrameworksLibraryForSigning>$(TargetFrameworksLibrary);net6.0</TargetFrameworksLibraryForSigning>
|
||||
<TargetFrameworksLibraryForCrossVerificationTests>$(NETFXTargetFramework);netcoreapp5.0</TargetFrameworksLibraryForCrossVerificationTests>
|
||||
<RepositoryRootDirectory>$([MSBuild]::GetDirectoryNameOfFileAbove($(MSBuildThisFileDirectory), 'README.md'))\</RepositoryRootDirectory>
|
||||
<BuildCommonDirectory>$(RepositoryRootDirectory)build\</BuildCommonDirectory>
|
||||
diff --git a/build/packages.targets b/build/packages.targets
|
||||
index c11557248..0e7dd7861 100644
|
||||
--- a/build/packages.targets
|
||||
+++ b/build/packages.targets
|
||||
@@ -10,6 +10,7 @@
|
||||
<CryptographyPackagesVersion>5.0.0</CryptographyPackagesVersion>
|
||||
<NuGetCoreV2Version>2.14.0-rtm-832</NuGetCoreV2Version>
|
||||
<ProjectSystemManagedVersion>17.0.0-beta1-10402-05</ProjectSystemManagedVersion>
|
||||
+ <MicrosoftExtensionsCommandLineUtilsSourcesPackageVersion Condition="'$(MicrosoftExtensionsCommandLineUtilsSourcesPackageVersion)' == ''">5.0.1-rtm.21063.7</MicrosoftExtensionsCommandLineUtilsSourcesPackageVersion>
|
||||
</PropertyGroup>
|
||||
|
||||
<!-- Test and package versions -->
|
||||
@@ -33,7 +34,7 @@
|
||||
<PackageReference Update="Microsoft.Build.Utilities.Core" Version="$(MicrosoftBuildPackageVersion)" />
|
||||
<PackageReference Update="Microsoft.CodeAnalysis.FxCopAnalyzers" Version="2.9.8" />
|
||||
<PackageReference Update="Microsoft.DataAI.NuGetRecommender.Contracts" Version="2.1.0" />
|
||||
- <PackageReference Update="Microsoft.Extensions.CommandLineUtils" Version="1.0.1" />
|
||||
+ <PackageReference Update="Microsoft.Extensions.CommandLineUtils.Sources" Version="$(MicrosoftExtensionsCommandLineUtilsSourcesPackageVersion)" />
|
||||
<PackageReference Update="Microsoft.Internal.VisualStudio.Shell.Framework" Version="$(VSFrameworkVersion)" />
|
||||
<PackageReference Update="Microsoft.SourceLink.GitHub" Version="1.0.0" />
|
||||
<PackageReference Update="Microsoft.TeamFoundationServer.ExtendedClient" Version="$(VSServicesVersion)" />
|
||||
diff --git a/src/NuGet.Core/NuGet.Build.Tasks.Pack/NuGet.Build.Tasks.Pack.csproj b/src/NuGet.Core/NuGet.Build.Tasks.Pack/NuGet.Build.Tasks.Pack.csproj
|
||||
index c94acffd8..f4d083e52 100644
|
||||
--- a/src/NuGet.Core/NuGet.Build.Tasks.Pack/NuGet.Build.Tasks.Pack.csproj
|
||||
+++ b/src/NuGet.Core/NuGet.Build.Tasks.Pack/NuGet.Build.Tasks.Pack.csproj
|
||||
@@ -177,7 +177,7 @@
|
||||
<!-- Build from source can't use ILMerge. -->
|
||||
<ILMergeSubpath Condition="'$(IsBuildOnlyXPLATProjects)' != 'true'">ilmerge\</ILMergeSubpath>
|
||||
<PackagePathDir Condition="'$(TargetFramework)' == '$(NETFXTargetFramework)' AND '$(IsBuildOnlyXPLATProjects)' != 'true'">Desktop/</PackagePathDir>
|
||||
- <PackagePathDir Condition="'$(TargetFramework)' == '$(NetStandardVersion)'">CoreCLR/</PackagePathDir>
|
||||
+ <PackagePathDir Condition="'$(TargetFramework)' == 'netstandard2.0'">CoreCLR/</PackagePathDir>
|
||||
</PropertyGroup>
|
||||
<ItemGroup>
|
||||
<TfmSpecificPackageFile Include="$(OutputPath)\$(ILMergeSubpath)NuGet.Build.Tasks.Pack.dll" Condition="'$(IsBuildOnlyXPLATProjects)' != 'true'">
|
||||
@@ -189,7 +189,7 @@
|
||||
<TfmSpecificPackageFile Include="$(OutputPath)\$(ILMergeSubpath)NuGet*.dll" Condition="'$(IsBuildOnlyXPLATProjects)' == 'true'">
|
||||
<PackagePath>$(PackagePathDir)</PackagePath>
|
||||
</TfmSpecificPackageFile>
|
||||
- </ItemGroup>
|
||||
+ </ItemGroup>
|
||||
</Target>
|
||||
|
||||
<Import Project="$(BuildCommonDirectory)common.targets"/>
|
||||
diff --git a/src/NuGet.Core/NuGet.CommandLine.XPlat/NuGet.CommandLine.XPlat.csproj b/src/NuGet.Core/NuGet.CommandLine.XPlat/NuGet.CommandLine.XPlat.csproj
|
||||
index 21015c00a..e306cdee4 100644
|
||||
--- a/src/NuGet.Core/NuGet.CommandLine.XPlat/NuGet.CommandLine.XPlat.csproj
|
||||
+++ b/src/NuGet.Core/NuGet.CommandLine.XPlat/NuGet.CommandLine.XPlat.csproj
|
||||
@@ -18,7 +18,7 @@
|
||||
</ItemGroup>
|
||||
|
||||
<ItemGroup>
|
||||
- <PackageReference Include="Microsoft.Extensions.CommandLineUtils" />
|
||||
+ <PackageReference Include="Microsoft.Extensions.CommandLineUtils.Sources" />
|
||||
<PackageReference Include="System.Diagnostics.Debug" />
|
||||
</ItemGroup>
|
||||
|
||||
diff --git a/src/NuGet.Core/NuGet.Commands/SignCommand/CertificateProvider.cs b/src/NuGet.Core/NuGet.Commands/SignCommand/CertificateProvider.cs
|
||||
index c6ea71243..beac41889 100644
|
||||
--- a/src/NuGet.Core/NuGet.Commands/SignCommand/CertificateProvider.cs
|
||||
+++ b/src/NuGet.Core/NuGet.Commands/SignCommand/CertificateProvider.cs
|
||||
@@ -115,7 +115,7 @@ public static async Task<X509Certificate2Collection> GetCertificatesAsync(Certif
|
||||
|
||||
return resultCollection;
|
||||
}
|
||||
-
|
||||
+#pragma warning disable CS1998
|
||||
private static async Task<X509Certificate2> LoadCertificateFromFileAsync(CertificateSourceOptions options)
|
||||
{
|
||||
X509Certificate2 cert;
|
||||
@@ -154,7 +154,7 @@ private static async Task<X509Certificate2> LoadCertificateFromFileAsync(Certifi
|
||||
|
||||
return cert;
|
||||
}
|
||||
-
|
||||
+#pragma warning restore CS1998
|
||||
private static X509Certificate2Collection LoadCertificateFromStore(CertificateSourceOptions options)
|
||||
{
|
||||
X509Certificate2Collection resultCollection = null;
|
||||
diff --git a/src/NuGet.Core/NuGet.Common/NuGet.Common.csproj b/src/NuGet.Core/NuGet.Common/NuGet.Common.csproj
|
||||
index e30a079eb..c2b8fe241 100644
|
||||
--- a/src/NuGet.Core/NuGet.Common/NuGet.Common.csproj
|
||||
+++ b/src/NuGet.Core/NuGet.Common/NuGet.Common.csproj
|
||||
@@ -5,7 +5,6 @@
|
||||
<PropertyGroup>
|
||||
<Description>Common utilities and interfaces for all NuGet libraries.</Description>
|
||||
<TargetFrameworks>$(TargetFrameworksLibrary)</TargetFrameworks>
|
||||
- <TargetFrameworks Condition="'$(IsBuildOnlyXPLATProjects)' != 'true'">$(TargetFrameworks);net45</TargetFrameworks>
|
||||
<TargetFramework />
|
||||
<NoWarn>$(NoWarn);CS1591;CS1574</NoWarn>
|
||||
<PackProject>true</PackProject>
|
||||
diff --git a/src/NuGet.Core/NuGet.Configuration/NuGet.Configuration.csproj b/src/NuGet.Core/NuGet.Configuration/NuGet.Configuration.csproj
|
||||
index bbc5ba480..18b597c74 100644
|
||||
--- a/src/NuGet.Core/NuGet.Configuration/NuGet.Configuration.csproj
|
||||
+++ b/src/NuGet.Core/NuGet.Configuration/NuGet.Configuration.csproj
|
||||
@@ -6,7 +6,6 @@
|
||||
<Description>NuGet's configuration settings implementation.</Description>
|
||||
<NoWarn>$(NoWarn);CS1591</NoWarn>
|
||||
<TargetFrameworks>$(TargetFrameworksLibrary)</TargetFrameworks>
|
||||
- <TargetFrameworks Condition="'$(IsBuildOnlyXPLATProjects)' != 'true'">$(TargetFrameworks);net45</TargetFrameworks>
|
||||
<TargetFramework />
|
||||
<PackProject>true</PackProject>
|
||||
<Shipping>true</Shipping>
|
||||
@@ -29,7 +28,7 @@
|
||||
<Reference Include="System.Xml.Linq" />
|
||||
</ItemGroup>
|
||||
|
||||
- <ItemGroup Condition=" '$(TargetFramework)' == '$(NetStandardVersion)' ">
|
||||
+ <ItemGroup Condition=" '$(TargetFramework)' == 'netstandard2.0' or '$(TargetFramework)' == 'net6.0' ">
|
||||
<PackageReference Include="System.Security.Cryptography.ProtectedData" />
|
||||
</ItemGroup>
|
||||
|
||||
diff --git a/src/NuGet.Core/NuGet.Frameworks/NuGet.Frameworks.csproj b/src/NuGet.Core/NuGet.Frameworks/NuGet.Frameworks.csproj
|
||||
index b78b1f2ea..a89b516c6 100644
|
||||
--- a/src/NuGet.Core/NuGet.Frameworks/NuGet.Frameworks.csproj
|
||||
+++ b/src/NuGet.Core/NuGet.Frameworks/NuGet.Frameworks.csproj
|
||||
@@ -4,8 +4,7 @@
|
||||
|
||||
<PropertyGroup>
|
||||
<Description>NuGet's understanding of target frameworks.</Description>
|
||||
- <TargetFrameworks Condition="'$(IsBuildOnlyXPLATProjects)' == 'true'">$(TargetFrameworksLibrary);netstandard2.0</TargetFrameworks>
|
||||
- <TargetFrameworks Condition="'$(IsBuildOnlyXPLATProjects)' != 'true'">$(TargetFrameworksLibrary);net40</TargetFrameworks>
|
||||
+ <TargetFrameworks>$(TargetFrameworksLibrary);netstandard2.0</TargetFrameworks>
|
||||
<TargetFramework />
|
||||
<NoWarn>$(NoWarn);CS1591;CS1574;CS1573</NoWarn>
|
||||
<PackProject>true</PackProject>
|
||||
diff --git a/src/NuGet.Core/NuGet.PackageManagement/NuGet.PackageManagement.csproj b/src/NuGet.Core/NuGet.PackageManagement/NuGet.PackageManagement.csproj
|
||||
index dfbfcaa8d..a6bb51d6b 100644
|
||||
--- a/src/NuGet.Core/NuGet.PackageManagement/NuGet.PackageManagement.csproj
|
||||
+++ b/src/NuGet.Core/NuGet.PackageManagement/NuGet.PackageManagement.csproj
|
||||
@@ -35,7 +35,7 @@
|
||||
<Reference Include="System.Net.Http" />
|
||||
</ItemGroup>
|
||||
|
||||
- <ItemGroup Condition=" '$(TargetFramework)' == '$(NetStandardVersion)' ">
|
||||
+ <ItemGroup Condition=" '$(TargetFramework)' == 'netstandard2.0' or '$(TargetFramework)' == 'net6.0' ">
|
||||
<PackageReference Include="System.ComponentModel.Composition" />
|
||||
</ItemGroup>
|
||||
|
||||
diff --git a/src/NuGet.Core/NuGet.Packaging/Signing/Authoring/SignPackageRequest.cs b/src/NuGet.Core/NuGet.Packaging/Signing/Authoring/SignPackageRequest.cs
|
||||
index e0cfae99f..ce19f2d6e 100644
|
||||
--- a/src/NuGet.Core/NuGet.Packaging/Signing/Authoring/SignPackageRequest.cs
|
||||
+++ b/src/NuGet.Core/NuGet.Packaging/Signing/Authoring/SignPackageRequest.cs
|
||||
@@ -98,7 +98,9 @@ protected virtual void Dispose(bool disposing)
|
||||
Chain?.Dispose();
|
||||
|
||||
#if IS_SIGNING_SUPPORTED
|
||||
+#pragma warning disable CA1416
|
||||
PrivateKey?.Dispose();
|
||||
+#pragma warning restore CA1416
|
||||
#endif
|
||||
}
|
||||
|
||||
diff --git a/src/NuGet.Core/NuGet.Packaging/Signing/Cms/NativeUtility.cs b/src/NuGet.Core/NuGet.Packaging/Signing/Cms/NativeUtility.cs
|
||||
index 565ac60b7..d57e38a65 100644
|
||||
--- a/src/NuGet.Core/NuGet.Packaging/Signing/Cms/NativeUtility.cs
|
||||
+++ b/src/NuGet.Core/NuGet.Packaging/Signing/Cms/NativeUtility.cs
|
||||
@@ -120,7 +120,9 @@ internal static SignedCms NativeSign(CmsSigner cmsSigner, byte[] data, CngKey pr
|
||||
|
||||
signerInfo.cbSize = (uint)Marshal.SizeOf(signerInfo);
|
||||
signerInfo.pCertInfo = MarshalUtility.PtrToStructure<CERT_CONTEXT>(cmsSigner.Certificate.Handle).pCertInfo;
|
||||
+#pragma warning disable CA1416
|
||||
signerInfo.hCryptProvOrhNCryptKey = privateKey.Handle.DangerousGetHandle();
|
||||
+#pragma warning restore CA1416
|
||||
signerInfo.HashAlgorithm.pszObjId = cmsSigner.DigestAlgorithm.Value;
|
||||
|
||||
if (cmsSigner.SignerIdentifierType == SubjectIdentifierType.SubjectKeyIdentifier)
|
||||
diff --git a/src/NuGet.Core/NuGet.Protocol/HttpSource/HttpRequestMessageExtensions.cs b/src/NuGet.Core/NuGet.Protocol/HttpSource/HttpRequestMessageExtensions.cs
|
||||
index 7c9595268..1ca751850 100644
|
||||
--- a/src/NuGet.Core/NuGet.Protocol/HttpSource/HttpRequestMessageExtensions.cs
|
||||
+++ b/src/NuGet.Core/NuGet.Protocol/HttpSource/HttpRequestMessageExtensions.cs
|
||||
@@ -34,7 +34,7 @@ internal static HttpRequestMessage Clone(this HttpRequestMessage request)
|
||||
clone.Headers.TryAddWithoutValidation(header.Key, header.Value);
|
||||
}
|
||||
|
||||
-#if NET5_0
|
||||
+#if NET5_0 || NET6_0
|
||||
var clonedOptions = (IDictionary<string, object>)clone.Options;
|
||||
foreach (var option in request.Options)
|
||||
{
|
||||
@@ -118,7 +118,7 @@ public static void SetConfiguration(this HttpRequestMessage request, HttpRequest
|
||||
throw new ArgumentNullException(nameof(configuration));
|
||||
}
|
||||
|
||||
-#if NET5_0
|
||||
+#if NET5_0 || NET6_0
|
||||
request.Options.Set(new HttpRequestOptionsKey<HttpRequestMessageConfiguration>(NuGetConfigurationKey), configuration);
|
||||
#else
|
||||
request.Properties[NuGetConfigurationKey] = configuration;
|
||||
@@ -128,7 +128,7 @@ public static void SetConfiguration(this HttpRequestMessage request, HttpRequest
|
||||
private static T GetProperty<T>(this HttpRequestMessage request, string key)
|
||||
{
|
||||
|
||||
-#if NET5_0
|
||||
+#if NET5_0 || NET6_0
|
||||
if (request.Options.TryGetValue<T>(new HttpRequestOptionsKey<T>(key), out T result))
|
||||
#else
|
||||
object result;
|
||||
diff --git a/src/NuGet.Core/NuGet.Protocol/HttpSource/HttpRetryHandler.cs b/src/NuGet.Core/NuGet.Protocol/HttpSource/HttpRetryHandler.cs
|
||||
index c7bcb54bb..30d86fcc9 100644
|
||||
--- a/src/NuGet.Core/NuGet.Protocol/HttpSource/HttpRetryHandler.cs
|
||||
+++ b/src/NuGet.Core/NuGet.Protocol/HttpSource/HttpRetryHandler.cs
|
||||
@@ -113,7 +113,7 @@ internal HttpRetryHandler(IEnvironmentVariableReader environmentVariableReader)
|
||||
headerStopwatch = new Stopwatch();
|
||||
stopwatches.Add(headerStopwatch);
|
||||
}
|
||||
-#if NET5_0
|
||||
+#if NET5_0 || NET6_0
|
||||
requestMessage.Options.Set(new HttpRequestOptionsKey<List<Stopwatch>>(StopwatchPropertyName), stopwatches);
|
||||
#else
|
||||
requestMessage.Properties[StopwatchPropertyName] = stopwatches;
|
||||
diff --git a/src/NuGet.Core/NuGet.Protocol/HttpSource/HttpSourceAuthenticationHandler.cs b/src/NuGet.Core/NuGet.Protocol/HttpSource/HttpSourceAuthenticationHandler.cs
|
||||
index b9ab58ce7..ebf738e52 100644
|
||||
--- a/src/NuGet.Core/NuGet.Protocol/HttpSource/HttpSourceAuthenticationHandler.cs
|
||||
+++ b/src/NuGet.Core/NuGet.Protocol/HttpSource/HttpSourceAuthenticationHandler.cs
|
||||
@@ -98,7 +98,7 @@ protected override async Task<HttpResponseMessage> SendAsync(HttpRequestMessage
|
||||
{
|
||||
List<Stopwatch> stopwatches = null;
|
||||
|
||||
-#if NET5_0
|
||||
+#if NET5_0 || NET6_0
|
||||
if (request.Options.TryGetValue(
|
||||
new HttpRequestOptionsKey<List<Stopwatch>>(HttpRetryHandler.StopwatchPropertyName),
|
||||
out stopwatches))
|
||||
diff --git a/src/NuGet.Core/NuGet.Versioning/NuGet.Versioning.csproj b/src/NuGet.Core/NuGet.Versioning/NuGet.Versioning.csproj
|
||||
index 180293944..8498664b9 100644
|
||||
--- a/src/NuGet.Core/NuGet.Versioning/NuGet.Versioning.csproj
|
||||
+++ b/src/NuGet.Core/NuGet.Versioning/NuGet.Versioning.csproj
|
||||
@@ -4,7 +4,6 @@
|
||||
|
||||
<PropertyGroup>
|
||||
<TargetFrameworks>$(TargetFrameworksLibrary)</TargetFrameworks>
|
||||
- <TargetFrameworks Condition="'$(IsBuildOnlyXPLATProjects)' != 'true'">$(TargetFrameworks);net45</TargetFrameworks>
|
||||
<TargetFramework />
|
||||
<Description>NuGet's implementation of Semantic Versioning.</Description>
|
||||
<PackageTags>semver;semantic versioning</PackageTags>
|
||||
--
|
||||
2.31.1
|
||||
|
|
@ -1,144 +0,0 @@
|
|||
From de74c87d3f9364be1f3bdba43844c8de92704757 Mon Sep 17 00:00:00 2001
|
||||
From: Michael Simons <msimons@microsoft.com>
|
||||
Date: Tue, 17 Aug 2021 21:13:07 +0000
|
||||
Subject: [PATCH 2/8] Update netcoreapp TFMs to 6.0
|
||||
|
||||
Patch removal is tracked by https://github.com/dotnet/source-build/issues/2555.
|
||||
|
||||
---
|
||||
build/common.project.props | 10 +++++-----
|
||||
build/common.targets | 2 +-
|
||||
.../NuGet.Build.Tasks.Pack.csproj | 2 +-
|
||||
src/NuGet.Core/NuGet.Common/NuGet.Common.csproj | 1 -
|
||||
.../NuGet.Configuration/NuGet.Configuration.csproj | 3 +--
|
||||
.../NuGet.Frameworks/NuGet.Frameworks.csproj | 1 -
|
||||
.../NuGet.PackageManagement.csproj | 2 +-
|
||||
.../NuGet.Versioning/NuGet.Versioning.csproj | 1 -
|
||||
8 files changed, 9 insertions(+), 13 deletions(-)
|
||||
|
||||
diff --git a/build/common.project.props b/build/common.project.props
|
||||
index e2e3c0c11..000702f58 100644
|
||||
--- a/build/common.project.props
|
||||
+++ b/build/common.project.props
|
||||
@@ -13,17 +13,17 @@
|
||||
<RestoreProjectStyle>PackageReference</RestoreProjectStyle>
|
||||
<NETFXTargetFrameworkVersion>v4.7.2</NETFXTargetFrameworkVersion>
|
||||
<NETFXTargetFramework>net472</NETFXTargetFramework>
|
||||
- <NETCoreTargetFramework>netcoreapp2.1</NETCoreTargetFramework>
|
||||
+ <NETCoreTargetFramework>net6.0</NETCoreTargetFramework>
|
||||
<NETCoreTestTargetFramework>netcoreapp5.0</NETCoreTestTargetFramework>
|
||||
<IsBuildOnlyXPLATProjects>$(DotNetBuildFromSource)</IsBuildOnlyXPLATProjects>
|
||||
- <NetStandardVersion>netstandard2.0</NetStandardVersion>
|
||||
+ <NetStandardVersion>netstandard2.0;net6.0</NetStandardVersion>
|
||||
<TargetFrameworksExe>$(NETFXTargetFramework);$(NETCoreTargetFramework)</TargetFrameworksExe>
|
||||
<TargetFrameworksExe Condition="'$(IsBuildOnlyXPLATProjects)' == 'true' OR '$(IsXPlat)' == 'true'">$(NETCoreTargetFramework)</TargetFrameworksExe>
|
||||
- <TargetFrameworksExeForSigning>$(TargetFrameworksExe);netcoreapp5.0</TargetFrameworksExeForSigning>
|
||||
- <TargetFrameworksExeForSigning Condition=" '$(IsXPlat)' == 'true' ">$(NETCoreTargetFramework);netcoreapp5.0</TargetFrameworksExeForSigning>
|
||||
+ <TargetFrameworksExeForSigning>$(TargetFrameworksExe);net6.0</TargetFrameworksExeForSigning>
|
||||
+ <TargetFrameworksExeForSigning Condition=" '$(IsXPlat)' == 'true' ">$(NETCoreTargetFramework);net6.0</TargetFrameworksExeForSigning>
|
||||
<TargetFrameworksLibrary>$(NETFXTargetFramework);$(NetStandardVersion)</TargetFrameworksLibrary>
|
||||
<TargetFrameworksLibrary Condition="'$(IsBuildOnlyXPLATProjects)' == 'true'">$(NetStandardVersion)</TargetFrameworksLibrary>
|
||||
- <TargetFrameworksLibraryForSigning>$(TargetFrameworksLibrary);netcoreapp5.0</TargetFrameworksLibraryForSigning>
|
||||
+ <TargetFrameworksLibraryForSigning>$(TargetFrameworksLibrary);net6.0</TargetFrameworksLibraryForSigning>
|
||||
<TargetFrameworksLibraryForCrossVerificationTests>$(NETFXTargetFramework);netcoreapp5.0</TargetFrameworksLibraryForCrossVerificationTests>
|
||||
<RepositoryRootDirectory>$([MSBuild]::GetDirectoryNameOfFileAbove($(MSBuildThisFileDirectory), 'README.md'))\</RepositoryRootDirectory>
|
||||
<BuildCommonDirectory>$(RepositoryRootDirectory)build\</BuildCommonDirectory>
|
||||
diff --git a/build/common.targets b/build/common.targets
|
||||
index 6fd5bd260..3de830b25 100644
|
||||
--- a/build/common.targets
|
||||
+++ b/build/common.targets
|
||||
@@ -6,7 +6,7 @@
|
||||
<IsDesktop>true</IsDesktop>
|
||||
</PropertyGroup>
|
||||
|
||||
- <PropertyGroup Condition=" $(TargetFramework.StartsWith('netcoreapp')) OR $(TargetFramework.StartsWith('netstandard')) ">
|
||||
+ <PropertyGroup Condition=" $(TargetFramework.StartsWith('netcoreapp')) OR $(TargetFramework.StartsWith('netstandard')) OR '$(TargetFramework)' == 'net6.0' ">
|
||||
<DefineConstants>$(DefineConstants);IS_CORECLR</DefineConstants>
|
||||
<IsCore>true</IsCore>
|
||||
</PropertyGroup>
|
||||
diff --git a/src/NuGet.Core/NuGet.Build.Tasks.Pack/NuGet.Build.Tasks.Pack.csproj b/src/NuGet.Core/NuGet.Build.Tasks.Pack/NuGet.Build.Tasks.Pack.csproj
|
||||
index f11dd752b..d4f11aad5 100644
|
||||
--- a/src/NuGet.Core/NuGet.Build.Tasks.Pack/NuGet.Build.Tasks.Pack.csproj
|
||||
+++ b/src/NuGet.Core/NuGet.Build.Tasks.Pack/NuGet.Build.Tasks.Pack.csproj
|
||||
@@ -177,7 +177,7 @@
|
||||
<!-- Build from source can't use ILMerge. -->
|
||||
<ILMergeSubpath Condition="'$(IsBuildOnlyXPLATProjects)' != 'true'">ilmerge\</ILMergeSubpath>
|
||||
<PackagePathDir Condition="'$(TargetFramework)' == '$(NETFXTargetFramework)' AND '$(IsBuildOnlyXPLATProjects)' != 'true'">Desktop/</PackagePathDir>
|
||||
- <PackagePathDir Condition="'$(TargetFramework)' == '$(NetStandardVersion)'">CoreCLR/</PackagePathDir>
|
||||
+ <PackagePathDir Condition="'$(TargetFramework)' == 'netstandard2.0'">CoreCLR/</PackagePathDir>
|
||||
</PropertyGroup>
|
||||
<ItemGroup>
|
||||
<TfmSpecificPackageFile Include="$(OutputPath)\$(ILMergeSubpath)NuGet.Build.Tasks.Pack.dll">
|
||||
diff --git a/src/NuGet.Core/NuGet.Common/NuGet.Common.csproj b/src/NuGet.Core/NuGet.Common/NuGet.Common.csproj
|
||||
index e30a079eb..c2b8fe241 100644
|
||||
--- a/src/NuGet.Core/NuGet.Common/NuGet.Common.csproj
|
||||
+++ b/src/NuGet.Core/NuGet.Common/NuGet.Common.csproj
|
||||
@@ -5,7 +5,6 @@
|
||||
<PropertyGroup>
|
||||
<Description>Common utilities and interfaces for all NuGet libraries.</Description>
|
||||
<TargetFrameworks>$(TargetFrameworksLibrary)</TargetFrameworks>
|
||||
- <TargetFrameworks Condition="'$(IsBuildOnlyXPLATProjects)' != 'true'">$(TargetFrameworks);net45</TargetFrameworks>
|
||||
<TargetFramework />
|
||||
<NoWarn>$(NoWarn);CS1591;CS1574</NoWarn>
|
||||
<PackProject>true</PackProject>
|
||||
diff --git a/src/NuGet.Core/NuGet.Configuration/NuGet.Configuration.csproj b/src/NuGet.Core/NuGet.Configuration/NuGet.Configuration.csproj
|
||||
index bbc5ba480..18b597c74 100644
|
||||
--- a/src/NuGet.Core/NuGet.Configuration/NuGet.Configuration.csproj
|
||||
+++ b/src/NuGet.Core/NuGet.Configuration/NuGet.Configuration.csproj
|
||||
@@ -6,7 +6,6 @@
|
||||
<Description>NuGet's configuration settings implementation.</Description>
|
||||
<NoWarn>$(NoWarn);CS1591</NoWarn>
|
||||
<TargetFrameworks>$(TargetFrameworksLibrary)</TargetFrameworks>
|
||||
- <TargetFrameworks Condition="'$(IsBuildOnlyXPLATProjects)' != 'true'">$(TargetFrameworks);net45</TargetFrameworks>
|
||||
<TargetFramework />
|
||||
<PackProject>true</PackProject>
|
||||
<Shipping>true</Shipping>
|
||||
@@ -29,7 +28,7 @@
|
||||
<Reference Include="System.Xml.Linq" />
|
||||
</ItemGroup>
|
||||
|
||||
- <ItemGroup Condition=" '$(TargetFramework)' == '$(NetStandardVersion)' ">
|
||||
+ <ItemGroup Condition=" '$(TargetFramework)' == 'netstandard2.0' or '$(TargetFramework)' == 'net6.0' ">
|
||||
<PackageReference Include="System.Security.Cryptography.ProtectedData" />
|
||||
</ItemGroup>
|
||||
|
||||
diff --git a/src/NuGet.Core/NuGet.Frameworks/NuGet.Frameworks.csproj b/src/NuGet.Core/NuGet.Frameworks/NuGet.Frameworks.csproj
|
||||
index 65f261dc1..f29551741 100644
|
||||
--- a/src/NuGet.Core/NuGet.Frameworks/NuGet.Frameworks.csproj
|
||||
+++ b/src/NuGet.Core/NuGet.Frameworks/NuGet.Frameworks.csproj
|
||||
@@ -5,7 +5,6 @@
|
||||
<PropertyGroup>
|
||||
<Description>NuGet's understanding of target frameworks.</Description>
|
||||
<TargetFrameworks>$(TargetFrameworksLibrary)</TargetFrameworks>
|
||||
- <TargetFrameworks Condition="'$(IsBuildOnlyXPLATProjects)' != 'true'">$(TargetFrameworks);net40</TargetFrameworks>
|
||||
<TargetFramework />
|
||||
<NoWarn>$(NoWarn);CS1591;CS1574;CS1573</NoWarn>
|
||||
<PackProject>true</PackProject>
|
||||
diff --git a/src/NuGet.Core/NuGet.PackageManagement/NuGet.PackageManagement.csproj b/src/NuGet.Core/NuGet.PackageManagement/NuGet.PackageManagement.csproj
|
||||
index dfbfcaa8d..a6bb51d6b 100644
|
||||
--- a/src/NuGet.Core/NuGet.PackageManagement/NuGet.PackageManagement.csproj
|
||||
+++ b/src/NuGet.Core/NuGet.PackageManagement/NuGet.PackageManagement.csproj
|
||||
@@ -35,7 +35,7 @@
|
||||
<Reference Include="System.Net.Http" />
|
||||
</ItemGroup>
|
||||
|
||||
- <ItemGroup Condition=" '$(TargetFramework)' == '$(NetStandardVersion)' ">
|
||||
+ <ItemGroup Condition=" '$(TargetFramework)' == 'netstandard2.0' or '$(TargetFramework)' == 'net6.0' ">
|
||||
<PackageReference Include="System.ComponentModel.Composition" />
|
||||
</ItemGroup>
|
||||
|
||||
diff --git a/src/NuGet.Core/NuGet.Versioning/NuGet.Versioning.csproj b/src/NuGet.Core/NuGet.Versioning/NuGet.Versioning.csproj
|
||||
index 180293944..8498664b9 100644
|
||||
--- a/src/NuGet.Core/NuGet.Versioning/NuGet.Versioning.csproj
|
||||
+++ b/src/NuGet.Core/NuGet.Versioning/NuGet.Versioning.csproj
|
||||
@@ -4,7 +4,6 @@
|
||||
|
||||
<PropertyGroup>
|
||||
<TargetFrameworks>$(TargetFrameworksLibrary)</TargetFrameworks>
|
||||
- <TargetFrameworks Condition="'$(IsBuildOnlyXPLATProjects)' != 'true'">$(TargetFrameworks);net45</TargetFrameworks>
|
||||
<TargetFramework />
|
||||
<Description>NuGet's implementation of Semantic Versioning.</Description>
|
||||
<PackageTags>semver;semantic versioning</PackageTags>
|
||||
--
|
||||
2.31.1
|
||||
|
|
@ -1,43 +0,0 @@
|
|||
From fecc40e502197e65804177b2aec49a7a5422ed6e Mon Sep 17 00:00:00 2001
|
||||
From: Davis Goodin <dagood@microsoft.com>
|
||||
Date: Thu, 10 Dec 2020 16:17:55 -0600
|
||||
Subject: [PATCH 3/5] Use source-built Microsoft.Web.Xdt &
|
||||
System.ComponentModel.Composition
|
||||
|
||||
---
|
||||
build/packages.targets | 10 ++++++++--
|
||||
1 file changed, 8 insertions(+), 2 deletions(-)
|
||||
|
||||
diff --git a/build/packages.targets b/build/packages.targets
|
||||
index 6f72ac3fd..8317f3903 100644
|
||||
--- a/build/packages.targets
|
||||
+++ b/build/packages.targets
|
||||
@@ -15,6 +15,12 @@
|
||||
<XunitVersion>2.4.1</XunitVersion>
|
||||
</PropertyGroup>
|
||||
|
||||
+ <!-- source-build-relevant package versions -->
|
||||
+ <PropertyGroup>
|
||||
+ <MicrosoftWebXdtPackageVersion Condition="'$(MicrosoftWebXdtPackageVersion)' == ''">3.0.0</MicrosoftWebXdtPackageVersion>
|
||||
+ <SystemComponentModelCompositionPackageVersion Condition="'$(SystemComponentModelCompositionPackageVersion)' == ''">4.5.0</SystemComponentModelCompositionPackageVersion>
|
||||
+ </PropertyGroup>
|
||||
+
|
||||
<ItemGroup>
|
||||
<!-- PackageDownload -->
|
||||
<PackageDownload Update="Microsoft.Build" Version="[15.1.262-preview5]" />
|
||||
@@ -42,10 +48,10 @@
|
||||
<PackageReference Update="Microsoft.VisualStudio.VCProjectEngine" Version="$(VSFrameworkVersion)" />
|
||||
<PackageReference Update="Microsoft.VisualStudio.Workspace.VSIntegration" Version="17.0.7-preview-0001-g5492e466a9" />
|
||||
<PackageReference Update="Microsoft.VSSDK.BuildTools" Version="17.0.1600" />
|
||||
- <PackageReference Update="Microsoft.Web.Xdt" Version="3.0.0" />
|
||||
+ <PackageReference Update="Microsoft.Web.Xdt" Version="$(MicrosoftWebXdtPackageVersion)" />
|
||||
<PackageReference Update="Newtonsoft.Json" Version="$(NewtonsoftJsonPackageVersion)" />
|
||||
<PackageReference Update="SharpZipLib" Version="1.3.2" />
|
||||
- <PackageReference Update="System.ComponentModel.Composition" Version="4.5.0" />
|
||||
+ <PackageReference Update="System.ComponentModel.Composition" Version="$(SystemComponentModelCompositionPackageVersion)" />
|
||||
<!--
|
||||
The Microsoft.VisualStudio.SDK metapackage brings in System.Threading.Tasks.Dataflow 4.11.1 (assembly version 4.9.5.0).
|
||||
However, our MSBuild integration tests use Microsoft.Build 16.8.0, which requires System.Threading.Tasks.Dataflow 4.9.0 (assembly version 4.9.3.0).
|
||||
--
|
||||
2.18.0
|
||||
|
|
@ -1,88 +0,0 @@
|
|||
From 9e35a4d319f3288a50bdaf5b32661764761aa0e9 Mon Sep 17 00:00:00 2001
|
||||
From: Chris Rummel <crummel@microsoft.com>
|
||||
Date: Thu, 19 Aug 2021 10:59:36 -0500
|
||||
Subject: [PATCH 4/5] Build script changes to support ArPow from tarball.
|
||||
|
||||
---
|
||||
eng/source-build/build.sh | 27 +++++++++++++++++++++++++--
|
||||
eng/source-build/source-build.proj | 6 ++++--
|
||||
2 files changed, 29 insertions(+), 4 deletions(-)
|
||||
|
||||
diff --git a/eng/source-build/build.sh b/eng/source-build/build.sh
|
||||
index 3bb69b2b0..aaff8ef0f 100755
|
||||
--- a/eng/source-build/build.sh
|
||||
+++ b/eng/source-build/build.sh
|
||||
@@ -13,6 +13,25 @@ while [[ -h $source ]]; do
|
||||
[[ $source != /* ]] && source="$scriptroot/$source"
|
||||
done
|
||||
|
||||
+
|
||||
+while [[ $# > 0 ]]; do
|
||||
+ lowerI="$(echo $1 | awk '{print tolower($0)}')"
|
||||
+ case $lowerI in
|
||||
+ --configuration|-c)
|
||||
+ configuration=$2
|
||||
+ shift
|
||||
+ ;;
|
||||
+ -*)
|
||||
+ # just eat this so we don't try to pass it along to MSBuild
|
||||
+ export DOTNET_CORESDK_NOPRETTYPRINT=1
|
||||
+ ;;
|
||||
+ *)
|
||||
+ args="$args $1"
|
||||
+ ;;
|
||||
+ esac
|
||||
+ shift
|
||||
+done
|
||||
+
|
||||
function ReadGlobalVersion {
|
||||
local key=$1
|
||||
local global_json_file="$scriptroot/global.json"
|
||||
@@ -40,8 +59,12 @@ function GetNuGetPackageCachePath {
|
||||
fi
|
||||
}
|
||||
|
||||
-export DOTNET=${DOTNET:-dotnet}
|
||||
+if [[ "$DOTNET" == "" && "$DOTNET_PATH" != "" ]]; then
|
||||
+ export DOTNET="$DOTNET_PATH/dotnet"
|
||||
+else
|
||||
+ export DOTNET=${DOTNET:-dotnet}
|
||||
+fi
|
||||
|
||||
ReadGlobalVersion Microsoft.DotNet.Arcade.Sdk
|
||||
export ARCADE_VERSION=$_ReadGlobalVersion
|
||||
-"$DOTNET" msbuild "$scriptroot/source-build.proj" /p:DotNetBuildFromSource=true /p:ArcadeBuildFromSource=true "/p:RepoRoot=$scriptroot/../../" "/bl:$scriptroot/../../artifacts/source-build/self/log/source-build.binlog"
|
||||
+"$DOTNET" msbuild "$scriptroot/source-build.proj" /p:Configuration=$configuration /p:DotNetBuildFromSource=true /p:ArcadeBuildFromSource=true "/p:RepoRoot=$scriptroot/../../" "/bl:$scriptroot/../../artifacts/source-build/self/log/source-build.binlog" $args
|
||||
diff --git a/eng/source-build/source-build.proj b/eng/source-build/source-build.proj
|
||||
index 6f90f9793..91ea2d032 100644
|
||||
--- a/eng/source-build/source-build.proj
|
||||
+++ b/eng/source-build/source-build.proj
|
||||
@@ -4,6 +4,8 @@
|
||||
|
||||
<PropertyGroup>
|
||||
<ProjectRoot>$(MSBuildThisFileDirectory)../../</ProjectRoot>
|
||||
+ <ArcadeDir Condition="'$(SOURCE_BUILT_SDK_DIR_ARCADE)' != ''">$(SOURCE_BUILT_SDK_DIR_ARCADE)/tools/</ArcadeDir>
|
||||
+ <ArcadeDir Condition="'$(ArcadeDir)' == ''">$(NuGetPackageRoot)/microsoft.dotnet.arcade.sdk/$(ARCADE_VERSION)/tools/</ArcadeDir>
|
||||
</PropertyGroup>
|
||||
|
||||
<Target Name="Build" DependsOnTargets="SourceBuildPostBuild">
|
||||
@@ -18,14 +20,14 @@
|
||||
<Target Name="SourceBuildPostBuild" DependsOnTargets="SourceBuildInnerBuild">
|
||||
<Message Text="Running source-build PostBuild target" Importance="High" />
|
||||
|
||||
- <MSbuild Projects="$(NuGetPackageRoot)/microsoft.dotnet.arcade.sdk/$(ARCADE_VERSION)/tools/Build.proj"
|
||||
+ <MSbuild Projects="$(ArcadeDir)/Build.proj"
|
||||
Properties="_NETCORE_ENGINEERING_TELEMETRY=AfterSourceBuild;ArcadeBuildFromSource=true;Restore=true;Build=false;Pack=false;Publish=false;Rebuild=false;Test=false;IntegrationTest=false;PerformanceTest=false;PreventPrebuiltBuild=false;BaseInnerSourceBuildCommand=echo skipping internal build with args: "
|
||||
Targets="Execute"
|
||||
/>
|
||||
|
||||
<Message Text="Finished restoring Arcade" Importance="High" />
|
||||
|
||||
- <MSbuild Projects="$(NuGetPackageRoot)/microsoft.dotnet.arcade.sdk/$(ARCADE_VERSION)/tools/SourceBuild/AfterSourceBuild.proj"
|
||||
+ <MSbuild Projects="$(ArcadeDir)/SourceBuild/AfterSourceBuild.proj"
|
||||
Properties="_NETCORE_ENGINEERING_TELEMETRY=AfterSourceBuild;ArcadeBuildFromSource=true;CurrentRepoSourceBuildArtifactsPackagesDir=$(ProjectRoot)artifacts/nupkgs/"
|
||||
/>
|
||||
|
||||
--
|
||||
2.18.0
|
||||
|
|
@ -1,124 +0,0 @@
|
|||
From d3c633ad00408b2b6122b70d9a152d1ab79c8378 Mon Sep 17 00:00:00 2001
|
||||
From: Chris Rummel <crummel@microsoft.com>
|
||||
Date: Thu, 19 Aug 2021 11:01:04 -0500
|
||||
Subject: [PATCH 2/2] Upgrade to .NET 6 SDK.
|
||||
|
||||
---
|
||||
.../NuGet.Commands/SignCommand/CertificateProvider.cs | 4 ++--
|
||||
.../NuGet.Packaging/Signing/Authoring/SignPackageRequest.cs | 2 ++
|
||||
src/NuGet.Core/NuGet.Packaging/Signing/Cms/NativeUtility.cs | 2 ++
|
||||
.../HttpSource/HttpRequestMessageExtensions.cs | 6 +++---
|
||||
.../NuGet.Protocol/HttpSource/HttpRetryHandler.cs | 2 +-
|
||||
.../HttpSource/HttpSourceAuthenticationHandler.cs | 2 +-
|
||||
6 files changed, 11 insertions(+), 7 deletions(-)
|
||||
|
||||
diff --git a/src/NuGet.Core/NuGet.Commands/SignCommand/CertificateProvider.cs b/src/NuGet.Core/NuGet.Commands/SignCommand/CertificateProvider.cs
|
||||
index c6ea71243..beac41889 100644
|
||||
--- a/src/NuGet.Core/NuGet.Commands/SignCommand/CertificateProvider.cs
|
||||
+++ b/src/NuGet.Core/NuGet.Commands/SignCommand/CertificateProvider.cs
|
||||
@@ -115,7 +115,7 @@ public static async Task<X509Certificate2Collection> GetCertificatesAsync(Certif
|
||||
|
||||
return resultCollection;
|
||||
}
|
||||
-
|
||||
+#pragma warning disable CS1998
|
||||
private static async Task<X509Certificate2> LoadCertificateFromFileAsync(CertificateSourceOptions options)
|
||||
{
|
||||
X509Certificate2 cert;
|
||||
@@ -154,7 +154,7 @@ private static async Task<X509Certificate2> LoadCertificateFromFileAsync(Certifi
|
||||
|
||||
return cert;
|
||||
}
|
||||
-
|
||||
+#pragma warning restore CS1998
|
||||
private static X509Certificate2Collection LoadCertificateFromStore(CertificateSourceOptions options)
|
||||
{
|
||||
X509Certificate2Collection resultCollection = null;
|
||||
diff --git a/src/NuGet.Core/NuGet.Packaging/Signing/Authoring/SignPackageRequest.cs b/src/NuGet.Core/NuGet.Packaging/Signing/Authoring/SignPackageRequest.cs
|
||||
index e0cfae99f..ce19f2d6e 100644
|
||||
--- a/src/NuGet.Core/NuGet.Packaging/Signing/Authoring/SignPackageRequest.cs
|
||||
+++ b/src/NuGet.Core/NuGet.Packaging/Signing/Authoring/SignPackageRequest.cs
|
||||
@@ -98,7 +98,9 @@ protected virtual void Dispose(bool disposing)
|
||||
Chain?.Dispose();
|
||||
|
||||
#if IS_SIGNING_SUPPORTED
|
||||
+#pragma warning disable CA1416
|
||||
PrivateKey?.Dispose();
|
||||
+#pragma warning restore CA1416
|
||||
#endif
|
||||
}
|
||||
|
||||
diff --git a/src/NuGet.Core/NuGet.Packaging/Signing/Cms/NativeUtility.cs b/src/NuGet.Core/NuGet.Packaging/Signing/Cms/NativeUtility.cs
|
||||
index 565ac60b7..d57e38a65 100644
|
||||
--- a/src/NuGet.Core/NuGet.Packaging/Signing/Cms/NativeUtility.cs
|
||||
+++ b/src/NuGet.Core/NuGet.Packaging/Signing/Cms/NativeUtility.cs
|
||||
@@ -120,7 +120,9 @@ internal static SignedCms NativeSign(CmsSigner cmsSigner, byte[] data, CngKey pr
|
||||
|
||||
signerInfo.cbSize = (uint)Marshal.SizeOf(signerInfo);
|
||||
signerInfo.pCertInfo = MarshalUtility.PtrToStructure<CERT_CONTEXT>(cmsSigner.Certificate.Handle).pCertInfo;
|
||||
+#pragma warning disable CA1416
|
||||
signerInfo.hCryptProvOrhNCryptKey = privateKey.Handle.DangerousGetHandle();
|
||||
+#pragma warning restore CA1416
|
||||
signerInfo.HashAlgorithm.pszObjId = cmsSigner.DigestAlgorithm.Value;
|
||||
|
||||
if (cmsSigner.SignerIdentifierType == SubjectIdentifierType.SubjectKeyIdentifier)
|
||||
diff --git a/src/NuGet.Core/NuGet.Protocol/HttpSource/HttpRequestMessageExtensions.cs b/src/NuGet.Core/NuGet.Protocol/HttpSource/HttpRequestMessageExtensions.cs
|
||||
index 7c9595268..1ca751850 100644
|
||||
--- a/src/NuGet.Core/NuGet.Protocol/HttpSource/HttpRequestMessageExtensions.cs
|
||||
+++ b/src/NuGet.Core/NuGet.Protocol/HttpSource/HttpRequestMessageExtensions.cs
|
||||
@@ -34,7 +34,7 @@ internal static HttpRequestMessage Clone(this HttpRequestMessage request)
|
||||
clone.Headers.TryAddWithoutValidation(header.Key, header.Value);
|
||||
}
|
||||
|
||||
-#if NET5_0
|
||||
+#if NET5_0 || NET6_0
|
||||
var clonedOptions = (IDictionary<string, object>)clone.Options;
|
||||
foreach (var option in request.Options)
|
||||
{
|
||||
@@ -118,7 +118,7 @@ public static void SetConfiguration(this HttpRequestMessage request, HttpRequest
|
||||
throw new ArgumentNullException(nameof(configuration));
|
||||
}
|
||||
|
||||
-#if NET5_0
|
||||
+#if NET5_0 || NET6_0
|
||||
request.Options.Set(new HttpRequestOptionsKey<HttpRequestMessageConfiguration>(NuGetConfigurationKey), configuration);
|
||||
#else
|
||||
request.Properties[NuGetConfigurationKey] = configuration;
|
||||
@@ -128,7 +128,7 @@ public static void SetConfiguration(this HttpRequestMessage request, HttpRequest
|
||||
private static T GetProperty<T>(this HttpRequestMessage request, string key)
|
||||
{
|
||||
|
||||
-#if NET5_0
|
||||
+#if NET5_0 || NET6_0
|
||||
if (request.Options.TryGetValue<T>(new HttpRequestOptionsKey<T>(key), out T result))
|
||||
#else
|
||||
object result;
|
||||
diff --git a/src/NuGet.Core/NuGet.Protocol/HttpSource/HttpRetryHandler.cs b/src/NuGet.Core/NuGet.Protocol/HttpSource/HttpRetryHandler.cs
|
||||
index 67a1726b6..0534e936e 100644
|
||||
--- a/src/NuGet.Core/NuGet.Protocol/HttpSource/HttpRetryHandler.cs
|
||||
+++ b/src/NuGet.Core/NuGet.Protocol/HttpSource/HttpRetryHandler.cs
|
||||
@@ -81,7 +81,7 @@ public class HttpRetryHandler : IHttpRetryHandler
|
||||
headerStopwatch = new Stopwatch();
|
||||
stopwatches.Add(headerStopwatch);
|
||||
}
|
||||
-#if NET5_0
|
||||
+#if NET5_0 || NET6_0
|
||||
requestMessage.Options.Set(new HttpRequestOptionsKey<List<Stopwatch>>(StopwatchPropertyName), stopwatches);
|
||||
#else
|
||||
requestMessage.Properties[StopwatchPropertyName] = stopwatches;
|
||||
diff --git a/src/NuGet.Core/NuGet.Protocol/HttpSource/HttpSourceAuthenticationHandler.cs b/src/NuGet.Core/NuGet.Protocol/HttpSource/HttpSourceAuthenticationHandler.cs
|
||||
index b9ab58ce7..ebf738e52 100644
|
||||
--- a/src/NuGet.Core/NuGet.Protocol/HttpSource/HttpSourceAuthenticationHandler.cs
|
||||
+++ b/src/NuGet.Core/NuGet.Protocol/HttpSource/HttpSourceAuthenticationHandler.cs
|
||||
@@ -98,7 +98,7 @@ protected override async Task<HttpResponseMessage> SendAsync(HttpRequestMessage
|
||||
{
|
||||
List<Stopwatch> stopwatches = null;
|
||||
|
||||
-#if NET5_0
|
||||
+#if NET5_0 || NET6_0
|
||||
if (request.Options.TryGetValue(
|
||||
new HttpRequestOptionsKey<List<Stopwatch>>(HttpRetryHandler.StopwatchPropertyName),
|
||||
out stopwatches))
|
||||
--
|
||||
2.18.0
|
||||
|
|
@ -1,26 +0,0 @@
|
|||
From be9f7f1415250433578ed6aa36da13a4442aff8f Mon Sep 17 00:00:00 2001
|
||||
From: Chris Rummel <crummel@microsoft.com>
|
||||
Date: Fri, 20 Aug 2021 15:30:52 -0500
|
||||
Subject: [PATCH 6/8] Build NuGet.Frameworks for netstandard as well for
|
||||
VSTest.
|
||||
|
||||
---
|
||||
src/NuGet.Core/NuGet.Frameworks/NuGet.Frameworks.csproj | 2 +-
|
||||
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||
|
||||
diff --git a/src/NuGet.Core/NuGet.Frameworks/NuGet.Frameworks.csproj b/src/NuGet.Core/NuGet.Frameworks/NuGet.Frameworks.csproj
|
||||
index f29551741..a89b516c6 100644
|
||||
--- a/src/NuGet.Core/NuGet.Frameworks/NuGet.Frameworks.csproj
|
||||
+++ b/src/NuGet.Core/NuGet.Frameworks/NuGet.Frameworks.csproj
|
||||
@@ -4,7 +4,7 @@
|
||||
|
||||
<PropertyGroup>
|
||||
<Description>NuGet's understanding of target frameworks.</Description>
|
||||
- <TargetFrameworks>$(TargetFrameworksLibrary)</TargetFrameworks>
|
||||
+ <TargetFrameworks>$(TargetFrameworksLibrary);netstandard2.0</TargetFrameworks>
|
||||
<TargetFramework />
|
||||
<NoWarn>$(NoWarn);CS1591;CS1574;CS1573</NoWarn>
|
||||
<PackProject>true</PackProject>
|
||||
--
|
||||
2.31.1
|
||||
|
|
@ -1,35 +0,0 @@
|
|||
From 36e519a13431f36cd30e44a91d3b4f81c6753528 Mon Sep 17 00:00:00 2001
|
||||
From: Michael Simons <msimons@microsoft.com>
|
||||
Date: Fri, 27 Aug 2021 01:52:56 +0000
|
||||
Subject: [PATCH 7/8] NuGet.Build.Tasks.Pack source-build support
|
||||
|
||||
---
|
||||
.../NuGet.Build.Tasks.Pack/NuGet.Build.Tasks.Pack.csproj | 7 +++++--
|
||||
1 file changed, 5 insertions(+), 2 deletions(-)
|
||||
|
||||
diff --git a/src/NuGet.Core/NuGet.Build.Tasks.Pack/NuGet.Build.Tasks.Pack.csproj b/src/NuGet.Core/NuGet.Build.Tasks.Pack/NuGet.Build.Tasks.Pack.csproj
|
||||
index d4f11aad5..f4d083e52 100644
|
||||
--- a/src/NuGet.Core/NuGet.Build.Tasks.Pack/NuGet.Build.Tasks.Pack.csproj
|
||||
+++ b/src/NuGet.Core/NuGet.Build.Tasks.Pack/NuGet.Build.Tasks.Pack.csproj
|
||||
@@ -180,13 +180,16 @@
|
||||
<PackagePathDir Condition="'$(TargetFramework)' == 'netstandard2.0'">CoreCLR/</PackagePathDir>
|
||||
</PropertyGroup>
|
||||
<ItemGroup>
|
||||
- <TfmSpecificPackageFile Include="$(OutputPath)\$(ILMergeSubpath)NuGet.Build.Tasks.Pack.dll">
|
||||
+ <TfmSpecificPackageFile Include="$(OutputPath)\$(ILMergeSubpath)NuGet.Build.Tasks.Pack.dll" Condition="'$(IsBuildOnlyXPLATProjects)' != 'true'">
|
||||
<PackagePath>$(PackagePathDir)</PackagePath>
|
||||
</TfmSpecificPackageFile>
|
||||
<TfmSpecificPackageFile Include="$(OutputPath)\$(ILMergeSubpath)**\NuGet*.resources.dll">
|
||||
<PackagePath>$(PackagePathDir)</PackagePath>
|
||||
</TfmSpecificPackageFile>
|
||||
- </ItemGroup>
|
||||
+ <TfmSpecificPackageFile Include="$(OutputPath)\$(ILMergeSubpath)NuGet*.dll" Condition="'$(IsBuildOnlyXPLATProjects)' == 'true'">
|
||||
+ <PackagePath>$(PackagePathDir)</PackagePath>
|
||||
+ </TfmSpecificPackageFile>
|
||||
+ </ItemGroup>
|
||||
</Target>
|
||||
|
||||
<Import Project="$(BuildCommonDirectory)common.targets"/>
|
||||
--
|
||||
2.31.1
|
||||
|
|
@ -1,46 +0,0 @@
|
|||
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
||||
From: Chris Rummel <crummel@microsoft.com>
|
||||
Date: Wed, 21 Jul 2021 17:33:03 -0500
|
||||
Subject: [PATCH] Update Microsoft.Extensions.CommandLineUtils reference
|
||||
|
||||
Microsoft.Extensions.CommandLineUtils is obsolete and no longer being built. Because of this it can't be source-built.
|
||||
Microsoft.Extensions.CommandLineUtils.Sources is handled as a text-only SBRP.
|
||||
---
|
||||
build/packages.targets | 3 ++-
|
||||
.../NuGet.CommandLine.XPlat/NuGet.CommandLine.XPlat.csproj | 2 +-
|
||||
2 files changed, 3 insertions(+), 2 deletions(-)
|
||||
|
||||
diff --git a/build/packages.targets b/build/packages.targets
|
||||
index 614a0ca68..f6be9619e 100644
|
||||
--- a/build/packages.targets
|
||||
+++ b/build/packages.targets
|
||||
@@ -8,6 +8,7 @@
|
||||
<CryptographyPackagesVersion>5.0.0</CryptographyPackagesVersion>
|
||||
<NuGetCoreV2Version>2.14.0-rtm-832</NuGetCoreV2Version>
|
||||
<ProjectSystemManagedVersion>17.0.0-beta1-10402-05</ProjectSystemManagedVersion>
|
||||
+ <MicrosoftExtensionsCommandLineUtilsSourcesPackageVersion Condition="'$(MicrosoftExtensionsCommandLineUtilsSourcesPackageVersion)' == ''">5.0.1-rtm.21063.7</MicrosoftExtensionsCommandLineUtilsSourcesPackageVersion>
|
||||
</PropertyGroup>
|
||||
|
||||
<!-- Test and package versions -->
|
||||
@@ -31,7 +32,7 @@
|
||||
<PackageReference Update="Microsoft.Build.Utilities.Core" Version="$(MicrosoftBuildPackageVersion)" />
|
||||
<PackageReference Update="Microsoft.CodeAnalysis.FxCopAnalyzers" Version="2.9.8" />
|
||||
<PackageReference Update="Microsoft.DataAI.NuGetRecommender.Contracts" Version="2.1.0" />
|
||||
- <PackageReference Update="Microsoft.Extensions.CommandLineUtils" Version="1.0.1" />
|
||||
+ <PackageReference Update="Microsoft.Extensions.CommandLineUtils.Sources" Version="$(MicrosoftExtensionsCommandLineUtilsSourcesPackageVersion)" />
|
||||
<PackageReference Update="Microsoft.Internal.VisualStudio.Shell.Framework" Version="$(VSFrameworkVersion)" />
|
||||
<PackageReference Update="Microsoft.SourceLink.GitHub" Version="1.0.0" />
|
||||
<PackageReference Update="Microsoft.TeamFoundationServer.ExtendedClient" Version="$(VSServicesVersion)" />
|
||||
diff --git a/src/NuGet.Core/NuGet.CommandLine.XPlat/NuGet.CommandLine.XPlat.csproj b/src/NuGet.Core/NuGet.CommandLine.XPlat/NuGet.CommandLine.XPlat.csproj
|
||||
index 21015c00a..e306cdee4 100644
|
||||
--- a/src/NuGet.Core/NuGet.CommandLine.XPlat/NuGet.CommandLine.XPlat.csproj
|
||||
+++ b/src/NuGet.Core/NuGet.CommandLine.XPlat/NuGet.CommandLine.XPlat.csproj
|
||||
@@ -18,7 +18,7 @@
|
||||
</ItemGroup>
|
||||
|
||||
<ItemGroup>
|
||||
- <PackageReference Include="Microsoft.Extensions.CommandLineUtils" />
|
||||
+ <PackageReference Include="Microsoft.Extensions.CommandLineUtils.Sources" />
|
||||
<PackageReference Include="System.Diagnostics.Debug" />
|
||||
</ItemGroup>
|
||||
|
|
@ -1,4 +1,4 @@
|
|||
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
||||
From d1fd2aa5e216e49f9da38b0000d006184c540ff2 Mon Sep 17 00:00:00 2001
|
||||
From: Joey Robichaud <jorobich@microsoft.com>
|
||||
Date: Wed, 20 Oct 2021 13:40:38 -0700
|
||||
Subject: [PATCH] Add Features projects to SourceBuild
|
||||
|
@ -10,22 +10,20 @@ Subject: [PATCH] Add Features projects to SourceBuild
|
|||
.../Microsoft.Build.Tasks.CodeAnalysis.csproj | 6 +++---
|
||||
...ft.Build.Tasks.CodeAnalysis.UnitTests.csproj | 6 +++---
|
||||
.../Extension/Roslyn.Compilers.Extension.csproj | 6 +++---
|
||||
...icrosoft.CodeAnalysis.CSharp.Features.csproj | 5 +++++
|
||||
.../Microsoft.CodeAnalysis.Features.csproj | 10 ++++++++--
|
||||
.../LanguageServer/Directory.Build.props | 6 ++++++
|
||||
src/Features/Lsif/Directory.Build.props | 6 ++++++
|
||||
...oft.CodeAnalysis.VisualBasic.Features.vbproj | 4 ++++
|
||||
src/NuGet/VisualStudio/Directory.Build.props | 6 ++++++
|
||||
.../Microsoft.CodeAnalysis.Features.csproj | 2 +-
|
||||
.../{ => LanguageServer}/Directory.Build.props | 0
|
||||
src/Features/{ => Lsif}/Directory.Build.props | 0
|
||||
.../VisualStudio}/Directory.Build.props | 0
|
||||
src/Tools/AnalyzerRunner/AnalyzerRunner.csproj | 2 +-
|
||||
src/Tools/BuildBoss/ProjectCheckerUtil.cs | 7 ++++---
|
||||
.../IdeCoreBenchmarks/IdeCoreBenchmarks.csproj | 2 +-
|
||||
...osoft.CodeAnalysis.Workspaces.MSBuild.csproj | 8 +++-----
|
||||
...Analysis.Workspaces.MSBuild.UnitTests.csproj | 4 ++--
|
||||
17 files changed, 68 insertions(+), 29 deletions(-)
|
||||
rename src/{Features => CodeStyle/Core/Tests}/Directory.Build.props (100%)
|
||||
create mode 100644 src/Features/LanguageServer/Directory.Build.props
|
||||
create mode 100644 src/Features/Lsif/Directory.Build.props
|
||||
create mode 100644 src/NuGet/VisualStudio/Directory.Build.props
|
||||
15 files changed, 34 insertions(+), 28 deletions(-)
|
||||
copy src/{Features => CodeStyle/Core/Tests}/Directory.Build.props (100%)
|
||||
copy src/Features/{ => LanguageServer}/Directory.Build.props (100%)
|
||||
copy src/Features/{ => Lsif}/Directory.Build.props (100%)
|
||||
rename src/{Features => NuGet/VisualStudio}/Directory.Build.props (100%)
|
||||
|
||||
diff --git a/eng/SourceBuild.props b/eng/SourceBuild.props
|
||||
index 182f8a9cdb1..92e316a4744 100644
|
||||
|
@ -41,7 +39,7 @@ index 182f8a9cdb1..92e316a4744 100644
|
|||
</Target>
|
||||
|
||||
diff --git a/eng/Versions.props b/eng/Versions.props
|
||||
index e835ef04d52..34cab5c4755 100644
|
||||
index 679e77c5e19..96b3981a12c 100644
|
||||
--- a/eng/Versions.props
|
||||
+++ b/eng/Versions.props
|
||||
@@ -38,7 +38,7 @@
|
||||
|
@ -78,8 +76,8 @@ index e835ef04d52..34cab5c4755 100644
|
|||
<!--
|
||||
diff --git a/src/Features/Directory.Build.props b/src/CodeStyle/Core/Tests/Directory.Build.props
|
||||
similarity index 100%
|
||||
rename from src/Features/Directory.Build.props
|
||||
rename to src/CodeStyle/Core/Tests/Directory.Build.props
|
||||
copy from src/Features/Directory.Build.props
|
||||
copy to src/CodeStyle/Core/Tests/Directory.Build.props
|
||||
diff --git a/src/Compilers/Core/MSBuildTask/Microsoft.Build.Tasks.CodeAnalysis.csproj b/src/Compilers/Core/MSBuildTask/Microsoft.Build.Tasks.CodeAnalysis.csproj
|
||||
index 8c6bb122fb2..cc743d09032 100644
|
||||
--- a/src/Compilers/Core/MSBuildTask/Microsoft.Build.Tasks.CodeAnalysis.csproj
|
||||
|
@ -138,24 +136,8 @@ index 3644afb8c2f..ed4259ec61b 100644
|
|||
<PackageReference Include="Microsoft.VisualStudio.SDK.Analyzers" Version="$(MicrosoftVisualStudioSDKAnalyzersVersion)" PrivateAssets="all" />
|
||||
<PackageReference Include="Microsoft.VisualStudio.Threading" Version="$(MicrosoftVisualStudioThreadingVersion)" />
|
||||
<PackageReference Include="Microsoft.VisualStudio.Validation" Version="$(MicrosoftVisualStudioValidationVersion)" />
|
||||
diff --git a/src/Features/CSharp/Portable/Microsoft.CodeAnalysis.CSharp.Features.csproj b/src/Features/CSharp/Portable/Microsoft.CodeAnalysis.CSharp.Features.csproj
|
||||
index a82a820316c..9dac307c856 100644
|
||||
--- a/src/Features/CSharp/Portable/Microsoft.CodeAnalysis.CSharp.Features.csproj
|
||||
+++ b/src/Features/CSharp/Portable/Microsoft.CodeAnalysis.CSharp.Features.csproj
|
||||
@@ -60,6 +60,11 @@
|
||||
<Link>InternalUtilities\LambdaUtilities.cs</Link>
|
||||
</Compile>
|
||||
</ItemGroup>
|
||||
+ <ItemGroup>
|
||||
+ <Compile Remove="EditAndContinue\**\*.cs" Condition="'$(DotNetBuildFromSource)' == 'true'" />
|
||||
+ <Compile Include="EditAndContinue\BreakpointSpans.cs" Condition="'$(DotNetBuildFromSource)' == 'true'" />
|
||||
+ <Compile Include="EditAndContinue\SyntaxUtilities.cs" Condition="'$(DotNetBuildFromSource)' == 'true'" />
|
||||
+ </ItemGroup>
|
||||
<ItemGroup>
|
||||
<EmbeddedResource Update="CSharpFeaturesResources.resx" GenerateSource="true" />
|
||||
</ItemGroup>
|
||||
diff --git a/src/Features/Core/Portable/Microsoft.CodeAnalysis.Features.csproj b/src/Features/Core/Portable/Microsoft.CodeAnalysis.Features.csproj
|
||||
index 1af351cc77b..943443c55bc 100644
|
||||
index 1af351cc77b..8ecad0bac56 100644
|
||||
--- a/src/Features/Core/Portable/Microsoft.CodeAnalysis.Features.csproj
|
||||
+++ b/src/Features/Core/Portable/Microsoft.CodeAnalysis.Features.csproj
|
||||
@@ -7,7 +7,7 @@
|
||||
|
@ -167,72 +149,18 @@ index 1af351cc77b..943443c55bc 100644
|
|||
<!-- NuGet -->
|
||||
<IsPackable>true</IsPackable>
|
||||
<PackageDescription>
|
||||
@@ -129,7 +129,13 @@
|
||||
<PackageReference Include="System.Threading.Tasks.Extensions" Version="$(SystemThreadingTasksExtensionsVersion)" />
|
||||
<PackageReference Include="Microsoft.DiaSymReader" Version="$(MicrosoftDiaSymReaderVersion)" />
|
||||
<PackageReference Include="Microsoft.CodeAnalysis.AnalyzerUtilities" Version="$(MicrosoftCodeAnalysisAnalyzerUtilitiesVersion)" />
|
||||
- <PackageReference Include="Microsoft.VisualStudio.Debugger.Contracts" Version="$(MicrosoftVisualStudioDebuggerContractsVersion)" />
|
||||
+ <PackageReference Include="Microsoft.VisualStudio.Debugger.Contracts" Version="$(MicrosoftVisualStudioDebuggerContractsVersion)" Condition="'$(DotNetBuildFromSource)' != 'true'" />
|
||||
+ </ItemGroup>
|
||||
+ <ItemGroup>
|
||||
+ <Compile Remove="EditAndContinue\**\*.cs" Condition="'$(DotNetBuildFromSource)' == 'true'" />
|
||||
+ <Compile Include="EditAndContinue\EditAndContinueMethodDebugInfoReader.cs" Condition="'$(DotNetBuildFromSource)' == 'true'" />
|
||||
+ <Compile Remove="ExternalAccess\UnitTesting\API\UnitTestingHotReloadService.cs" Condition="'$(DotNetBuildFromSource)' == 'true'" />
|
||||
+ <Compile Remove="ExternalAccess\Watch\Api\WatchHotReloadService.cs" Condition="'$(DotNetBuildFromSource)' == 'true'" />
|
||||
</ItemGroup>
|
||||
<Import Project="..\..\..\Compilers\Core\AnalyzerDriver\AnalyzerDriver.projitems" Label="Shared" />
|
||||
<Import Project="..\..\..\Dependencies\CodeAnalysis.Debugging\Microsoft.CodeAnalysis.Debugging.projitems" Label="Shared" />
|
||||
diff --git a/src/Features/LanguageServer/Directory.Build.props b/src/Features/LanguageServer/Directory.Build.props
|
||||
new file mode 100644
|
||||
index 00000000000..6eef643958f
|
||||
--- /dev/null
|
||||
+++ b/src/Features/LanguageServer/Directory.Build.props
|
||||
@@ -0,0 +1,6 @@
|
||||
+<Project>
|
||||
+ <Import Project="$([MSBuild]::GetPathOfFileAbove('Directory.Build.props', '$(MSBuildThisFileDirectory)../'))" />
|
||||
+ <PropertyGroup>
|
||||
+ <ExcludeFromSourceBuild>true</ExcludeFromSourceBuild>
|
||||
+ </PropertyGroup>
|
||||
+</Project>
|
||||
diff --git a/src/Features/Lsif/Directory.Build.props b/src/Features/Lsif/Directory.Build.props
|
||||
new file mode 100644
|
||||
index 00000000000..6eef643958f
|
||||
--- /dev/null
|
||||
+++ b/src/Features/Lsif/Directory.Build.props
|
||||
@@ -0,0 +1,6 @@
|
||||
+<Project>
|
||||
+ <Import Project="$([MSBuild]::GetPathOfFileAbove('Directory.Build.props', '$(MSBuildThisFileDirectory)../'))" />
|
||||
+ <PropertyGroup>
|
||||
+ <ExcludeFromSourceBuild>true</ExcludeFromSourceBuild>
|
||||
+ </PropertyGroup>
|
||||
+</Project>
|
||||
diff --git a/src/Features/VisualBasic/Portable/Microsoft.CodeAnalysis.VisualBasic.Features.vbproj b/src/Features/VisualBasic/Portable/Microsoft.CodeAnalysis.VisualBasic.Features.vbproj
|
||||
index ac8c80c68fb..d17a5d84802 100644
|
||||
--- a/src/Features/VisualBasic/Portable/Microsoft.CodeAnalysis.VisualBasic.Features.vbproj
|
||||
+++ b/src/Features/VisualBasic/Portable/Microsoft.CodeAnalysis.VisualBasic.Features.vbproj
|
||||
@@ -55,6 +55,10 @@
|
||||
<Link>InternalUtilities\LambdaUtilities.vb</Link>
|
||||
</Compile>
|
||||
</ItemGroup>
|
||||
+ <ItemGroup>
|
||||
+ <Compile Remove="EditAndContinue\**\*.vb" Condition="'$(DotNetBuildFromSource)' == 'true'" />
|
||||
+ <Compile Include="EditAndContinue\BreakpointSpans.vb" Condition="'$(DotNetBuildFromSource)' == 'true'" />
|
||||
+ </ItemGroup>
|
||||
<ItemGroup>
|
||||
<EmbeddedResource Update="VBFeaturesResources.resx" GenerateSource="true" Namespace="Microsoft.CodeAnalysis.VisualBasic" />
|
||||
</ItemGroup>
|
||||
diff --git a/src/NuGet/VisualStudio/Directory.Build.props b/src/NuGet/VisualStudio/Directory.Build.props
|
||||
new file mode 100644
|
||||
index 00000000000..6eef643958f
|
||||
--- /dev/null
|
||||
+++ b/src/NuGet/VisualStudio/Directory.Build.props
|
||||
@@ -0,0 +1,6 @@
|
||||
+<Project>
|
||||
+ <Import Project="$([MSBuild]::GetPathOfFileAbove('Directory.Build.props', '$(MSBuildThisFileDirectory)../'))" />
|
||||
+ <PropertyGroup>
|
||||
+ <ExcludeFromSourceBuild>true</ExcludeFromSourceBuild>
|
||||
+ </PropertyGroup>
|
||||
+</Project>
|
||||
diff --git a/src/Features/Directory.Build.props b/src/Features/LanguageServer/Directory.Build.props
|
||||
similarity index 100%
|
||||
copy from src/Features/Directory.Build.props
|
||||
copy to src/Features/LanguageServer/Directory.Build.props
|
||||
diff --git a/src/Features/Directory.Build.props b/src/Features/Lsif/Directory.Build.props
|
||||
similarity index 100%
|
||||
copy from src/Features/Directory.Build.props
|
||||
copy to src/Features/Lsif/Directory.Build.props
|
||||
diff --git a/src/Features/Directory.Build.props b/src/NuGet/VisualStudio/Directory.Build.props
|
||||
similarity index 100%
|
||||
rename from src/Features/Directory.Build.props
|
||||
rename to src/NuGet/VisualStudio/Directory.Build.props
|
||||
diff --git a/src/Tools/AnalyzerRunner/AnalyzerRunner.csproj b/src/Tools/AnalyzerRunner/AnalyzerRunner.csproj
|
||||
index 6e1cbe46285..8ca3cbb28f0 100644
|
||||
--- a/src/Tools/AnalyzerRunner/AnalyzerRunner.csproj
|
||||
|
@ -332,3 +260,6 @@ index 3d0c6e993c0..06773c65e8d 100644
|
|||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<Reference Include="System.Xaml">
|
||||
--
|
||||
2.31.1
|
||||
|
||||
|
|
Loading…
Reference in a new issue