Merge branch 'release/6.0.1xx' into main

This commit is contained in:
Jason Zhai 2021-10-28 23:16:31 -07:00
commit 3d723365aa
69 changed files with 1834 additions and 640 deletions

View file

@ -186,9 +186,10 @@
<Uri>https://github.com/dotnet/arcade</Uri> <Uri>https://github.com/dotnet/arcade</Uri>
<Sha>32ff2e3f45ae8fefed72a93ca17f4b01e106c7c9</Sha> <Sha>32ff2e3f45ae8fefed72a93ca17f4b01e106c7c9</Sha>
</Dependency> </Dependency>
<Dependency Name="Private.SourceBuild.ReferencePackages" Version="1.0.0-beta.20217.1"> <Dependency Name="Microsoft.SourceBuild.Intermediate.source-build-reference-packages" Version="6.0.0-alpha.1.21521.1">
<Uri>https://github.com/dotnet/source-build-reference-packages</Uri> <Uri>https://github.com/dotnet/source-build-reference-packages</Uri>
<Sha>639aeb4d76c8b1a6226bf7c4edb34fbdae30e6e1</Sha> <Sha>fc184172bf8144f7c91a7bc0226b7d90c5821576</Sha>
<SourceBuildTarball RepoName="source-build-reference-packages" ManagedOnly="true" />
</Dependency> </Dependency>
<Dependency Name="Microsoft.SourceLink.GitHub" Version="1.1.0-beta-21525-02" CoherentParentDependency="Microsoft.DotNet.Arcade.Sdk"> <Dependency Name="Microsoft.SourceLink.GitHub" Version="1.1.0-beta-21525-02" CoherentParentDependency="Microsoft.DotNet.Arcade.Sdk">
<Uri>https://github.com/dotnet/sourcelink</Uri> <Uri>https://github.com/dotnet/sourcelink</Uri>

View file

@ -162,8 +162,20 @@
removed. See https://github.com/dotnet/source-build/issues/2295 --> removed. See https://github.com/dotnet/source-build/issues/2295 -->
<MicrosoftBuildFrameworkVersion>15.7.179</MicrosoftBuildFrameworkVersion> <MicrosoftBuildFrameworkVersion>15.7.179</MicrosoftBuildFrameworkVersion>
<MicrosoftBuildUtilitiesCoreVersion>15.7.179</MicrosoftBuildUtilitiesCoreVersion> <MicrosoftBuildUtilitiesCoreVersion>15.7.179</MicrosoftBuildUtilitiesCoreVersion>
<PrivateSourceBuiltArtifactsPackageVersion>0.1.0-6.0.100-bootstrap.11</PrivateSourceBuiltArtifactsPackageVersion> <!--
<PrivateSourceBuiltPrebuiltsPackageVersion>0.1.0-6.0.100-19</PrivateSourceBuiltPrebuiltsPackageVersion> Building .NET from source depends on one or two tar.gz files depending on the branch's current
source-buildability status.
PrivateSourceBuiltArtifactsPackageVersion is a tar.gz of .NET build outputs from a previous
build needed to build the current version of .NET. This is always defined, because .NET needs
to be bootstrappable at any point in time.
PrivateSourceBuiltPrebuiltsPackageVersion is a tar.gz of assets downloaded from the internet
that are needed to build the current version of .NET. Early in the lifecycle of a .NET major
or minor release, prebuilts may be needed. When the release is mature, prebuilts are not
necessary, and this property is removed from the file.
-->
<PrivateSourceBuiltArtifactsPackageVersion>0.1.0-6.0.100-bootstrap.29</PrivateSourceBuiltArtifactsPackageVersion>
</PropertyGroup> </PropertyGroup>
<!-- Workload manifest package versions --> <!-- Workload manifest package versions -->
<PropertyGroup> <PropertyGroup>

View file

@ -248,6 +248,20 @@
</ItemGroup> </ItemGroup>
<Delete Files="@(TarballSrcBinaryToRemove)" /> <Delete Files="@(TarballSrcBinaryToRemove)" />
<!-- We have some not-strictly-required files that are under non-open source licenses.
See https://github.com/dotnet/source-build/issues/2359.
Remove them. -->
<ItemGroup>
<TarballSrcNonOpenSourceFiles Include="$(TarballSourceDir)**\humanizer\samples\**\*.js" />
<TarballSrcNonOpenSourceFiles Include="$(TarballSourceDir)**\*nuget-client.*\**\EndToEnd\**\jquery-validation-unobtrusive\*.js" />
<TarballSrcNonOpenSourceFiles Include="$(TarballSourceDir)**\*nuget-client.*\**\EndToEnd\**\jquery-validation-unobtrusive\.bower.json" />
<TarballSrcNonOpenSourceFiles Include="$(TarballSourceDir)**\*aspnetcore.*\**\samples\**\jquery-validation-unobtrusive\.bower.json" />
<TarballSrcNonOpenSourceFiles Include="$(TarballSourceDir)**\*aspnetcore.*\**\samples\**\jquery-validation-unobtrusive\*.js" />
</ItemGroup>
<Message Importance="High" Text="Deleting files with questionable licenses: @(TarballSrcNonOpenSourceFiles, ' ')" />
<Delete Files="@(TarballSrcNonOpenSourceFiles)" />
</Target> </Target>
<Target Name="RestoreTextOnlyPackages"> <Target Name="RestoreTextOnlyPackages">
@ -294,7 +308,9 @@
<ItemGroup> <ItemGroup>
<ArtifactUrls Include="$(SourceBuiltArtifactsTarballUrl)$(SourceBuiltArtifactsTarballName).$(PrivateSourceBuiltArtifactsPackageVersion).tar.gz" /> <ArtifactUrls Include="$(SourceBuiltArtifactsTarballUrl)$(SourceBuiltArtifactsTarballName).$(PrivateSourceBuiltArtifactsPackageVersion).tar.gz" />
<ArtifactUrls Include="$(SourceBuiltArtifactsTarballUrl)$(SourceBuiltPrebuiltsTarballName).$(PrivateSourceBuiltPrebuiltsPackageVersion).tar.gz" /> <ArtifactUrls
Include="$(SourceBuiltArtifactsTarballUrl)$(SourceBuiltPrebuiltsTarballName).$(PrivateSourceBuiltPrebuiltsPackageVersion).tar.gz"
Condition="'$(PrivateSourceBuiltPrebuiltsPackageVersion)' != ''" />
</ItemGroup> </ItemGroup>
<WriteLinesToFile <WriteLinesToFile

View file

@ -133,8 +133,22 @@
</Target> </Target>
<Target Name="CreatePrebuiltsTarball" <Target Name="CreatePrebuiltsTarball"
AfterTargets="Build"> AfterTargets="Build"
DependsOnTargets="
CheckIfPrebuiltsExistToPack;
CreatePrebuiltsTarballIfPrebuiltsExist"/>
<Target Name="CheckIfPrebuiltsExistToPack">
<!-- Directory existence doesn't mean there are files inside. Use a pattern to find files. -->
<ItemGroup>
<PrebuiltFile Include="$(ResultingPrebuiltPackagesDir)**" />
</ItemGroup>
<Message Text="Found @(PrebuiltFile->Count()) files in prebuilt packages dir." Importance="High" />
</Target>
<Target Name="CreatePrebuiltsTarballIfPrebuiltsExist"
Condition="'@(PrebuiltFile->Count())' != '0'">
<PropertyGroup> <PropertyGroup>
<TarballFileVersion>$(PrivateSourceBuiltPrebuiltsPackageVersionPrefix)$([MSBuild]::Add($(PrivateSourceBuiltPrebuiltsPackageVersionSuffix), 1))</TarballFileVersion> <TarballFileVersion>$(PrivateSourceBuiltPrebuiltsPackageVersionPrefix)$([MSBuild]::Add($(PrivateSourceBuiltPrebuiltsPackageVersionSuffix), 1))</TarballFileVersion>
<TarballFilePath>$(OutputPath)$(SourceBuiltPrebuiltsTarballName).$(TarballFileVersion).tar.gz</TarballFilePath> <TarballFilePath>$(OutputPath)$(SourceBuiltPrebuiltsTarballName).$(TarballFileVersion).tar.gz</TarballFilePath>

View file

@ -22,6 +22,6 @@
<!-- Production Dependencies --> <!-- Production Dependencies -->
<PropertyGroup> <PropertyGroup>
<PrivateSourceBuiltPrebuiltsPackageVersionPrefix>0.1.0-6.0.100-</PrivateSourceBuiltPrebuiltsPackageVersionPrefix> <PrivateSourceBuiltPrebuiltsPackageVersionPrefix>0.1.0-6.0.100-</PrivateSourceBuiltPrebuiltsPackageVersionPrefix>
<PrivateSourceBuiltPrebuiltsPackageVersionSuffix>30</PrivateSourceBuiltPrebuiltsPackageVersionSuffix> <PrivateSourceBuiltPrebuiltsPackageVersionSuffix>36</PrivateSourceBuiltPrebuiltsPackageVersionSuffix>
</PropertyGroup> </PropertyGroup>
</Project> </Project>

View file

@ -151,6 +151,7 @@
<ArcadeBootstrapSdkOverride Include="Microsoft.DotNet.Arcade.Sdk" Group="ARCADE" Version="$(ArcadeBootstrapVersion)" Location="$(ArcadeBootstrapDir)microsoft.dotnet.arcade.sdk/$(ArcadeBootstrapVersion)" /> <ArcadeBootstrapSdkOverride Include="Microsoft.DotNet.Arcade.Sdk" Group="ARCADE" Version="$(ArcadeBootstrapVersion)" Location="$(ArcadeBootstrapDir)microsoft.dotnet.arcade.sdk/$(ArcadeBootstrapVersion)" />
<ArcadePackagingOverride Include="Microsoft.DotNet.Build.Tasks.Packaging" Group="ARCADE_PACKAGING" Version="$(arcadeOutputPackageVersion)"/> <ArcadePackagingOverride Include="Microsoft.DotNet.Build.Tasks.Packaging" Group="ARCADE_PACKAGING" Version="$(arcadeOutputPackageVersion)"/>
<ArcadeTargetFrameworkSdkOverride Include="Microsoft.DotNet.Build.Tasks.TargetFramework.Sdk" Group="ARCADE_TGT_FX_SDK" Version="$(arcadeOutputPackageVersion)"/> <ArcadeTargetFrameworkSdkOverride Include="Microsoft.DotNet.Build.Tasks.TargetFramework.Sdk" Group="ARCADE_TGT_FX_SDK" Version="$(arcadeOutputPackageVersion)"/>
<ArcadeSharedFrameworkSdkOverride Include="Microsoft.DotNet.SharedFramework.Sdk" Group="ARCADE_SHARED_FX_SDK" Version="$(arcadeOutputPackageVersion)"/>
<ILSdkOverride Include="Microsoft.NET.Sdk.IL" Group="IL" /> <ILSdkOverride Include="Microsoft.NET.Sdk.IL" Group="IL" />
<MsBuildTraversalSdkOverride Include="Microsoft.Build.Traversal" Group="MSBUILD_TRAVERSAL" Version="2.0.2"/> <MsBuildTraversalSdkOverride Include="Microsoft.Build.Traversal" Group="MSBUILD_TRAVERSAL" Version="2.0.2"/>
</ItemGroup> </ItemGroup>

View file

@ -25,6 +25,7 @@
<BuiltSdkPackageOverride Include="@(ArcadeCoreFxTestingOverride)" /> <BuiltSdkPackageOverride Include="@(ArcadeCoreFxTestingOverride)" />
<BuiltSdkPackageOverride Include="@(ArcadePackagingOverride)" /> <BuiltSdkPackageOverride Include="@(ArcadePackagingOverride)" />
<BuiltSdkPackageOverride Include="@(ArcadeTargetFrameworkSdkOverride)" /> <BuiltSdkPackageOverride Include="@(ArcadeTargetFrameworkSdkOverride)" />
<BuiltSdkPackageOverride Include="@(ArcadeSharedFrameworkSdkOverride)" />
</ItemGroup> </ItemGroup>
<ItemGroup> <ItemGroup>
@ -32,33 +33,13 @@
<EnvironmentVariables Include="useInstalledDotNetCli=false" /> <EnvironmentVariables Include="useInstalledDotNetCli=false" />
</ItemGroup> </ItemGroup>
<ItemGroup>
<ExtraPackageVersionPropsPackageInfo Include="NuGetVersion" Version="%24(NuGetPackagingVersion)" />
</ItemGroup>
<ItemGroup> <ItemGroup>
<RepositoryReference Include="sourcelink" /> <RepositoryReference Include="sourcelink" />
</ItemGroup> </ItemGroup>
<!-- TODO: Temporarily skip this target for now until source-build NuGet packaging is built
and packaged into source-built artifacts for 6.0.
See https://github.com/dotnet/source-build/issues/2285 -->
<Target Name="UsePreviouslySourceBuiltNuGet"
Condition=" 'true' == 'false' "
BeforeTargets="RepoBuild">
<ItemGroup>
<PreviouslySourceBuiltNuGetPackageFile Include="$(PrebuiltSourceBuiltPackagesPath)NuGet.Packaging.*.nupkg" />
</ItemGroup>
<Error
Text="Unable to find any previously source built NuGet.Packaging version to use in Arcade SDK tooling."
Condition="'@(PreviouslySourceBuiltNuGetPackageFile)' == ''" />
<ReadNuGetPackageInfos PackagePaths="@(PreviouslySourceBuiltNuGetPackageFile)">
<Output TaskParameter="PackageInfoItems" ItemName="PreviouslySourceBuiltNuGetPackageInfo" />
</ReadNuGetPackageInfos>
<PropertyGroup>
<PreviouslySourceBuiltNuGetVersion>%(PreviouslySourceBuiltNuGetPackageInfo.PackageVersion)</PreviouslySourceBuiltNuGetVersion>
<BuildCommand>$(BuildCommand) /p:NuGetVersion=$(PreviouslySourceBuiltNuGetVersion)</BuildCommand>
</PropertyGroup>
</Target>
<Import Project="Sdk.targets" Sdk="Microsoft.NET.Sdk" /> <Import Project="Sdk.targets" Sdk="Microsoft.NET.Sdk" />
</Project> </Project>

View file

@ -23,6 +23,18 @@
<NuGetConfigFile>$(ProjectDirectory)NuGet.config</NuGetConfigFile> <NuGetConfigFile>$(ProjectDirectory)NuGet.config</NuGetConfigFile>
</PropertyGroup> </PropertyGroup>
<ItemGroup>
<!--
From aspnetcore Versions.props:
Versions of Microsoft.CodeAnalysis packages referenced by analyzers shipped in the SDK.
This need to be pinned since they're used in 3.1 apps and need to be loadable in VS 2019.
In source-build these don't need to be pinned and can use the source-built versions since it doesn't
need to support VS 2019.
-->
<ExtraPackageVersionPropsPackageInfo Include="Analyzer_MicrosoftCodeAnalysisCSharpVersion" Version="%24(MicrosoftCodeAnalysisCSharpVersion)" />
<ExtraPackageVersionPropsPackageInfo Include="Analyzer_MicrosoftCodeAnalysisCSharpWorkspacesVersion" Version="%24(MicrosoftCodeAnalysisCSharpWorkspacesVersion)" />
</ItemGroup>
<ItemGroup> <ItemGroup>
<RepositoryReference Include="arcade" /> <RepositoryReference Include="arcade" />
<RepositoryReference Include="source-build" /> <RepositoryReference Include="source-build" />

View file

@ -0,0 +1,23 @@
<Project>
<Import Project="Sdk.props" Sdk="Microsoft.NET.Sdk" />
<PropertyGroup>
<BuildCommand>$(ProjectDirectory)eng\common\build$(ShellExtension) $(StandardSourceBuildArgs)</BuildCommand>
<GlobalJsonFile>$(ProjectDirectory)global.json</GlobalJsonFile>
<NuGetConfigFile>$(ProjectDirectory)NuGet.config</NuGetConfigFile>
<OutputPlacementRepoApiImplemented>false</OutputPlacementRepoApiImplemented>
</PropertyGroup>
<ItemGroup>
<RepositoryReference Include="roslyn" />
<RepositoryReference Include="roslyn-analyzers" />
<RepositoryReference Include="source-build" />
</ItemGroup>
<ItemGroup>
<UseSourceBuiltSdkOverride Include="@(ArcadeSdkOverride)" />
</ItemGroup>
<Import Project="Sdk.targets" Sdk="Microsoft.NET.Sdk" />
</Project>

View file

@ -4,6 +4,12 @@
<PropertyGroup> <PropertyGroup>
<BuildCommandArgs>$(StandardSourceBuildArgs)</BuildCommandArgs> <BuildCommandArgs>$(StandardSourceBuildArgs)</BuildCommandArgs>
<BuildCommandArgs>$(BuildCommandArgs) /p:TreatWarningsAsErrors=false</BuildCommandArgs> <BuildCommandArgs>$(BuildCommandArgs) /p:TreatWarningsAsErrors=false</BuildCommandArgs>
<!--
dotnet/fsharp has a custom eng/build.sh script that handles its own sourcebuild arg
differently from the ArcadeBuildFromSource MSBuild arg. Including both args is fine, but the
custom sourcebuild arg is the one that's required. This avoids running bootstrapping twice.
-->
<BuildCommandArgs>$(BuildCommandArgs) --sourcebuild</BuildCommandArgs>
<BuildCommand>$(StandardSourceBuildCommand) $(BuildCommandArgs)</BuildCommand> <BuildCommand>$(StandardSourceBuildCommand) $(BuildCommandArgs)</BuildCommand>
<OutputPlacementRepoApiImplemented>false</OutputPlacementRepoApiImplemented> <OutputPlacementRepoApiImplemented>false</OutputPlacementRepoApiImplemented>

View file

@ -54,6 +54,7 @@
<!-- Tier 4 --> <!-- Tier 4 -->
<RepositoryReference Include="aspnetcore" /> <RepositoryReference Include="aspnetcore" />
<RepositoryReference Include="deployment-tools" /> <RepositoryReference Include="deployment-tools" />
<RepositoryReference Include="format" />
<RepositoryReference Include="nuget-client" /> <RepositoryReference Include="nuget-client" />
<!-- Tier 5 --> <!-- Tier 5 -->

View file

@ -2,12 +2,8 @@
<Import Project="Sdk.props" Sdk="Microsoft.NET.Sdk" /> <Import Project="Sdk.props" Sdk="Microsoft.NET.Sdk" />
<PropertyGroup> <PropertyGroup>
<!-- roslyn-analyzers does not want to build with the source build packages as this more closely mimics their repo build. <BuildCommandArgs>$(StandardSourceBuildArgs)</BuildCommandArgs>
To make this easier, the use of DotNetPackageVersionPropsPath is disabled and its versions.props explicitly imports
$(SourceBuildPackageVersionPropsPath) at the beginning. -->
<BuildCommandArgs>$(StandardSourceBuildArgs.Replace('/p:DotNetPackageVersionPropsPath="$(PackageVersionPropsPath)"', ''))</BuildCommandArgs>
<BuildCommandArgs>$(BuildCommandArgs) $(FlagParameterPrefix)warnAsError $(ArcadeFalseBoolBuildArg)</BuildCommandArgs> <BuildCommandArgs>$(BuildCommandArgs) $(FlagParameterPrefix)warnAsError $(ArcadeFalseBoolBuildArg)</BuildCommandArgs>
<BuildCommandArgs>$(BuildCommandArgs) /p:SourceBuildPackageVersionPropsPath="$(PackageVersionPropsPath)"</BuildCommandArgs>
<BuildCommand>$(StandardSourceBuildCommand) $(BuildCommandArgs)</BuildCommand> <BuildCommand>$(StandardSourceBuildCommand) $(BuildCommandArgs)</BuildCommand>
<RepoApiImplemented>false</RepoApiImplemented> <RepoApiImplemented>false</RepoApiImplemented>

View file

@ -19,6 +19,23 @@
<GlobalJsonFile>$(ProjectDirectory)global.json</GlobalJsonFile> <GlobalJsonFile>$(ProjectDirectory)global.json</GlobalJsonFile>
</PropertyGroup> </PropertyGroup>
<ItemGroup>
<!--
From roslyn Versions.props:
The version of Roslyn we build Source Generators against that are built in this
repository. This must be lower than MicrosoftNetCompilersToolsetVersion,
but not higher than our minimum dogfoodable Visual Studio version, or else
the generators we build would load on the command line but not load in IDEs.
In source-build these don't need to be pinned and can use the source-built versions since it doesn't
need to support VS.
-->
<ExtraPackageVersionPropsPackageInfo Include="SourceGeneratorMicrosoftCodeAnalysisVersion" Version="%24(MicrosoftCodeAnalysisCommonVersion)" />
<ExtraPackageVersionPropsPackageInfo Include="SourceBuildLiftedSystemCollectionsImmutableVersion" Version="%24(SystemCollectionsImmutableVersion)" />
<ExtraPackageVersionPropsPackageInfo Include="SourceBuildLiftedSystemReflectionMetadataVersion" Version="%24(SystemReflectionMetadataVersion)" />
<ExtraPackageVersionPropsPackageInfo Include="SourceBuildLiftedSystemRuntimeCompilerServicesUnsafeVersion" Version="%24(SystemRuntimeCompilerServicesUnsafeVersion)" />
<ExtraPackageVersionPropsPackageInfo Include="SourceBuildLiftedSystemTextEncodingCodePagesVersion" Version="%24(SystemTextEncodingCodePagesVersion)" />
</ItemGroup>
<ItemGroup> <ItemGroup>
<RepositoryReference Include="arcade" /> <RepositoryReference Include="arcade" />
<RepositoryReference Include="command-line-api" /> <RepositoryReference Include="command-line-api" />

View file

@ -32,6 +32,7 @@
<UseSourceBuiltSdkOverride Include="@(ArcadeCoreFxTestingOverride)" /> <UseSourceBuiltSdkOverride Include="@(ArcadeCoreFxTestingOverride)" />
<UseSourceBuiltSdkOverride Include="@(ArcadePackagingOverride)" /> <UseSourceBuiltSdkOverride Include="@(ArcadePackagingOverride)" />
<UseSourceBuiltSdkOverride Include="@(ArcadeTargetFrameworkSdkOverride)" /> <UseSourceBuiltSdkOverride Include="@(ArcadeTargetFrameworkSdkOverride)" />
<UseSourceBuiltSdkOverride Include="@(ArcadeSharedFrameworkSdkOverride)" />
</ItemGroup> </ItemGroup>
<!-- Environment Variables --> <!-- Environment Variables -->

View file

@ -42,6 +42,7 @@
<RepositoryReference Include="roslyn-analyzers" /> <RepositoryReference Include="roslyn-analyzers" />
<RepositoryReference Include="vstest" /> <RepositoryReference Include="vstest" />
<RepositoryReference Include="fsharp" /> <RepositoryReference Include="fsharp" />
<RepositoryReference Include="format" />
<RepositoryReference Include="deployment-tools" /> <RepositoryReference Include="deployment-tools" />
</ItemGroup> </ItemGroup>

View file

@ -15,6 +15,7 @@
<ItemGroup> <ItemGroup>
<RepositoryReference Include="clicommandlineparser" /> <RepositoryReference Include="clicommandlineparser" />
<RepositoryReference Include="nuget-client" />
<RepositoryReference Include="source-build" /> <RepositoryReference Include="source-build" />
</ItemGroup> </ItemGroup>

View file

@ -246,21 +246,39 @@ function doCommand() {
wait $! wait $!
echo " terminated with exit code $?" | tee -a "$logFile" echo " terminated with exit code $?" | tee -a "$logFile"
elif [ "$1" == "multi-rid-publish" ]; then elif [ "$1" == "multi-rid-publish" ]; then
runPublishScenarios() { if [ "$lang" == "F#" ]; then
"${dotnetCmd}" publish --self-contained false /bl:"${binlogPrefix}publish-fx-dep.binlog" # F# tries to use a truncated version number unless we pass it this flag. see https://github.com/dotnet/source-build/issues/2554
"${dotnetCmd}" publish --self-contained true -r "$targetRid" /bl:"${binlogPrefix}publish-self-contained-${targetRid}.binlog" runPublishScenarios() {
"${dotnetCmd}" publish --self-contained true -r linux-x64 /bl:"${binlogPrefix}publish-self-contained-portable.binlog" "${dotnetCmd}" publish --self-contained false /bl:"${binlogPrefix}publish-fx-dep.binlog" /p:_NETCoreSdkIsPreview=true
} "${dotnetCmd}" publish --self-contained true -r "$targetRid" /bl:"${binlogPrefix}publish-self-contained-${targetRid}.binlog" /p:_NETCoreSdkIsPreview=true
"${dotnetCmd}" publish --self-contained true -r linux-x64 /bl:"${binlogPrefix}publish-self-contained-portable.binlog" /p:_NETCoreSdkIsPreview=true
}
else
runPublishScenarios() {
"${dotnetCmd}" publish --self-contained false /bl:"${binlogPrefix}publish-fx-dep.binlog"
"${dotnetCmd}" publish --self-contained true -r "$targetRid" /bl:"${binlogPrefix}publish-self-contained-${targetRid}.binlog"
"${dotnetCmd}" publish --self-contained true -r linux-x64 /bl:"${binlogPrefix}publish-self-contained-portable.binlog"
}
fi
if [ "$projectOutput" == "true" ]; then if [ "$projectOutput" == "true" ]; then
runPublishScenarios | tee -a "$logFile" runPublishScenarios | tee -a "$logFile"
else else
runPublishScenarios >> "$logFile" 2>&1 runPublishScenarios >> "$logFile" 2>&1
fi fi
else else
if [ "$projectOutput" == "true" ]; then if [ "$lang" == "F#" ]; then
"${dotnetCmd}" $1 /bl:"$binlog" | tee -a "$logFile" # F# tries to use a truncated version number unless we pass it this flag. see https://github.com/dotnet/source-build/issues/2554
if [ "$projectOutput" == "true" ]; then
"${dotnetCmd}" $1 /bl:"$binlog" /p:_NETCoreSdkIsPreview=true | tee -a "$logFile"
else
"${dotnetCmd}" $1 /bl:"$binlog" /p:_NETCoreSdkIsPreview=true >> "$logFile" 2>&1
fi
else else
"${dotnetCmd}" $1 /bl:"$binlog" >> "$logFile" 2>&1 if [ "$projectOutput" == "true" ]; then
"${dotnetCmd}" $1 /bl:"$binlog" | tee -a "$logFile"
else
"${dotnetCmd}" $1 /bl:"$binlog" >> "$logFile" 2>&1
fi
fi fi
fi fi
if [ $? -eq 0 ]; then if [ $? -eq 0 ]; then
@ -304,7 +322,8 @@ function runAllTests() {
doCommand VB xunit new restore test doCommand VB xunit new restore test
doCommand VB mstest new restore test doCommand VB mstest new restore test
doCommand F# console new restore build run multi-rid-publish # "run" was removed from the list below. see https://github.com/dotnet/source-build/issues/2554
doCommand F# console new restore build multi-rid-publish
doCommand F# classlib new restore build multi-rid-publish doCommand F# classlib new restore build multi-rid-publish
doCommand F# xunit new restore test doCommand F# xunit new restore test
doCommand F# mstest new restore test doCommand F# mstest new restore test
@ -329,12 +348,16 @@ function runWebTests() {
doCommand C# mvc "$@" new restore build run multi-rid-publish doCommand C# mvc "$@" new restore build run multi-rid-publish
doCommand C# webapi "$@" new restore build multi-rid-publish doCommand C# webapi "$@" new restore build multi-rid-publish
doCommand C# razor "$@" new restore build run multi-rid-publish doCommand C# razor "$@" new restore build run multi-rid-publish
doCommand C# blazorwasm "$@" new restore build run publish # Requires prereqs (non-source-built packages) - re-enable with https://github.com/dotnet/source-build/issues/2550
# doCommand C# blazorwasm "$@" new restore build run publish
doCommand C# blazorserver "$@" new restore build run publish doCommand C# blazorserver "$@" new restore build run publish
doCommand F# web "$@" new restore build run multi-rid-publish # "run" was removed from the list below. see https://github.com/dotnet/source-build/issues/2554
doCommand F# mvc "$@" new restore build run multi-rid-publish doCommand F# web "$@" new restore build multi-rid-publish
doCommand F# webapi "$@" new restore build run multi-rid-publish # Requires prereqs (non-source-built packages) - re-enable with https://github.com/dotnet/source-build/issues/2550
# doCommand F# mvc "$@" new restore build run multi-rid-publish
# "run" was also removed from this set, same issue: https://github.com/dotnet/source-build/issues/2554
doCommand F# webapi "$@" new restore build multi-rid-publish
} }
function runXmlDocTests() { function runXmlDocTests() {
@ -517,6 +540,7 @@ function runXmlDocTests() {
System.Xml.Serialization.xml System.Xml.Serialization.xml
System.Xml.xml System.Xml.xml
System.Xml.XmlDocument.xml System.Xml.XmlDocument.xml
WindowsBase.xml
) )
aspnetcoreappIgnoreList=( aspnetcoreappIgnoreList=(

View file

@ -46,8 +46,16 @@
WorkingDirectory="$(PrebuiltSourceBuiltPackagesPath)" WorkingDirectory="$(PrebuiltSourceBuiltPackagesPath)"
Condition="'$(CustomPrebuiltSourceBuiltPackagesPath)' == ''" /> Condition="'$(CustomPrebuiltSourceBuiltPackagesPath)' == ''" />
<Exec Command="tar -xzf $(ExternalTarballsDir)$(SourceBuiltPrebuiltsTarballName).*.tar.gz" <!--
WorkingDirectory="$(PrebuiltPackagesPath)" /> Check for a prebuilt dependency tarball and extract if exists. If there isn't one, we expect
the build to be working without prebuilts.
-->
<ItemGroup>
<SourceBuiltPrebuiltsTarballFile Include="$(ExternalTarballsDir)$(SourceBuiltPrebuiltsTarballName).*.tar.gz" />
</ItemGroup>
<Exec Command="tar -xzf %(SourceBuiltPrebuiltsTarballFile.FullPath)"
WorkingDirectory="$(PrebuiltPackagesPath)"
Condition="'@(SourceBuiltPrebuiltsTarballFile)' != ''" />
<!-- Move SBRP packages to reference packages location --> <!-- Move SBRP packages to reference packages location -->
<MakeDir Directories="$(ReferencePackagesDir)" /> <MakeDir Directories="$(ReferencePackagesDir)" />

View file

@ -5,8 +5,7 @@ Subject: [PATCH] Build Microsoft.DotNet.Build.Tasks.Workloads for net6.0
--- ---
.../src/Microsoft.DotNet.Build.Tasks.Workloads.csproj | 1 + .../src/Microsoft.DotNet.Build.Tasks.Workloads.csproj | 1 +
.../src/VisualStudioComponent.cs | 4 ++++ 1 files changed, 1 insertions(+)
2 files changed, 5 insertions(+)
diff --git a/src/Microsoft.DotNet.Build.Tasks.Workloads/src/Microsoft.DotNet.Build.Tasks.Workloads.csproj b/src/Microsoft.DotNet.Build.Tasks.Workloads/src/Microsoft.DotNet.Build.Tasks.Workloads.csproj diff --git a/src/Microsoft.DotNet.Build.Tasks.Workloads/src/Microsoft.DotNet.Build.Tasks.Workloads.csproj b/src/Microsoft.DotNet.Build.Tasks.Workloads/src/Microsoft.DotNet.Build.Tasks.Workloads.csproj
index ae34705a..bda5d581 100644 index ae34705a..bda5d581 100644
@ -20,22 +19,6 @@ index ae34705a..bda5d581 100644
<AllowUnsafeBlocks>true</AllowUnsafeBlocks> <AllowUnsafeBlocks>true</AllowUnsafeBlocks>
<LangVersion>Latest</LangVersion> <LangVersion>Latest</LangVersion>
<IsPackable>true</IsPackable> <IsPackable>true</IsPackable>
diff --git a/src/Microsoft.DotNet.Build.Tasks.Workloads/src/VisualStudioComponent.cs b/src/Microsoft.DotNet.Build.Tasks.Workloads/src/VisualStudioComponent.cs
index ee7e9d6d..b69b6823 100644
--- a/src/Microsoft.DotNet.Build.Tasks.Workloads/src/VisualStudioComponent.cs
+++ b/src/Microsoft.DotNet.Build.Tasks.Workloads/src/VisualStudioComponent.cs
@@ -247,7 +247,11 @@ public TaskItem Generate(string projectPath)
// processing direct pack dependencies
if (workload.Extends?.Count() > 0)
{
+#if NET6_0
+ foreach (WorkloadId dependency in workload.Extends)
+#else
foreach (WorkloadDefinitionId dependency in workload.Extends)
+#endif
{
// Component dependencies, aka. workload extensions only have minimum version dependencies.
component.AddDependency($"{Utils.ToSafeId(dependency.ToString())}", new Version("1.0.0.0"), maxVersion: null);
-- --
2.29.2 2.29.2

View file

@ -1,25 +0,0 @@
From 4577f60202649281d2c96c4d8b67d331b7e71c35 Mon Sep 17 00:00:00 2001
From: Michael Simons <msimons@microsoft.com>
Date: Fri, 10 Sep 2021 13:52:54 +0000
Subject: [PATCH] Respond to WorkloadDefinition breaking API change
See https://github.com/dotnet/arcade/issues/7880 for details
---
.../src/GenerateWorkloadMsis.cs | 1 +
1 file changed, 1 insertion(+)
diff --git a/src/Microsoft.DotNet.Build.Tasks.Workloads/src/GenerateWorkloadMsis.cs b/src/Microsoft.DotNet.Build.Tasks.Workloads/src/GenerateWorkloadMsis.cs
index 50340821..a65453f2 100644
--- a/src/Microsoft.DotNet.Build.Tasks.Workloads/src/GenerateWorkloadMsis.cs
+++ b/src/Microsoft.DotNet.Build.Tasks.Workloads/src/GenerateWorkloadMsis.cs
@@ -121,6 +121,7 @@ private IEnumerable<WorkloadPack> GetWorkloadPacks()
// platform includes Windows
var workloads = manifests.SelectMany(m => m.Workloads).
Select(w => w.Value).
+ OfType<WorkloadDefinition>().
Where(wd => (wd.Platforms == null) || wd.Platforms.Any(p => p.StartsWith("win")));
var packIds = workloads.Where(w => w.Packs != null).SelectMany(w => w.Packs).Distinct();
--
2.29.2

View file

@ -13,20 +13,20 @@ Temporary workaround until source-build is built with recent source-built.
1 file changed, 4 insertions(+) 1 file changed, 4 insertions(+)
diff --git a/Directory.Build.props b/Directory.Build.props diff --git a/Directory.Build.props b/Directory.Build.props
index 960eb6c9..fa87aaac 100644 index 37feef5..c5aee85 100644
--- a/Directory.Build.props --- a/Directory.Build.props
+++ b/Directory.Build.props +++ b/Directory.Build.props
@@ -18,6 +18,10 @@ @@ -18,6 +18,10 @@
<IsShipping>false</IsShipping> <IsShipping>false</IsShipping>
</PropertyGroup> </PropertyGroup>
+ <PropertyGroup> + <PropertyGroup>
+ <NoWarn>$(NoWarn);NU1603</NoWarn> + <NoWarn>$(NoWarn);NU1603</NoWarn>
+ </PropertyGroup> + </PropertyGroup>
+ +
<PropertyGroup Condition="'$(DotNetBuildFromSource)' == 'true'"> <PropertyGroup Condition="'$(DotNetBuildOffline)' == 'true'">
<!-- <!--
When building using source-build the process is: Arcade has a special version prop for CodeAnalysis.CSharp in GenFacades
-- --
2.29.2 2.29.2

View file

@ -0,0 +1,124 @@
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
From: Davis Goodin <dagood@microsoft.com>
Date: Fri, 8 Oct 2021 16:15:42 -0700
Subject: [PATCH] Disable Workloads WiX dependency in source-build
This removes the prebuilt WiX dependency: https://github.com/dotnet/arcade/issues/8014
The patch is temporary, pending upstream fix and dependency flow.
---
.../src/{FileRow.cs => FileRow.wix.cs} | 0
...ifestMsi.cs => GenerateManifestMsi.wix.cs} | 0
.../{GenerateMsi.cs => GenerateMsi.wix.cs} | 0
...erateMsiBase.cs => GenerateMsiBase.wix.cs} | 0
...erateVisualStudioMsiPackageProject.wix.cs} | 0
...cs => GenerateVisualStudioWorkload.wix.cs} | 0
...oadMsis.cs => GenerateWorkloadMsis.wix.cs} | 0
...rosoft.DotNet.Build.Tasks.Workloads.csproj | 23 ++++++++++++++++---
...{MsiProperties.cs => MsiProperties.wix.cs} | 0
.../src/{MsiUtils.cs => MsiUtils.wix.cs} | 0
...elatedProduct.cs => RelatedProduct.wix.cs} | 0
11 files changed, 20 insertions(+), 3 deletions(-)
rename src/Microsoft.DotNet.Build.Tasks.Workloads/src/{FileRow.cs => FileRow.wix.cs} (100%)
rename src/Microsoft.DotNet.Build.Tasks.Workloads/src/{GenerateManifestMsi.cs => GenerateManifestMsi.wix.cs} (100%)
rename src/Microsoft.DotNet.Build.Tasks.Workloads/src/{GenerateMsi.cs => GenerateMsi.wix.cs} (100%)
rename src/Microsoft.DotNet.Build.Tasks.Workloads/src/{GenerateMsiBase.cs => GenerateMsiBase.wix.cs} (100%)
rename src/Microsoft.DotNet.Build.Tasks.Workloads/src/{GenerateVisualStudioMsiPackageProject.cs => GenerateVisualStudioMsiPackageProject.wix.cs} (100%)
rename src/Microsoft.DotNet.Build.Tasks.Workloads/src/{GenerateVisualStudioWorkload.cs => GenerateVisualStudioWorkload.wix.cs} (100%)
rename src/Microsoft.DotNet.Build.Tasks.Workloads/src/{GenerateWorkloadMsis.cs => GenerateWorkloadMsis.wix.cs} (100%)
rename src/Microsoft.DotNet.Build.Tasks.Workloads/src/{MsiProperties.cs => MsiProperties.wix.cs} (100%)
rename src/Microsoft.DotNet.Build.Tasks.Workloads/src/{MsiUtils.cs => MsiUtils.wix.cs} (100%)
rename src/Microsoft.DotNet.Build.Tasks.Workloads/src/{RelatedProduct.cs => RelatedProduct.wix.cs} (100%)
diff --git a/src/Microsoft.DotNet.Build.Tasks.Workloads/src/FileRow.cs b/src/Microsoft.DotNet.Build.Tasks.Workloads/src/FileRow.wix.cs
similarity index 100%
rename from src/Microsoft.DotNet.Build.Tasks.Workloads/src/FileRow.cs
rename to src/Microsoft.DotNet.Build.Tasks.Workloads/src/FileRow.wix.cs
diff --git a/src/Microsoft.DotNet.Build.Tasks.Workloads/src/GenerateManifestMsi.cs b/src/Microsoft.DotNet.Build.Tasks.Workloads/src/GenerateManifestMsi.wix.cs
similarity index 100%
rename from src/Microsoft.DotNet.Build.Tasks.Workloads/src/GenerateManifestMsi.cs
rename to src/Microsoft.DotNet.Build.Tasks.Workloads/src/GenerateManifestMsi.wix.cs
diff --git a/src/Microsoft.DotNet.Build.Tasks.Workloads/src/GenerateMsi.cs b/src/Microsoft.DotNet.Build.Tasks.Workloads/src/GenerateMsi.wix.cs
similarity index 100%
rename from src/Microsoft.DotNet.Build.Tasks.Workloads/src/GenerateMsi.cs
rename to src/Microsoft.DotNet.Build.Tasks.Workloads/src/GenerateMsi.wix.cs
diff --git a/src/Microsoft.DotNet.Build.Tasks.Workloads/src/GenerateMsiBase.cs b/src/Microsoft.DotNet.Build.Tasks.Workloads/src/GenerateMsiBase.wix.cs
similarity index 100%
rename from src/Microsoft.DotNet.Build.Tasks.Workloads/src/GenerateMsiBase.cs
rename to src/Microsoft.DotNet.Build.Tasks.Workloads/src/GenerateMsiBase.wix.cs
diff --git a/src/Microsoft.DotNet.Build.Tasks.Workloads/src/GenerateVisualStudioMsiPackageProject.cs b/src/Microsoft.DotNet.Build.Tasks.Workloads/src/GenerateVisualStudioMsiPackageProject.wix.cs
similarity index 100%
rename from src/Microsoft.DotNet.Build.Tasks.Workloads/src/GenerateVisualStudioMsiPackageProject.cs
rename to src/Microsoft.DotNet.Build.Tasks.Workloads/src/GenerateVisualStudioMsiPackageProject.wix.cs
diff --git a/src/Microsoft.DotNet.Build.Tasks.Workloads/src/GenerateVisualStudioWorkload.cs b/src/Microsoft.DotNet.Build.Tasks.Workloads/src/GenerateVisualStudioWorkload.wix.cs
similarity index 100%
rename from src/Microsoft.DotNet.Build.Tasks.Workloads/src/GenerateVisualStudioWorkload.cs
rename to src/Microsoft.DotNet.Build.Tasks.Workloads/src/GenerateVisualStudioWorkload.wix.cs
diff --git a/src/Microsoft.DotNet.Build.Tasks.Workloads/src/GenerateWorkloadMsis.cs b/src/Microsoft.DotNet.Build.Tasks.Workloads/src/GenerateWorkloadMsis.wix.cs
similarity index 100%
rename from src/Microsoft.DotNet.Build.Tasks.Workloads/src/GenerateWorkloadMsis.cs
rename to src/Microsoft.DotNet.Build.Tasks.Workloads/src/GenerateWorkloadMsis.wix.cs
diff --git a/src/Microsoft.DotNet.Build.Tasks.Workloads/src/Microsoft.DotNet.Build.Tasks.Workloads.csproj b/src/Microsoft.DotNet.Build.Tasks.Workloads/src/Microsoft.DotNet.Build.Tasks.Workloads.csproj
index 19cf67b5..2d02b7f4 100644
--- a/src/Microsoft.DotNet.Build.Tasks.Workloads/src/Microsoft.DotNet.Build.Tasks.Workloads.csproj
+++ b/src/Microsoft.DotNet.Build.Tasks.Workloads/src/Microsoft.DotNet.Build.Tasks.Workloads.csproj
@@ -11,6 +11,16 @@
<NoWarn>$(NoWarn);NU5127</NoWarn>
<EnableDefaultNoneItems>false</EnableDefaultNoneItems>
<RootNamespace>Microsoft.DotNet.Build.Tasks.Workloads</RootNamespace>
+
+ <!--
+ Only include WiX-powered features when running a non-from-source build. (For example, the
+ Microsoft build used to build .NET for Windows.)
+
+ This removes a dependency on prebuilt WiX binaries. The purpose of WiX is to produce Windows
+ installers, and source-build doesn't run on Windows, so excluding WiX while building in
+ source-build mode to remove the prebuilt dependency has no impact to available .NET features.
+ -->
+ <IncludeWiX Condition="'$(DotNetBuildFromSource)' != 'true'">true</IncludeWiX>
</PropertyGroup>
<ItemGroup>
@@ -19,13 +29,16 @@
<PackageReference Include="Microsoft.Build.Tasks.Core" Version="$(MicrosoftBuildTasksCoreVersion)" />
<PackageReference Include="Microsoft.Build.Framework" Version="$(MicrosoftBuildFrameworkVersion)" />
<PackageReference Include="NuGet.Packaging" Version="$(NuGetVersion)" />
- <PackageReference Include="Wix" Version="3.11.2" />
<PackageReference Include="Microsoft.NET.Sdk.WorkloadManifestReader" Version="$(MicrosoftNetSdkWorkloadManifestReaderVersion)" />
- <PackageReference Include="System.Text.Json" Version="$(SystemTextJsonVersion)" Condition="'$(TargetFramework)' == 'net472'"/>
+ <PackageReference Include="System.Text.Json" Version="$(SystemTextJsonVersion)" Condition="'$(TargetFramework)' == 'net472'" />
<PackageReference Include="Microsoft.Deployment.DotNet.Releases" Version="$(MicrosoftDeploymentDotNetReleasesVersion)" />
</ItemGroup>
- <ItemGroup>
+ <ItemGroup Condition="'$(IncludeWiX)' == 'true'">
+ <PackageReference Include="Wix" Version="3.11.2" />
+ </ItemGroup>
+
+ <ItemGroup Condition="'$(IncludeWiX)' == 'true'">
<Reference Include="$(WixInstallPath)\Microsoft.Deployment.Resources.dll" />
<Reference Include="$(WixInstallPath)\Microsoft.Deployment.Compression.dll" />
<Reference Include="$(WixInstallPath)\Microsoft.Deployment.Compression.Cab.dll" />
@@ -48,6 +61,10 @@
<EmbeddedResource Remove="obj\**" />
</ItemGroup>
+ <ItemGroup Condition="'$(IncludeWiX)' != 'true'">
+ <Compile Remove="**\*.wix.cs" />
+ </ItemGroup>
+
<ItemGroup>
<EmbeddedResource Include="Misc\*.*" />
<EmbeddedResource Include="MsiTemplate\*.wxs" />
diff --git a/src/Microsoft.DotNet.Build.Tasks.Workloads/src/MsiProperties.cs b/src/Microsoft.DotNet.Build.Tasks.Workloads/src/MsiProperties.wix.cs
similarity index 100%
rename from src/Microsoft.DotNet.Build.Tasks.Workloads/src/MsiProperties.cs
rename to src/Microsoft.DotNet.Build.Tasks.Workloads/src/MsiProperties.wix.cs
diff --git a/src/Microsoft.DotNet.Build.Tasks.Workloads/src/MsiUtils.cs b/src/Microsoft.DotNet.Build.Tasks.Workloads/src/MsiUtils.wix.cs
similarity index 100%
rename from src/Microsoft.DotNet.Build.Tasks.Workloads/src/MsiUtils.cs
rename to src/Microsoft.DotNet.Build.Tasks.Workloads/src/MsiUtils.wix.cs
diff --git a/src/Microsoft.DotNet.Build.Tasks.Workloads/src/RelatedProduct.cs b/src/Microsoft.DotNet.Build.Tasks.Workloads/src/RelatedProduct.wix.cs
similarity index 100%
rename from src/Microsoft.DotNet.Build.Tasks.Workloads/src/RelatedProduct.cs
rename to src/Microsoft.DotNet.Build.Tasks.Workloads/src/RelatedProduct.wix.cs

View file

@ -0,0 +1,50 @@
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
From: Davis Goodin <dagood@microsoft.com>
Date: Wed, 20 Oct 2021 16:17:54 -0500
Subject: [PATCH] Fix AppHost pack prebuilt usage in source-build
This avoids downloading a prebuilt apphost pack.
Upstream PR: https://github.com/dotnet/aspnetcore/pull/37672
---
Directory.Build.props | 14 ++++++++++++--
.../src/Microsoft.AspNetCore.App.Ref.csproj | 1 +
2 files changed, 13 insertions(+), 2 deletions(-)
diff --git a/Directory.Build.props b/Directory.Build.props
index 204df64da7..7280c12748 100644
--- a/Directory.Build.props
+++ b/Directory.Build.props
@@ -198,8 +198,18 @@
<!-- The location of the local installation of the .NET Core shared framework. -->
<PropertyGroup>
<LocalDotNetRoot>$(RepoRoot).dotnet\</LocalDotNetRoot>
- <!-- Override the SDK default and point to local .dotnet folder. -->
- <NetCoreTargetingPackRoot>$(LocalDotNetRoot)packs\</NetCoreTargetingPackRoot>
+ <!--
+ Override the SDK default and point to local .dotnet folder. This is done to work around
+ limitations in the way the .NET SDK finds shared frameworks and targeting packs. It allows
+ tests to use the shared frameworks and targeting packs that were just built.
+
+ However, source-build needs this to not happen while building projects that rely on the
+ AppHost framework pack. Source-build installs an SDK in a custom location outside this
+ repository, and setting NetCoreTargetingPackRoot to a different location causes source-build
+ to restore the AppHost pack as a prebuilt rather than using the one that's present in the SDK.
+ Source-build doesn't run tests, so the property is simply conditioned out.
+ -->
+ <NetCoreTargetingPackRoot Condition="'$(DotNetBuildFromSource)' != 'true'">$(LocalDotNetRoot)packs\</NetCoreTargetingPackRoot>
</PropertyGroup>
<Import Project="eng\tools\RepoTasks\RepoTasks.tasks" Condition="'$(MSBuildProjectName)' != 'RepoTasks' AND '$(DesignTimeBuild)' != 'true'" />
diff --git a/src/Framework/App.Ref/src/Microsoft.AspNetCore.App.Ref.csproj b/src/Framework/App.Ref/src/Microsoft.AspNetCore.App.Ref.csproj
index 0cb7503c04..3a0832ee21 100644
--- a/src/Framework/App.Ref/src/Microsoft.AspNetCore.App.Ref.csproj
+++ b/src/Framework/App.Ref/src/Microsoft.AspNetCore.App.Ref.csproj
@@ -211,6 +211,7 @@ This package is an internal implementation of the .NET Core SDK and is not meant
<!-- Workaround https://github.com/dotnet/sdk/issues/2910 by copying targeting pack into local installation. -->
<Target Name="_InstallTargetingPackIntoLocalDotNet"
DependsOnTargets="_ResolveTargetingPackContent"
+ Condition="'$(DotNetBuildFromSource)' != 'true'"
Inputs="@(RefPackContent)"
Outputs="@(RefPackContent->'$(LocalInstallationOutputPath)%(PackagePath)%(RecursiveDir)%(FileName)%(Extension)')">
<RemoveDir Directories="$(LocalInstallationOutputPath)" />

View file

@ -0,0 +1,68 @@
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
From: Davis Goodin <dagood@microsoft.com>
Date: Fri, 22 Oct 2021 13:26:33 -0500
Subject: [PATCH] Fix MicrosoftExtensionsVersion
Move it to eng/Versions.props to make it overridable, and rename it to match an
actual package ID.
Update paramater nullability in src/Logging/SimpleConsoleLogger.cs to be
source-compatible with the 6.0 version of these packages.
See https://github.com/dotnet/format/issues/1400
---
Directory.Packages.props | 7 +++----
eng/Versions.props | 1 +
src/Logging/SimpleConsoleLogger.cs | 2 +-
3 files changed, 5 insertions(+), 5 deletions(-)
diff --git a/Directory.Packages.props b/Directory.Packages.props
index 6b628c2..9b579ea 100644
--- a/Directory.Packages.props
+++ b/Directory.Packages.props
@@ -2,7 +2,6 @@
<!-- <Import Project="eng\Versions.props" /> -->
<PropertyGroup>
- <MicrosoftExtensionsVersion>5.0.0</MicrosoftExtensionsVersion>
<!-- In order tests against the same version of NuGet as the SDK. We have to set this to match. -->
<NuGetVersion>6.0.0-preview.4.221</NuGetVersion>
</PropertyGroup>
@@ -25,9 +24,9 @@
<PackageVersion Include="Microsoft.CodeAnalysis.Workspaces.Common" Version="$(MicrosoftNETCoreCompilersPackageVersion)" />
<PackageVersion Include="Microsoft.CodeAnalysis.Workspaces.MSBuild" Version="$(MicrosoftNETCoreCompilersPackageVersion)" />
<PackageVersion Include="Microsoft.CodeAnalysis" Version="$(MicrosoftNETCoreCompilersPackageVersion)" />
- <PackageVersion Include="Microsoft.Extensions.DependencyInjection" Version="$(MicrosoftExtensionsVersion)" />
- <PackageVersion Include="Microsoft.Extensions.FileSystemGlobbing" Version="$(MicrosoftExtensionsVersion)" />
- <PackageVersion Include="Microsoft.Extensions.Logging" Version="$(MicrosoftExtensionsVersion)" />
+ <PackageVersion Include="Microsoft.Extensions.DependencyInjection" Version="$(MicrosoftExtensionsDependencyInjectionVersion)" />
+ <PackageVersion Include="Microsoft.Extensions.FileSystemGlobbing" Version="$(MicrosoftExtensionsDependencyInjectionVersion)" />
+ <PackageVersion Include="Microsoft.Extensions.Logging" Version="$(MicrosoftExtensionsDependencyInjectionVersion)" />
<PackageVersion Include="NuGet.Common" Version="$(NuGetVersion)" />
<PackageVersion Include="NuGet.Configuration" Version="$(NuGetVersion)" />
<PackageVersion Include="NuGet.Frameworks" Version="$(NuGetVersion)" />
diff --git a/eng/Versions.props b/eng/Versions.props
index b1990aa..f6ddbbd 100644
--- a/eng/Versions.props
+++ b/eng/Versions.props
@@ -15,6 +15,7 @@
<PropertyGroup>
<MicrosoftBuildVersion>16.11.0</MicrosoftBuildVersion>
<MicrosoftCodeAnalysisAnalyzersVersion>3.3.2</MicrosoftCodeAnalysisAnalyzersVersion>
+ <MicrosoftExtensionsDependencyInjectionVersion>5.0.0</MicrosoftExtensionsDependencyInjectionVersion>
<!-- Dependencies from https://github.com/dotnet/roslyn -->
<MicrosoftNETCoreCompilersPackageVersion>4.0.0-6.21526.21</MicrosoftNETCoreCompilersPackageVersion>
<!-- Dependencies from https://github.com/dotnet/command-line-api -->
diff --git a/src/Logging/SimpleConsoleLogger.cs b/src/Logging/SimpleConsoleLogger.cs
index c361f84..fd8015c 100644
--- a/src/Logging/SimpleConsoleLogger.cs
+++ b/src/Logging/SimpleConsoleLogger.cs
@@ -37,7 +37,7 @@ namespace Microsoft.CodeAnalysis.Tools.Logging
_minimalErrorLevel = minimalErrorLevel;
}
- public void Log<TState>(LogLevel logLevel, EventId eventId, TState state, Exception exception, Func<TState, Exception, string> formatter)
+ public void Log<TState>(LogLevel logLevel, EventId eventId, TState state, Exception? exception, Func<TState, Exception?, string> formatter)
{
if (!IsEnabled(logLevel))
{

View file

@ -0,0 +1,167 @@
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
From: Davis Goodin <dagood@microsoft.com>
Date: Tue, 19 Oct 2021 16:11:51 -0500
Subject: [PATCH] Disable apphost on downlevel frameworks during source-build
During source-build, disable apphost build for 'fsi' and 'fsc', and
'fsyacc', 'fslex', and 'AssemblyCheck' during the bootstrap build.
Creating an apphost for a net5.0 project while building with a net6.0
SDK downloads the apphost pack as a prebuilt. Stopping the projects from
creating the apphost removes the prebuilt for source-build.
To make disabling the apphost work in the bootstrapping build, add a
check to eng/build.sh to skip the bootstrap build if we're currently
running the "outer" source-build. That gives source-build the ability to
run bootstrapping on its own terms. Now, when eng/SourceBuild.props runs
bootstrapping, it can pass the DotNetBuildFromSource property through
the environment so it takes effect.
See: https://github.com/dotnet/fsharp/issues/12282
PR: https://github.com/dotnet/fsharp/pull/12286
---
eng/SourceBuild.props | 2 +-
eng/build.sh | 51 ++++++++++---------
.../AssemblyCheck/AssemblyCheck.fsproj | 1 +
src/buildtools/fslex/fslex.fsproj | 1 +
src/buildtools/fsyacc/fsyacc.fsproj | 1 +
src/fsharp/fsc/fsc.fsproj | 1 +
src/fsharp/fsi/fsi.fsproj | 1 +
7 files changed, 34 insertions(+), 24 deletions(-)
diff --git a/eng/SourceBuild.props b/eng/SourceBuild.props
index 22c929f28..903ee00d3 100644
--- a/eng/SourceBuild.props
+++ b/eng/SourceBuild.props
@@ -41,7 +41,7 @@
<Exec
Command="./build.sh --bootstrap --skipBuild"
WorkingDirectory="$(InnerSourceBuildRepoRoot)"
- EnvironmentVariables="@(InnerBuildEnv)" />
+ EnvironmentVariables="@(InnerBuildEnv);DotNetBuildFromSource=true" />
</Target>
</Project>
diff --git a/eng/build.sh b/eng/build.sh
index 9a2aa0083..6af422237 100755
--- a/eng/build.sh
+++ b/eng/build.sh
@@ -240,29 +240,34 @@ function BuildSolution {
node_reuse=false
# build bootstrap tools
- bootstrap_config=Proto
- bootstrap_dir=$artifacts_dir/Bootstrap
- if [[ "$force_bootstrap" == true ]]; then
- rm -fr $bootstrap_dir
- fi
- if [ ! -f "$bootstrap_dir/fslex.dll" ]; then
- BuildMessage="Error building tools"
- MSBuild "$repo_root/src/buildtools/buildtools.proj" \
- /restore \
- /p:Configuration=$bootstrap_config
-
- mkdir -p "$bootstrap_dir"
- cp -pr $artifacts_dir/bin/fslex/$bootstrap_config/net5.0 $bootstrap_dir/fslex
- cp -pr $artifacts_dir/bin/fsyacc/$bootstrap_config/net5.0 $bootstrap_dir/fsyacc
- fi
- if [ ! -f "$bootstrap_dir/fsc.exe" ]; then
- BuildMessage="Error building bootstrap"
- MSBuild "$repo_root/proto.proj" \
- /restore \
- /p:Configuration=$bootstrap_config \
-
-
- cp -pr $artifacts_dir/bin/fsc/$bootstrap_config/net5.0 $bootstrap_dir/fsc
+ # source_build=true means we are currently in the outer/wrapper source-build,
+ # and building bootstrap needs to wait. The source-build targets will run this
+ # script again without setting source_build=true when it is done setting up
+ # the build environment. See 'eng/SourceBuild.props'.
+ if [[ "$source_build" != true ]]; then
+ bootstrap_config=Proto
+ bootstrap_dir=$artifacts_dir/Bootstrap
+ if [[ "$force_bootstrap" == true ]]; then
+ rm -fr $bootstrap_dir
+ fi
+ if [ ! -f "$bootstrap_dir/fslex.dll" ]; then
+ BuildMessage="Error building tools"
+ MSBuild "$repo_root/src/buildtools/buildtools.proj" \
+ /restore \
+ /p:Configuration=$bootstrap_config
+
+ mkdir -p "$bootstrap_dir"
+ cp -pr $artifacts_dir/bin/fslex/$bootstrap_config/net5.0 $bootstrap_dir/fslex
+ cp -pr $artifacts_dir/bin/fsyacc/$bootstrap_config/net5.0 $bootstrap_dir/fsyacc
+ fi
+ if [ ! -f "$bootstrap_dir/fsc.exe" ]; then
+ BuildMessage="Error building bootstrap"
+ MSBuild "$repo_root/proto.proj" \
+ /restore \
+ /p:Configuration=$bootstrap_config
+
+ cp -pr $artifacts_dir/bin/fsc/$bootstrap_config/net5.0 $bootstrap_dir/fsc
+ fi
fi
if [[ "$skip_build" != true ]]; then
diff --git a/src/buildtools/AssemblyCheck/AssemblyCheck.fsproj b/src/buildtools/AssemblyCheck/AssemblyCheck.fsproj
index 464b6ef78..5c78bbe6d 100644
--- a/src/buildtools/AssemblyCheck/AssemblyCheck.fsproj
+++ b/src/buildtools/AssemblyCheck/AssemblyCheck.fsproj
@@ -4,6 +4,7 @@
<OutputType>Exe</OutputType>
<TargetFramework>net5.0</TargetFramework>
<DisableImplicitFSharpCoreReference>true</DisableImplicitFSharpCoreReference>
+ <UseAppHost Condition="'$(DotNetBuildFromSource)' == 'true'">false</UseAppHost>
</PropertyGroup>
<ItemGroup>
diff --git a/src/buildtools/fslex/fslex.fsproj b/src/buildtools/fslex/fslex.fsproj
index 1959ce59c..3d63bf6bf 100644
--- a/src/buildtools/fslex/fslex.fsproj
+++ b/src/buildtools/fslex/fslex.fsproj
@@ -5,6 +5,7 @@
<TargetFramework>net5.0</TargetFramework>
<DefineConstants>INTERNALIZED_FSLEXYACC_RUNTIME;$(DefineConstants)</DefineConstants>
<DisableImplicitFSharpCoreReference>true</DisableImplicitFSharpCoreReference>
+ <UseAppHost Condition="'$(DotNetBuildFromSource)' == 'true'">false</UseAppHost>
</PropertyGroup>
<ItemGroup>
diff --git a/src/buildtools/fsyacc/fsyacc.fsproj b/src/buildtools/fsyacc/fsyacc.fsproj
index 5d1b7141f..63b63c5de 100644
--- a/src/buildtools/fsyacc/fsyacc.fsproj
+++ b/src/buildtools/fsyacc/fsyacc.fsproj
@@ -5,6 +5,7 @@
<TargetFramework>net5.0</TargetFramework>
<DefineConstants>INTERNALIZED_FSLEXYACC_RUNTIME;$(DefineConstants)</DefineConstants>
<DisableImplicitFSharpCoreReference>true</DisableImplicitFSharpCoreReference>
+ <UseAppHost Condition="'$(DotNetBuildFromSource)' == 'true'">false</UseAppHost>
</PropertyGroup>
<ItemGroup>
diff --git a/src/fsharp/fsc/fsc.fsproj b/src/fsharp/fsc/fsc.fsproj
index 7fa31fc21..04025c297 100644
--- a/src/fsharp/fsc/fsc.fsproj
+++ b/src/fsharp/fsc/fsc.fsproj
@@ -12,6 +12,7 @@
<OtherFlags>$(OtherFlags) --maxerrors:20 --extraoptimizationloops:1</OtherFlags>
<NGenBinary>true</NGenBinary>
<UseAppHost>true</UseAppHost>
+ <UseAppHost Condition="'$(DotNetBuildFromSource)' == 'true'">false</UseAppHost>
</PropertyGroup>
<PropertyGroup Condition="'$(TargetFramework)' == 'net472'">
diff --git a/src/fsharp/fsi/fsi.fsproj b/src/fsharp/fsi/fsi.fsproj
index 9fd9b1333..eace6c166 100644
--- a/src/fsharp/fsi/fsi.fsproj
+++ b/src/fsharp/fsi/fsi.fsproj
@@ -13,6 +13,7 @@
<Win32Resource>fsi.res</Win32Resource>
<NGenBinary>true</NGenBinary>
<UseAppHost>true</UseAppHost>
+ <UseAppHost Condition="'$(DotNetBuildFromSource)' == 'true'">false</UseAppHost>
</PropertyGroup>
<PropertyGroup Condition="'$(TargetFramework)' == 'net472'">

View file

@ -0,0 +1,24 @@
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
From: Logan Bussell <36081148+lbussell@users.noreply.github.com>
Date: Wed, 13 Oct 2021 18:26:09 +0000
Subject: [PATCH] fix tlens Mono.Cecil reference
Pull request for applying the patch: https://github.com/dotnet/linker/pull/2317
---
src/tlens/tlens.csproj | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/src/tlens/tlens.csproj b/src/tlens/tlens.csproj
index 92b3754..e17f9fb 100644
--- a/src/tlens/tlens.csproj
+++ b/src/tlens/tlens.csproj
@@ -10,7 +10,8 @@
</ItemGroup>
<ItemGroup>
- <PackageReference Include="Mono.Cecil" Version="$(MonoCecilVersion)" />
+ <PackageReference Condition="'$(UseCecilPackage)' == 'true'" Include="Mono.Cecil" Version="$(MonoCecilVersion)" />
+ <ProjectReference Condition="'$(UseCecilPackage)' != 'true'" Include="../../external/cecil/Mono.Cecil.csproj" />
</ItemGroup>
</Project>

View file

@ -0,0 +1,24 @@
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
From: Michael Simons <msimons@microsoft.com>
Date: Wed, 20 Oct 2021 14:44:36 +0000
Subject: [PATCH] Exclude Microsoft.DotNet.ApiCompat from source-build
Backport PR: https://github.com/dotnet/linker/pull/2326
---
eng/Tools.props | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/eng/Tools.props b/eng/Tools.props
index 494d208..7c32ad5 100644
--- a/eng/Tools.props
+++ b/eng/Tools.props
@@ -2,7 +2,7 @@
<!-- This file is an Arcade extension point that specifies additional tools to restore. -->
<ItemGroup>
- <PackageReference Include="Microsoft.DotNet.ApiCompat" Version="$(MicrosoftDotNetApiCompatVersion)" />
+ <PackageReference Include="Microsoft.DotNet.ApiCompat" Version="$(MicrosoftDotNetApiCompatVersion)" Condition=" '$(DotnetBuildFromSource)' != 'true' "/>
</ItemGroup>
</Project>
\ No newline at end of file

View file

@ -0,0 +1,23 @@
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
From: Michael Simons <msimons@microsoft.com>
Date: Wed, 20 Oct 2021 14:38:14 +0000
Subject: [PATCH 1/2] Upgrade Microsoft.NETFramework.ReferenceAssemblies from
1.0.0 to 1.0.2
Backport PR: https://github.com/dotnet/linker/pull/2326
---
src/ILLink.Tasks/ILLink.Tasks.csproj | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/src/ILLink.Tasks/ILLink.Tasks.csproj b/src/ILLink.Tasks/ILLink.Tasks.csproj
index 0ecf5d1..7501ecb 100644
--- a/src/ILLink.Tasks/ILLink.Tasks.csproj
+++ b/src/ILLink.Tasks/ILLink.Tasks.csproj
@@ -53,6 +53,6 @@
<PackageReference Include="Microsoft.Build.Utilities.Core" Version="$(MicrosoftBuildUtilitiesCoreVersion)" PrivateAssets="All" ExcludeAssets="Runtime" />
<PackageReference Include="System.Reflection.Metadata" Version="$(SystemReflectionMetadataVersion)" Condition=" '$(TargetFramework)' == 'net472' " PrivateAssets="All" Publish="True" />
- <PackageReference Include="Microsoft.NETFramework.ReferenceAssemblies" PrivateAssets="All" Version="1.0.0" />
+ <PackageReference Include="Microsoft.NETFramework.ReferenceAssemblies" PrivateAssets="All" Version="1.0.2" />
</ItemGroup>
</Project>

View file

@ -0,0 +1,36 @@
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
From: Davis Goodin <dagood@microsoft.com>
Date: Mon, 11 Oct 2021 17:09:14 -0500
Subject: [PATCH] Remove prebuilt jnm2.ReferenceAssemblies.net35
This prebuilt package filled a gap in the official 1.0 version of the .NET
Framework reference assembly packages. The gap has been fixed in later versions
of the official packages. Removal fixes a prebuilt dependency by letting the
repo use the official version of the packges, which are produced by SBRP.
https://github.com/dotnet/msbuild/issues/6935
---
src/StringTools/StringTools.csproj | 5 -----
1 file changed, 5 deletions(-)
diff --git a/src/StringTools/StringTools.csproj b/src/StringTools/StringTools.csproj
index fef9909..93a4634 100644
--- a/src/StringTools/StringTools.csproj
+++ b/src/StringTools/StringTools.csproj
@@ -20,17 +20,12 @@
<PropertyGroup Condition="'$(TargetFramework)' == 'net35'">
<AssemblyName>Microsoft.NET.StringTools.net35</AssemblyName>
- <!-- Disable Fx install checks as we're building against jnm2's 3.5 reference assemblies -->
- <BypassFrameworkInstallChecks>true</BypassFrameworkInstallChecks>
</PropertyGroup>
<ItemGroup Condition="'$(TargetFramework)' != 'net35'">
<PackageReference Include="System.Memory" />
<PackageReference Include="System.Runtime.CompilerServices.Unsafe" />
</ItemGroup>
- <ItemGroup>
- <PackageReference Include="jnm2.ReferenceAssemblies.net35" PrivateAssets="All" />
- </ItemGroup>
<ItemGroup Condition="'$(TargetFramework)' == 'net35'">
<Compile Remove="SpanBasedStringBuilder.cs" />

View file

@ -0,0 +1,29 @@
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
From: Davis Goodin <dagood@microsoft.com>
Date: Tue, 12 Oct 2021 18:14:59 -0500
Subject: [PATCH] Disable BannedApiAnalyzers during source-build
BannedApiAnalyzers has some intentional old dependencies and it's not feasible
to build it during source-build. Remove this usage to remove a prebuilt.
https://github.com/dotnet/msbuild/issues/6961
---
eng/Packages.props | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/eng/Packages.props b/eng/Packages.props
index 0f478634f..3cc09a008 100644
--- a/eng/Packages.props
+++ b/eng/Packages.props
@@ -45,11 +45,11 @@
<ItemGroup Condition="'$(DotNetBuildFromSource)' != 'true'">
<GlobalPackageReference Include="Microsoft.NETFramework.ReferenceAssemblies" Version="1.0.0" PrivateAssets="All"/>
+ <GlobalPackageReference Include="Microsoft.CodeAnalysis.BannedApiAnalyzers" Version="$(MicrosoftCodeAnalysisBannedApiAnalyzersVersion)" />
</ItemGroup>
<ItemGroup>
<GlobalPackageReference Include="Microsoft.VisualStudio.SDK.EmbedInteropTypes" Version="15.0.15" PrivateAssets="All" Condition="'$(TargetFrameworkIdentifier)' == '.NETFramework'" />
- <GlobalPackageReference Include="Microsoft.CodeAnalysis.BannedApiAnalyzers" Version="$(MicrosoftCodeAnalysisBannedApiAnalyzersVersion)" />
</ItemGroup>
</Project>

View file

@ -0,0 +1,50 @@
From b7f0c8d910b5fa110be7f34816c4934f61643d08 Mon Sep 17 00:00:00 2001
From: Chris Rummel <crummel@microsoft.com>
Date: Wed, 20 Oct 2021 15:19:29 -0500
Subject: [PATCH] Restore building all TFMs for source-build
Required for omnisharp, nuget-client, templating, sdk
Background Issue: https://github.com/dotnet/source-build/issues/2542
Patch removal issue: https://github.com/dotnet/source-build/issues/2556
---
src/Build/Microsoft.Build.csproj | 3 +--
src/Directory.Build.props | 3 +--
2 files changed, 2 insertions(+), 4 deletions(-)
diff --git a/src/Build/Microsoft.Build.csproj b/src/Build/Microsoft.Build.csproj
index f75408633..8dc86355a 100644
--- a/src/Build/Microsoft.Build.csproj
+++ b/src/Build/Microsoft.Build.csproj
@@ -4,8 +4,7 @@
<Import Project="..\Shared\DebuggingSources.proj" />
<PropertyGroup>
- <TargetFrameworks>net6.0</TargetFrameworks>
- <TargetFrameworks Condition="$([MSBuild]::IsOSPlatform('windows'))">$(FullFrameworkTFM);net6.0</TargetFrameworks>
+ <TargetFrameworks>$(FullFrameworkTFM);net6.0</TargetFrameworks>
<TargetFrameworks Condition="'$(MonoBuild)'=='true'">$(RuntimeOutputTargetFrameworks)</TargetFrameworks>
<RootNamespace>Microsoft.Build</RootNamespace>
<AssemblyName>Microsoft.Build</AssemblyName>
diff --git a/src/Directory.Build.props b/src/Directory.Build.props
index b0e233194..7e0c7d8c8 100644
--- a/src/Directory.Build.props
+++ b/src/Directory.Build.props
@@ -27,13 +27,12 @@
<!-- Defaults for target frameworks and architecture -->
<LibraryTargetFrameworks>$(FullFrameworkTFM);netstandard2.0</LibraryTargetFrameworks>
- <LibraryTargetFrameworks Condition="'$(DotNetBuildFromSource)' == 'true'">netstandard2.0</LibraryTargetFrameworks>
<LibraryTargetFrameworks Condition="'$(MonoBuild)'=='true'">$(FullFrameworkTFM)</LibraryTargetFrameworks>
<PlatformTarget>AnyCPU</PlatformTarget>
<!-- Target frameworks for Exe and unit test projects (ie projects with runtime output) -->
<RuntimeOutputTargetFrameworks>net6.0</RuntimeOutputTargetFrameworks>
- <RuntimeOutputTargetFrameworks Condition="$([MSBuild]::IsOSPlatform('windows')) and '$(DotNetBuildFromSource)' != 'true'">$(FullFrameworkTFM);$(RuntimeOutputTargetFrameworks)</RuntimeOutputTargetFrameworks>
+ <RuntimeOutputTargetFrameworks Condition="$([MSBuild]::IsOSPlatform('windows'))">$(FullFrameworkTFM);$(RuntimeOutputTargetFrameworks)</RuntimeOutputTargetFrameworks>
<RuntimeOutputTargetFrameworks Condition="'$(MonoBuild)' == 'true'">$(FullFrameworkTFM)</RuntimeOutputTargetFrameworks>
<!-- Don't automatically append target framework to output path, since we want to put the Platform Target beforehand, if it's not AnyCPU -->
--
2.31.1

View file

@ -0,0 +1,104 @@
From a75f4b17c3595079f69ea00041182368adea14c9 Mon Sep 17 00:00:00 2001
From: dseefeld <dseefeld@microsoft.com>
Date: Wed, 20 Oct 2021 21:49:51 +0000
Subject: [PATCH] Remove dependency on MS.VS.Setup.Configuration.Interop
Removes prebuilts.
Background Issue: https://github.com/dotnet/source-build/issues/2542
---
eng/Packages.props | 3 ---
src/Build/Microsoft.Build.csproj | 4 +++-
src/Directory.BeforeCommon.targets | 2 +-
src/Samples/Directory.Build.props | 1 +
src/Tasks/Microsoft.Build.Tasks.csproj | 4 +++-
src/Utilities/Microsoft.Build.Utilities.csproj | 2 +-
6 files changed, 9 insertions(+), 7 deletions(-)
diff --git a/eng/Packages.props b/eng/Packages.props
index 2de607c5d..1668addc9 100644
--- a/eng/Packages.props
+++ b/eng/Packages.props
@@ -46,9 +46,6 @@
<ItemGroup Condition="'$(DotNetBuildFromSource)' != 'true'">
<GlobalPackageReference Include="Microsoft.NETFramework.ReferenceAssemblies" Version="1.0.0" PrivateAssets="All"/>
<GlobalPackageReference Include="Microsoft.CodeAnalysis.BannedApiAnalyzers" Version="$(MicrosoftCodeAnalysisBannedApiAnalyzersVersion)" />
- </ItemGroup>
-
- <ItemGroup>
<GlobalPackageReference Include="Microsoft.VisualStudio.SDK.EmbedInteropTypes" Version="15.0.15" PrivateAssets="All" Condition="'$(TargetFrameworkIdentifier)' == '.NETFramework'" />
</ItemGroup>
diff --git a/src/Build/Microsoft.Build.csproj b/src/Build/Microsoft.Build.csproj
index d08e337c5..3b173aee5 100644
--- a/src/Build/Microsoft.Build.csproj
+++ b/src/Build/Microsoft.Build.csproj
@@ -38,8 +38,10 @@
<PackageReference Include="System.Reflection.Metadata" Condition="'$(MonoBuild)' == 'true'" />
</ItemGroup>
- <ItemGroup Condition="'$(TargetFrameworkIdentifier)' == '.NETFramework'">
+ <ItemGroup Condition="'$(TargetFrameworkIdentifier)' == '.NETFramework' and '$(DotNetBuildFromSource)' != 'true'">
<PackageReference Include="Microsoft.VisualStudio.Setup.Configuration.Interop" />
+ </ItemGroup>
+ <ItemGroup Condition="'$(TargetFrameworkIdentifier)' == '.NETFramework'">
<Reference Include="System.IO.Compression" />
<PackageReference Include="System.Memory" />
</ItemGroup>
diff --git a/src/Directory.BeforeCommon.targets b/src/Directory.BeforeCommon.targets
index 913c97b12..320bffa56 100644
--- a/src/Directory.BeforeCommon.targets
+++ b/src/Directory.BeforeCommon.targets
@@ -99,7 +99,7 @@
<DefineConstants>$(DefineConstants);FEATURE_DEBUGGER</DefineConstants>
<DefineConstants Condition="'$(MachineIndependentBuild)' != 'true'">$(DefineConstants);FEATURE_WIN32_REGISTRY</DefineConstants>
<DefineConstants>$(DefineConstants);FEATURE_WORKINGSET</DefineConstants>
- <DefineConstants Condition="'$(MonoBuild)' != 'true' and '$(MachineIndependentBuild)' != 'true' and '$(TargetFrameworkVersion)' != 'v3.5'">$(DefineConstants);FEATURE_VISUALSTUDIOSETUP</DefineConstants>
+ <DefineConstants Condition="'$(MonoBuild)' != 'true' and '$(MachineIndependentBuild)' != 'true' and '$(TargetFrameworkVersion)' != 'v3.5' and '$(DotNetBuildFromSource)' != 'true'">$(DefineConstants);FEATURE_VISUALSTUDIOSETUP</DefineConstants>
<DefineConstants>$(DefineConstants);FEATURE_MSCOREE</DefineConstants>
</PropertyGroup>
diff --git a/src/Samples/Directory.Build.props b/src/Samples/Directory.Build.props
index 6b9d6cd9f..317ef14a6 100644
--- a/src/Samples/Directory.Build.props
+++ b/src/Samples/Directory.Build.props
@@ -8,6 +8,7 @@
<EnableCentralPackageVersions>false</EnableCentralPackageVersions>
<IsShipping>false</IsShipping>
+ <ExcludeFromSourceBuild>true</ExcludeFromSourceBuild>
</PropertyGroup>
<!-- Import parent props -->
diff --git a/src/Tasks/Microsoft.Build.Tasks.csproj b/src/Tasks/Microsoft.Build.Tasks.csproj
index d8f81bf99..3a5514094 100644
--- a/src/Tasks/Microsoft.Build.Tasks.csproj
+++ b/src/Tasks/Microsoft.Build.Tasks.csproj
@@ -999,8 +999,10 @@
<PackageReference Include="Microsoft.Net.Compilers.Toolset" ExcludeAssets="all" Condition="'$(UsingToolMicrosoftNetCompilers)' == 'false'" />
</ItemGroup>
- <ItemGroup Condition="'$(TargetFrameworkIdentifier)' == '.NETFramework'">
+ <ItemGroup Condition="'$(TargetFrameworkIdentifier)' == '.NETFramework' and '$(DotNetBuildFromSource)' != 'true'">
<PackageReference Include="Microsoft.VisualStudio.Setup.Configuration.Interop" />
+ </ItemGroup>
+ <ItemGroup Condition="'$(TargetFrameworkIdentifier)' == '.NETFramework'">
<PackageReference Include="System.Threading.Tasks.Dataflow" />
<Content Include="$(NuGetPackageRoot)microsoft.net.compilers.toolset\$(MicrosoftNetCompilersToolsetVersion)\tasks\net472\**\*" CopyToOutputDirectory="PreserveNewest" LinkBase="Roslyn" />
diff --git a/src/Utilities/Microsoft.Build.Utilities.csproj b/src/Utilities/Microsoft.Build.Utilities.csproj
index 09634e723..72d838d9d 100644
--- a/src/Utilities/Microsoft.Build.Utilities.csproj
+++ b/src/Utilities/Microsoft.Build.Utilities.csproj
@@ -25,7 +25,7 @@
<PackageReference Include="System.Configuration.ConfigurationManager" />
</ItemGroup>
- <ItemGroup Condition="'$(TargetFrameworkIdentifier)' != '.NETStandard'">
+ <ItemGroup Condition="'$(TargetFrameworkIdentifier)' != '.NETStandard' and '$(DotNetBuildFromSource)' != 'true'">
<PackageReference Include="Microsoft.VisualStudio.Setup.Configuration.Interop" />
</ItemGroup>
--
2.31.1

View file

@ -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

View file

@ -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

View file

@ -1,53 +0,0 @@
From e0e1d72dfa8881244a76c3dbcc63aa73c05546f4 Mon Sep 17 00:00:00 2001
From: Michael Simons <msimons@microsoft.com>
Date: Tue, 17 Aug 2021 21:13:07 +0000
Subject: [PATCH] Update netcoreapp TFMs to 6.0
---
build/common.project.props | 10 +++++-----
build/common.targets | 2 +-
2 files changed, 6 insertions(+), 6 deletions(-)
diff --git a/build/common.project.props b/build/common.project.props
index 80433ed60..8acc4e0bb 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>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 cf5a70c62..8827686a7 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>
--
2.29.2

View file

@ -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

View file

@ -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

View file

@ -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

View file

@ -1,25 +0,0 @@
From 612f18bace3320572dc69b3ee56c0d942c29331f Mon Sep 17 00:00:00 2001
From: Chris Rummel <crummel@microsoft.com>
Date: Fri, 20 Aug 2021 15:30:52 -0500
Subject: [PATCH] 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 65f261dc1..ed81ecf24 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>
<TargetFrameworks Condition="'$(IsBuildOnlyXPLATProjects)' != 'true'">$(TargetFrameworks);net40</TargetFrameworks>
<TargetFramework />
<NoWarn>$(NoWarn);CS1591;CS1574;CS1573</NoWarn>
--
2.18.0

View file

@ -1,35 +0,0 @@
From d0596ee04233142bbaa9b3587f2c8b3a0bd82f8f Mon Sep 17 00:00:00 2001
From: Michael Simons <msimons@microsoft.com>
Date: Fri, 27 Aug 2021 01:52:56 +0000
Subject: [PATCH] NuGet.Build.Tasks.Pack source-build support
---
.../NuGet.Build.Tasks.Pack/NuGet.Build.Tasks.Pack.csproj | 9 ++++++---
1 file changed, 6 insertions(+), 3 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 f11dd752b..c7425dbe8 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)' == '$(NetStandardVersion)'">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.29.2

View file

@ -0,0 +1,43 @@
From 7f35d623761748721496abcbae2d6f11d4cf1ca8 Mon Sep 17 00:00:00 2001
From: Chris Rummel <crummel@microsoft.com>
Date: Fri, 22 Oct 2021 21:12:51 -0500
Subject: [PATCH] Re-enable fullfx TFM in NuGet.
---
build/common.project.props | 3 +--
.../NuGet.Build.Tasks.Pack/NuGet.Build.Tasks.Pack.csproj | 2 +-
2 files changed, 2 insertions(+), 3 deletions(-)
diff --git a/build/common.project.props b/build/common.project.props
index 000702f58..b29968eaf 100644
--- a/build/common.project.props
+++ b/build/common.project.props
@@ -18,11 +18,10 @@
<IsBuildOnlyXPLATProjects>$(DotNetBuildFromSource)</IsBuildOnlyXPLATProjects>
<NetStandardVersion>netstandard2.0;net6.0</NetStandardVersion>
<TargetFrameworksExe>$(NETFXTargetFramework);$(NETCoreTargetFramework)</TargetFrameworksExe>
- <TargetFrameworksExe Condition="'$(IsBuildOnlyXPLATProjects)' == 'true' OR '$(IsXPlat)' == 'true'">$(NETCoreTargetFramework)</TargetFrameworksExe>
+ <TargetFrameworksExe Condition="'$(IsXPlat)' == 'true'">$(NETCoreTargetFramework)</TargetFrameworksExe>
<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);net6.0</TargetFrameworksLibraryForSigning>
<TargetFrameworksLibraryForCrossVerificationTests>$(NETFXTargetFramework);netcoreapp5.0</TargetFrameworksLibraryForCrossVerificationTests>
<RepositoryRootDirectory>$([MSBuild]::GetDirectoryNameOfFileAbove($(MSBuildThisFileDirectory), 'README.md'))\</RepositoryRootDirectory>
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 f4d083e52..c4eb79b4c 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
@@ -176,7 +176,7 @@
<PropertyGroup>
<!-- 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)' == '$(NETFXTargetFramework)'">Desktop/</PackagePathDir>
<PackagePathDir Condition="'$(TargetFramework)' == 'netstandard2.0'">CoreCLR/</PackagePathDir>
</PropertyGroup>
<ItemGroup>
--
2.31.1

View file

@ -0,0 +1,211 @@
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
From: Eric Erhardt <eric.erhardt@microsoft.com>
Date: Tue, 19 Oct 2021 11:12:25 -0500
Subject: [PATCH] Eliminate pre-built assets during source-build for
roslyn-analyzers
This is taking the approach used in previous versions of source-build: update the dependency versions of Microsoft.CodeAnalysis to the version currently being built by source-build. This is a short-term solution to get unblocked in the 6.0.0 timeframe. In the future, the previous Microsoft.CodeAnalysis versions will be available in SBRP.
* Remove SourceBuildPackageVersionPropsPath at the top of Versions.props. The PVP from source-build will be imported after the repo's Versions.props
* Workaround a naming collison with DocumentBasedFixAllProvider. The latest Roslyn has a class with the same name.
* Remove hard-coded versions to Microsoft.CodeAnalysis in ResxSourceGenerator, Roslyn.Diagnostics.Analyzers, and GenerateDocumentationAndConfigFiles, so the latest gets picked up.
* Exclude ReleaseNotesUtil from source-build since it brings in the 3.1 app host. This tool shouldn't be needed during source-build.
* Disable BannedApiAnalyzers when in source-build. Other previously built code analysis packages are disabled already.
Contributes to https://github.com/dotnet/source-build/issues/2420
Contributes to https://github.com/dotnet/source-build/issues/2527
---
eng/Versions.props | 14 --------------
src/Directory.Build.targets | 5 +++--
.../Core/MetaAnalyzers/Fixers/PreferIsKindFix.cs | 2 +-
....CodeAnalysis.ResxSourceGenerator.CSharp.csproj | 1 -
...Analysis.ResxSourceGenerator.VisualBasic.csproj | 1 -
...crosoft.CodeAnalysis.ResxSourceGenerator.csproj | 1 -
.../DoNotDirectlyAwaitATask.Fixer.cs | 2 +-
.../Roslyn.Diagnostics.CSharp.Analyzers.csproj | 2 +-
.../Core/Roslyn.Diagnostics.Analyzers.csproj | 1 -
...Roslyn.Diagnostics.VisualBasic.Analyzers.vbproj | 2 +-
.../GenerateDocumentationAndConfigFiles.csproj | 1 -
...umentationAndConfigFilesForBrokenRuntime.csproj | 4 +---
src/Tools/ReleaseNotesUtil/ReleaseNotesUtil.csproj | 1 +
13 files changed, 9 insertions(+), 28 deletions(-)
diff --git a/eng/Versions.props b/eng/Versions.props
index 46d30b3bd..635f8bb5c 100644
--- a/eng/Versions.props
+++ b/eng/Versions.props
@@ -1,18 +1,4 @@
<Project>
- <Import Project="$(SourceBuildPackageVersionPropsPath)" Condition="'$(SourceBuildPackageVersionPropsPath)' != ''" />
- <PropertyGroup>
- <!--
- Binaries that need to be executable during source build are restricted to versions available within source build.
- This section defines executable versions of packages which are referenced via lower-version reference assemblies
- during the build.
- -->
- <SystemCollectionsImmutableExecutableVersion>$(SystemCollectionsImmutableVersion)</SystemCollectionsImmutableExecutableVersion>
- <SystemCollectionsImmutableExecutableVersion Condition="'$(SystemCollectionsImmutableExecutableVersion)' == ''">5.0.0</SystemCollectionsImmutableExecutableVersion>
- <SystemReflectionMetadataExecutableVersion>$(SystemReflectionMetadataVersion)</SystemReflectionMetadataExecutableVersion>
- <SystemReflectionMetadataExecutableVersion Condition="'$(SystemReflectionMetadataExecutableVersion)' == ''">5.0.0</SystemReflectionMetadataExecutableVersion>
- <MicrosoftCodeAnalysisExecutableVersion>$(MicrosoftCodeAnalysisVersion)</MicrosoftCodeAnalysisExecutableVersion>
- <MicrosoftCodeAnalysisExecutableVersion Condition="'$(MicrosoftCodeAnalysisExecutableVersion)' == ''">3.8.0</MicrosoftCodeAnalysisExecutableVersion>
- </PropertyGroup>
<PropertyGroup>
<VersionPrefix>3.3.3</VersionPrefix>
<PreReleaseVersionLabel>beta1</PreReleaseVersionLabel>
diff --git a/src/Directory.Build.targets b/src/Directory.Build.targets
index c7c28fd9f..e5be9e028 100644
--- a/src/Directory.Build.targets
+++ b/src/Directory.Build.targets
@@ -35,8 +35,9 @@
<Link>AnalyzerReleases\$(AssemblyName)\AnalyzerReleases.Shipped.md</Link>
</None>
</ItemGroup>
-
- <ItemGroup>
+
+ <!-- Disable code analysis for source build -->
+ <ItemGroup Condition="'$(DotNetBuildFromSource)' != 'true'">
<PackageReference Include="Microsoft.CodeAnalysis.BannedApiAnalyzers" Version="$(MicrosoftCodeAnalysisBannedApiAnalyzersVersion)" />
<AdditionalFiles Include="$(MSBuildThisFileDirectory)\BannedSymbols.txt" Condition="'$(BannedSymbolsOptOut)' != 'true'" />
</ItemGroup>
diff --git a/src/Microsoft.CodeAnalysis.Analyzers/Core/MetaAnalyzers/Fixers/PreferIsKindFix.cs b/src/Microsoft.CodeAnalysis.Analyzers/Core/MetaAnalyzers/Fixers/PreferIsKindFix.cs
index 7a6877e0e..a0cbd06e7 100644
--- a/src/Microsoft.CodeAnalysis.Analyzers/Core/MetaAnalyzers/Fixers/PreferIsKindFix.cs
+++ b/src/Microsoft.CodeAnalysis.Analyzers/Core/MetaAnalyzers/Fixers/PreferIsKindFix.cs
@@ -48,7 +48,7 @@ private async Task<Document> ConvertKindToIsKindAsync(Document document, TextSpa
protected abstract void FixDiagnostic(DocumentEditor editor, SyntaxNode nodeToFix);
- private sealed class CustomFixAllProvider : DocumentBasedFixAllProvider
+ private sealed class CustomFixAllProvider : Analyzer.Utilities.DocumentBasedFixAllProvider
{
private readonly PreferIsKindFix _fixer;
diff --git a/src/Microsoft.CodeAnalysis.ResxSourceGenerator/Microsoft.CodeAnalysis.ResxSourceGenerator.CSharp/Microsoft.CodeAnalysis.ResxSourceGenerator.CSharp.csproj b/src/Microsoft.CodeAnalysis.ResxSourceGenerator/Microsoft.CodeAnalysis.ResxSourceGenerator.CSharp/Microsoft.CodeAnalysis.ResxSourceGenerator.CSharp.csproj
index 114e30a43..e38f8549f 100644
--- a/src/Microsoft.CodeAnalysis.ResxSourceGenerator/Microsoft.CodeAnalysis.ResxSourceGenerator.CSharp/Microsoft.CodeAnalysis.ResxSourceGenerator.CSharp.csproj
+++ b/src/Microsoft.CodeAnalysis.ResxSourceGenerator/Microsoft.CodeAnalysis.ResxSourceGenerator.CSharp/Microsoft.CodeAnalysis.ResxSourceGenerator.CSharp.csproj
@@ -7,7 +7,6 @@
<!-- Avoid ID conflicts with the package project. -->
<PackageId>*$(MSBuildProjectFile)*</PackageId>
- <MicrosoftCodeAnalysisVersion>3.9.0</MicrosoftCodeAnalysisVersion>
</PropertyGroup>
<ItemGroup>
diff --git a/src/Microsoft.CodeAnalysis.ResxSourceGenerator/Microsoft.CodeAnalysis.ResxSourceGenerator.VisualBasic/Microsoft.CodeAnalysis.ResxSourceGenerator.VisualBasic.csproj b/src/Microsoft.CodeAnalysis.ResxSourceGenerator/Microsoft.CodeAnalysis.ResxSourceGenerator.VisualBasic/Microsoft.CodeAnalysis.ResxSourceGenerator.VisualBasic.csproj
index a44df8a50..cba084cd5 100644
--- a/src/Microsoft.CodeAnalysis.ResxSourceGenerator/Microsoft.CodeAnalysis.ResxSourceGenerator.VisualBasic/Microsoft.CodeAnalysis.ResxSourceGenerator.VisualBasic.csproj
+++ b/src/Microsoft.CodeAnalysis.ResxSourceGenerator/Microsoft.CodeAnalysis.ResxSourceGenerator.VisualBasic/Microsoft.CodeAnalysis.ResxSourceGenerator.VisualBasic.csproj
@@ -7,7 +7,6 @@
<!-- Avoid ID conflicts with the package project. -->
<PackageId>*$(MSBuildProjectFile)*</PackageId>
- <MicrosoftCodeAnalysisVersion>3.9.0</MicrosoftCodeAnalysisVersion>
</PropertyGroup>
<ItemGroup>
diff --git a/src/Microsoft.CodeAnalysis.ResxSourceGenerator/Microsoft.CodeAnalysis.ResxSourceGenerator/Microsoft.CodeAnalysis.ResxSourceGenerator.csproj b/src/Microsoft.CodeAnalysis.ResxSourceGenerator/Microsoft.CodeAnalysis.ResxSourceGenerator/Microsoft.CodeAnalysis.ResxSourceGenerator.csproj
index 46a4fca6b..c9fa15584 100644
--- a/src/Microsoft.CodeAnalysis.ResxSourceGenerator/Microsoft.CodeAnalysis.ResxSourceGenerator/Microsoft.CodeAnalysis.ResxSourceGenerator.csproj
+++ b/src/Microsoft.CodeAnalysis.ResxSourceGenerator/Microsoft.CodeAnalysis.ResxSourceGenerator/Microsoft.CodeAnalysis.ResxSourceGenerator.csproj
@@ -7,7 +7,6 @@
<!-- Avoid ID conflicts with the package project. -->
<PackageId>*$(MSBuildProjectFile)*</PackageId>
- <MicrosoftCodeAnalysisVersion>3.9.0</MicrosoftCodeAnalysisVersion>
</PropertyGroup>
<ItemGroup>
diff --git a/src/NetAnalyzers/Core/Microsoft.CodeQuality.Analyzers/ApiDesignGuidelines/DoNotDirectlyAwaitATask.Fixer.cs b/src/NetAnalyzers/Core/Microsoft.CodeQuality.Analyzers/ApiDesignGuidelines/DoNotDirectlyAwaitATask.Fixer.cs
index 738fdebf2..6d13947ce 100644
--- a/src/NetAnalyzers/Core/Microsoft.CodeQuality.Analyzers/ApiDesignGuidelines/DoNotDirectlyAwaitATask.Fixer.cs
+++ b/src/NetAnalyzers/Core/Microsoft.CodeQuality.Analyzers/ApiDesignGuidelines/DoNotDirectlyAwaitATask.Fixer.cs
@@ -82,7 +82,7 @@ private class MyCodeAction : DocumentChangeAction
}
}
- private sealed class CustomFixAllProvider : DocumentBasedFixAllProvider
+ private sealed class CustomFixAllProvider : Analyzer.Utilities.DocumentBasedFixAllProvider
{
public static readonly CustomFixAllProvider Instance = new();
diff --git a/src/Roslyn.Diagnostics.Analyzers/CSharp/Roslyn.Diagnostics.CSharp.Analyzers.csproj b/src/Roslyn.Diagnostics.Analyzers/CSharp/Roslyn.Diagnostics.CSharp.Analyzers.csproj
index e62266894..b858d7097 100644
--- a/src/Roslyn.Diagnostics.Analyzers/CSharp/Roslyn.Diagnostics.CSharp.Analyzers.csproj
+++ b/src/Roslyn.Diagnostics.Analyzers/CSharp/Roslyn.Diagnostics.CSharp.Analyzers.csproj
@@ -10,7 +10,7 @@
<InternalsVisibleTo Include="Roslyn.Diagnostics.Analyzers.UnitTests" />
</ItemGroup>
<ItemGroup>
- <PackageReference Include="Microsoft.CodeAnalysis.CSharp.Workspaces" Version="$(MicrosoftCodeAnalysisForRoslynDiagnosticsAnalyzersVersion)" />
+ <PackageReference Include="Microsoft.CodeAnalysis.CSharp.Workspaces" Version="$(MicrosoftCodeAnalysisVersion)" />
</ItemGroup>
<Import Project="..\..\Utilities\Refactoring.CSharp\Refactoring.CSharp.Utilities.projitems" Label="Shared" />
</Project>
\ No newline at end of file
diff --git a/src/Roslyn.Diagnostics.Analyzers/Core/Roslyn.Diagnostics.Analyzers.csproj b/src/Roslyn.Diagnostics.Analyzers/Core/Roslyn.Diagnostics.Analyzers.csproj
index 60450aee0..3489028d4 100644
--- a/src/Roslyn.Diagnostics.Analyzers/Core/Roslyn.Diagnostics.Analyzers.csproj
+++ b/src/Roslyn.Diagnostics.Analyzers/Core/Roslyn.Diagnostics.Analyzers.csproj
@@ -7,7 +7,6 @@
Restore would conclude that there is a cyclic dependency between us and the Roslyn.Diagnostics.Analyzers package.
-->
<PackageId>*$(MSBuildProjectFile)*</PackageId>
- <MicrosoftCodeAnalysisVersion>$(MicrosoftCodeAnalysisForRoslynDiagnosticsAnalyzersVersion)</MicrosoftCodeAnalysisVersion>
</PropertyGroup>
<ItemGroup>
<InternalsVisibleTo Include="Roslyn.Diagnostics.CSharp.Analyzers" />
diff --git a/src/Roslyn.Diagnostics.Analyzers/VisualBasic/Roslyn.Diagnostics.VisualBasic.Analyzers.vbproj b/src/Roslyn.Diagnostics.Analyzers/VisualBasic/Roslyn.Diagnostics.VisualBasic.Analyzers.vbproj
index 509a3c069..737a2cf24 100644
--- a/src/Roslyn.Diagnostics.Analyzers/VisualBasic/Roslyn.Diagnostics.VisualBasic.Analyzers.vbproj
+++ b/src/Roslyn.Diagnostics.Analyzers/VisualBasic/Roslyn.Diagnostics.VisualBasic.Analyzers.vbproj
@@ -7,7 +7,7 @@
<ProjectReference Include="..\Core\Roslyn.Diagnostics.Analyzers.csproj" />
</ItemGroup>
<ItemGroup>
- <PackageReference Include="Microsoft.CodeAnalysis.VisualBasic.Workspaces" Version="$(MicrosoftCodeAnalysisForRoslynDiagnosticsAnalyzersVersion)" />
+ <PackageReference Include="Microsoft.CodeAnalysis.VisualBasic.Workspaces" Version="$(MicrosoftCodeAnalysisVersion)" />
</ItemGroup>
<Import Project="..\..\Utilities\Refactoring.VisualBasic\Refactoring.VisualBasic.Utilities.projitems" Label="Shared" />
</Project>
\ No newline at end of file
diff --git a/src/Tools/GenerateDocumentationAndConfigFiles/GenerateDocumentationAndConfigFiles.csproj b/src/Tools/GenerateDocumentationAndConfigFiles/GenerateDocumentationAndConfigFiles.csproj
index c00a9ab5d..74f5f4d5a 100644
--- a/src/Tools/GenerateDocumentationAndConfigFiles/GenerateDocumentationAndConfigFiles.csproj
+++ b/src/Tools/GenerateDocumentationAndConfigFiles/GenerateDocumentationAndConfigFiles.csproj
@@ -5,7 +5,6 @@
<NonShipping>true</NonShipping>
<UseAppHost>false</UseAppHost>
<AutoGenerateBindingRedirects>true</AutoGenerateBindingRedirects>
- <MicrosoftCodeAnalysisVersion>$(MicrosoftCodeAnalysisForRoslynDiagnosticsAnalyzersVersion)</MicrosoftCodeAnalysisVersion>
</PropertyGroup>
<ItemGroup>
<Compile Include="..\..\Microsoft.CodeAnalysis.Analyzers\Core\MetaAnalyzers\ReleaseTrackingHelper.cs" Link="ReleaseTrackingHelper.cs" />
diff --git a/src/Tools/GenerateDocumentationAndConfigFilesForBrokenRuntime/GenerateDocumentationAndConfigFilesForBrokenRuntime.csproj b/src/Tools/GenerateDocumentationAndConfigFilesForBrokenRuntime/GenerateDocumentationAndConfigFilesForBrokenRuntime.csproj
index fa2233feb..f19ae8d4d 100644
--- a/src/Tools/GenerateDocumentationAndConfigFilesForBrokenRuntime/GenerateDocumentationAndConfigFilesForBrokenRuntime.csproj
+++ b/src/Tools/GenerateDocumentationAndConfigFilesForBrokenRuntime/GenerateDocumentationAndConfigFilesForBrokenRuntime.csproj
@@ -12,8 +12,6 @@
</ItemGroup>
<ItemGroup>
- <PackageReference Include="Microsoft.CodeAnalysis" Version="$(MicrosoftCodeAnalysisExecutableVersion)" />
- <PackageReference Include="System.Collections.Immutable" Version="$(SystemCollectionsImmutableExecutableVersion)" />
- <PackageReference Include="System.Reflection.Metadata" Version="$(SystemReflectionMetadataExecutableVersion)" />
+ <PackageReference Include="Microsoft.CodeAnalysis" Version="$(MicrosoftCodeAnalysisVersion)" />
</ItemGroup>
</Project>
diff --git a/src/Tools/ReleaseNotesUtil/ReleaseNotesUtil.csproj b/src/Tools/ReleaseNotesUtil/ReleaseNotesUtil.csproj
index fe90e93ca..01b64e055 100644
--- a/src/Tools/ReleaseNotesUtil/ReleaseNotesUtil.csproj
+++ b/src/Tools/ReleaseNotesUtil/ReleaseNotesUtil.csproj
@@ -3,6 +3,7 @@
<OutputType>Exe</OutputType>
<TargetFramework>netcoreapp3.1</TargetFramework>
<NonShipping>true</NonShipping>
+ <ExcludeFromSourceBuild>true</ExcludeFromSourceBuild>
</PropertyGroup>
<ItemGroup>
<PackageReference Include="Microsoft.CodeAnalysis" Version="$(MicrosoftCodeAnalysisVersion)" />

View file

@ -1,27 +0,0 @@
From eb67cc234b0073d8b210c3ae42b5efe481bd0900 Mon Sep 17 00:00:00 2001
From: Chris Rummel <crummel@microsoft.com>
Date: Tue, 20 Jul 2021 09:41:52 -0500
Subject: [PATCH 1/2] Patch out version check for source-build scenarios.
The immediate cause for removing this was that NuGet is not yet built at this point in the source-build process. Roslyn tries to use a reference package to run this task but fails (the usual "reference packages cannot be used at runtime" error). Additionally, this is not really a valid check in source-build - we give each repo the SDK and MSBuild that we expect it to use, and want to override its opinions about what it should be using.
---
eng/targets/Imports.targets | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/eng/targets/Imports.targets b/eng/targets/Imports.targets
index 15b067deb04..303b10c40cd 100644
--- a/eng/targets/Imports.targets
+++ b/eng/targets/Imports.targets
@@ -159,7 +159,7 @@
<UsingTask TaskName="Microsoft.DotNet.Arcade.Sdk.CompareVersions" AssemblyFile="$(ArcadeSdkBuildTasksAssembly)" />
<UsingTask TaskName="Microsoft.DotNet.Arcade.Sdk.SingleError" AssemblyFile="$(ArcadeSdkBuildTasksAssembly)" />
- <Target Name="_CheckRequiredMSBuildVersion" BeforeTargets="BeforeBuild">
+ <Target Name="_CheckRequiredMSBuildVersion" BeforeTargets="BeforeBuild" Condition="'$(DotNetBuildFromSource)' != 'true'">
<CompareVersions Left="$(MSBuildVersion)" Right="$(MinimumMSBuildVersion)">
<Output TaskParameter="Result" PropertyName="_VersionComparisonResult"/>
</CompareVersions>
--
2.18.0

View file

@ -0,0 +1,25 @@
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
From: Logan Bussell <36081148+lbussell@users.noreply.github.com>
Date: Thu, 21 Oct 2021 23:15:23 +0000
Subject: [PATCH] lift version of Microsoft.CodeAnalysis.Common dependencies to
previously source built versions
---
.../Source/CSharpSyntaxGenerator/CSharpSyntaxGenerator.csproj | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/src/Tools/Source/CompilerGeneratorTools/Source/CSharpSyntaxGenerator/CSharpSyntaxGenerator.csproj b/src/Tools/Source/CompilerGeneratorTools/Source/CSharpSyntaxGenerator/CSharpSyntaxGenerator.csproj
index 7eae8afa275..a50822a6aeb 100644
--- a/src/Tools/Source/CompilerGeneratorTools/Source/CSharpSyntaxGenerator/CSharpSyntaxGenerator.csproj
+++ b/src/Tools/Source/CompilerGeneratorTools/Source/CSharpSyntaxGenerator/CSharpSyntaxGenerator.csproj
@@ -27,5 +27,9 @@
<Compile Include="..\..\..\..\..\Compilers\CSharp\Portable\Syntax\SyntaxKindFacts.cs" Link="Grammar\SyntaxKindFacts.cs" Condition="'$(TargetFramework)' != 'netstandard2.0'" />
<PackageReference Include="Microsoft.CodeAnalysis.Common" Version="$(SourceGeneratorMicrosoftCodeAnalysisVersion)" PrivateAssets="all" Condition="'$(TargetFramework)' == 'netstandard2.0'" />
+ <PackageReference Include="System.Collections.Immutable" Version="$(SourceBuildLiftedSystemCollectionsImmutableVersion)" PrivateAssets="all" Condition="'$(TargetFramework)' == 'netstandard2.0'" />
+ <PackageReference Include="System.Reflection.Metadata" Version="$(SourceBuildLiftedSystemReflectionMetadataVersion)" PrivateAssets="all" Condition="'$(TargetFramework)' == 'netstandard2.0'" />
+ <PackageReference Include="System.Runtime.CompilerServices.Unsafe" Version="$(SourceBuildLiftedSystemRuntimeCompilerServicesUnsafeVersion)" PrivateAssets="all" Condition="'$(TargetFramework)' == 'netstandard2.0'" />
+ <PackageReference Include="System.Text.Encoding.CodePages" Version="$(SourceBuildLiftedSystemTextEncodingCodePagesVersion)" PrivateAssets="all" Condition="'$(TargetFramework)' == 'netstandard2.0'" />
</ItemGroup>
</Project>
\ No newline at end of file

View file

@ -0,0 +1,33 @@
From 1a415d2019d74bcf009134326d1c25798589de64 Mon Sep 17 00:00:00 2001
From: Chris Rummel <crummel@microsoft.com>
Date: Tue, 19 Oct 2021 11:39:32 -0500
Subject: [PATCH] Apply arcade-powered source-build patches (#55823)
Don't include desktop artifacts that don't exist in source-build.
Source-build doesn't have these artifacts available, even when we eventually will
build desktop TFMs, because Roslyn is one of the first builds in source-build.
Instead Roslyn is picking up reference packages that don't have the `lib` directory
which is causing a build failure. This disables the attempt to grab these desktop
artifacts so source-build just skips them instead.
Backported to roslyn with https://github.com/dotnet/roslyn/pull/55823
---
.../DesktopCompilerArtifacts.targets | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/src/NuGet/Microsoft.Net.Compilers.Toolset/DesktopCompilerArtifacts.targets b/src/NuGet/Microsoft.Net.Compilers.Toolset/DesktopCompilerArtifacts.targets
index c8b87ab6958..107ff051b51 100644
--- a/src/NuGet/Microsoft.Net.Compilers.Toolset/DesktopCompilerArtifacts.targets
+++ b/src/NuGet/Microsoft.Net.Compilers.Toolset/DesktopCompilerArtifacts.targets
@@ -20,7 +20,7 @@
VS training data to the assemblies they produce.
-->
- <Target Name="InitializeDesktopCompilerArtifacts">
+ <Target Name="InitializeDesktopCompilerArtifacts" Condition="'$(DotNetBuildFromSource)' != 'true'">
<ItemGroup>
<!-- The Roslyn built binaries must be taken from these locations because this is the location where signing occurs -->
--
2.31.1

View file

@ -1,65 +0,0 @@
From a235579b23a9aaf3f30202a69e92b93f7c569107 Mon Sep 17 00:00:00 2001
From: Chris Rummel <crummel@microsoft.com>
Date: Tue, 20 Jul 2021 14:20:14 -0500
Subject: [PATCH 2/2] Don't include desktop artifacts that don't exist in
source-build.
This fixes a bad intersection of a couple of things going on in the source-build Roslyn build.
- Roslyn.Extensions project that builds before this normally will restore a net46 version of System.Numerics.Vectors, but it sets it to CopyLocal and is building for net472, so this net46 DLL is output to the net472 folder.
- We don't build Roslyn.Extensions for net472 for other reasons, so we are missing this DLL but not the output from that project (we just get the .NET Core folders).
- DesktopCompilerArtifacts tries to specifically call out the System.Numerics.Vectors (and some other) DLLs because they are treated differently (NGEN is not supported for them).
- So the missing DLL, instead of just being ignored because of a wildcard, comes up as error trying to build these packages.
- We want full-framework Roslyn artifacts downstream but we don't ever run the fullfx Roslyn compiler, so we need these packages but not the CopyLocal fullfx DLLs.
So we keep the net472 build for these but remove the specifically-called out artifacts that we don't need.
---
.../Microsoft.Net.Compilers.Toolset.Package.csproj | 4 ++--
.../Microsoft.Net.Compilers.Package.csproj | 6 +++---
2 files changed, 5 insertions(+), 5 deletions(-)
diff --git a/src/NuGet/Microsoft.Net.Compilers.Toolset/Microsoft.Net.Compilers.Toolset.Package.csproj b/src/NuGet/Microsoft.Net.Compilers.Toolset/Microsoft.Net.Compilers.Toolset.Package.csproj
index 9e646ebab5b..7b598978fd1 100644
--- a/src/NuGet/Microsoft.Net.Compilers.Toolset/Microsoft.Net.Compilers.Toolset.Package.csproj
+++ b/src/NuGet/Microsoft.Net.Compilers.Toolset/Microsoft.Net.Compilers.Toolset.Package.csproj
@@ -23,7 +23,7 @@
<!-- Remove NU5128 once https://github.com/NuGet/Home/issues/8583 is fixed -->
<NoWarn>$(NoWarn);NU5100;NU5128</NoWarn>
- <_DependsOn Condition="'$(TargetFramework)' == 'net472'">InitializeDesktopCompilerArtifacts</_DependsOn>
+ <_DependsOn Condition="'$(TargetFramework)' == 'net472' and '$(DotNetBuildFromSource)' != 'true'">InitializeDesktopCompilerArtifacts</_DependsOn>
<_DependsOn Condition="'$(TargetFramework)' == 'netcoreapp3.1'">InitializeCoreClrCompilerArtifacts</_DependsOn>
</PropertyGroup>
@@ -57,6 +57,6 @@
</ItemGroup>
</Target>
- <Import Project="DesktopCompilerArtifacts.targets" Condition="'$(TargetFramework)' == 'net472'" />
+ <Import Project="DesktopCompilerArtifacts.targets" Condition="'$(TargetFramework)' == 'net472' and '$(DotNetBuildFromSource)' != 'true'" />
<Import Project="CoreClrCompilerArtifacts.targets" Condition="'$(TargetFramework)' == 'netcoreapp3.1'" />
</Project>
diff --git a/src/NuGet/Microsoft.Net.Compilers/Microsoft.Net.Compilers.Package.csproj b/src/NuGet/Microsoft.Net.Compilers/Microsoft.Net.Compilers.Package.csproj
index 05f74e26ce6..c33e557c249 100644
--- a/src/NuGet/Microsoft.Net.Compilers/Microsoft.Net.Compilers.Package.csproj
+++ b/src/NuGet/Microsoft.Net.Compilers/Microsoft.Net.Compilers.Package.csproj
@@ -31,13 +31,13 @@
<Target Name="_GetFilesToPackage" DependsOnTargets="InitializeDesktopCompilerArtifacts">
<ItemGroup>
- <_File Include="@(DesktopCompilerArtifact)" TargetDir="tools"/>
- <_File Include="@(DesktopCompilerResourceArtifact)" TargetDir="tools"/>
+ <_File Include="@(DesktopCompilerArtifact)" TargetDir="tools" Condition="'$(DotNetBuildFromSource)' != 'true'" />
+ <_File Include="@(DesktopCompilerResourceArtifact)" TargetDir="tools" Condition="'$(DotNetBuildFromSource)' != 'true'" />
<_File Include="$(MSBuildProjectDirectory)\build\**\*.*" TargetDir="build" />
<TfmSpecificPackageFile Include="@(_File)" PackagePath="%(_File.TargetDir)/%(_File.RecursiveDir)%(_File.FileName)%(_File.Extension)" />
</ItemGroup>
</Target>
- <Import Project="..\Microsoft.Net.Compilers.Toolset\DesktopCompilerArtifacts.targets"/>
+ <Import Project="..\Microsoft.Net.Compilers.Toolset\DesktopCompilerArtifacts.targets" />
</Project>
--
2.18.0

View file

@ -0,0 +1,25 @@
From 7260c572b1ce424f7ff3a64aa3227417c6a7a676 Mon Sep 17 00:00:00 2001
From: Logan Bussell <36081148+lbussell@users.noreply.github.com>
Date: Fri, 8 Oct 2021 00:56:41 +0000
Subject: [PATCH] remove Microsoft.DotNet prebuilts
Pull request for applying this patch: https://github.com/dotnet/roslyn/pull/57159
---
eng/Tools.props | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/eng/Tools.props b/eng/Tools.props
index 1579b510558..944448855ee 100644
--- a/eng/Tools.props
+++ b/eng/Tools.props
@@ -1,6 +1,6 @@
<Project>
- <ItemGroup>
+ <ItemGroup Condition="'$(DotNetBuildFromSource)' != 'true'">
<!--
This package would normally be restored by the Arcade SDK, but it is not included during restore operations
if the -package flag is not also provided during the build. Roslyn separates the restore operation from the
--
2.30.2

View file

@ -0,0 +1,41 @@
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
From: Davis Goodin <dagood@microsoft.com>
Date: Tue, 19 Oct 2021 19:38:52 -0500
Subject: [PATCH] Disable apphost build of 'csi', 'vbi' for source-build
Creating an apphost for a netcoreapp3.1 project uses the apphost pack as a
prebuilt. Stopping these projects from creating the apphost removes the prebuilt
for source-build.
See: https://github.com/dotnet/roslyn/issues/57233
PR: https://github.com/dotnet/roslyn/pull/57306
---
src/Interactive/csi/csi.csproj | 1 +
src/Interactive/vbi/vbi.vbproj | 1 +
2 files changed, 2 insertions(+)
diff --git a/src/Interactive/csi/csi.csproj b/src/Interactive/csi/csi.csproj
index 3970bb4e9ea..e96beb550d2 100644
--- a/src/Interactive/csi/csi.csproj
+++ b/src/Interactive/csi/csi.csproj
@@ -6,6 +6,7 @@
<OutputType>Exe</OutputType>
<RootNamespace>CSharpInteractive</RootNamespace>
<TargetFrameworks>netcoreapp3.1;net472</TargetFrameworks>
+ <UseAppHost Condition="'$(DotNetBuildFromSource)' == 'true'">false</UseAppHost>
</PropertyGroup>
<ItemGroup Label="Project References">
<ProjectReference Include="..\..\Compilers\Core\Portable\Microsoft.CodeAnalysis.csproj" />
diff --git a/src/Interactive/vbi/vbi.vbproj b/src/Interactive/vbi/vbi.vbproj
index 5bbdf7f03a7..5f732d71534 100644
--- a/src/Interactive/vbi/vbi.vbproj
+++ b/src/Interactive/vbi/vbi.vbproj
@@ -6,6 +6,7 @@
<OutputType>Exe</OutputType>
<StartupObject>Sub Main</StartupObject>
<TargetFrameworks>netcoreapp3.1;net472</TargetFrameworks>
+ <UseAppHost Condition="'$(DotNetBuildFromSource)' == 'true'">false</UseAppHost>
<RootNamespace></RootNamespace>
</PropertyGroup>
<ItemGroup Label="Project References">

View file

@ -0,0 +1,146 @@
From 110fc28ea7c17d57bbd5ce8ed3fc4e2b0274c5b3 Mon Sep 17 00:00:00 2001
From: dseefeld <dseefeld@microsoft.com>
Date: Fri, 22 Oct 2021 22:17:37 +0000
Subject: [PATCH] Build a subset of roslyn projects
Some projects use Microsoft.NET.Sdk.WindowsDesktop sdk
which cannot be built using a boostrapped source-build
sdk, since WindowsDesktop is not supported. These cannot
be ignored using ExcludeFromSourceBuild because the project
still needs to be loaded and the sdk cannot be found.
See https://github.com/dotnet/roslyn/issues/57342
---
Roslyn.SourceBuild.slnf | 105 ++++++++++++++++++++++++++++++++++++++++
eng/SourceBuild.props | 2 +-
2 files changed, 106 insertions(+), 1 deletion(-)
create mode 100644 Roslyn.SourceBuild.slnf
diff --git a/Roslyn.SourceBuild.slnf b/Roslyn.SourceBuild.slnf
new file mode 100644
index 00000000000..e6f8eb315bf
--- /dev/null
+++ b/Roslyn.SourceBuild.slnf
@@ -0,0 +1,105 @@
+{
+ "solution": {
+ "path": "Roslyn.sln",
+ "projects": [
+ "src\\Deployment\\RoslynDeployment.csproj",
+ "src\\Compilers\\Core\\Portable\\Microsoft.CodeAnalysis.csproj",
+ "src\\Compilers\\Server\\VBCSCompiler\\VBCSCompiler.csproj",
+ "src\\Compilers\\CSharp\\csc\\csc.csproj",
+ "src\\Compilers\\CSharp\\Portable\\Microsoft.CodeAnalysis.CSharp.csproj",
+ "src\\Compilers\\VisualBasic\\Portable\\Microsoft.CodeAnalysis.VisualBasic.vbproj",
+ "src\\Workspaces\\Core\\Portable\\Microsoft.CodeAnalysis.Workspaces.csproj",
+ "src\\Tools\\Source\\CompilerGeneratorTools\\Source\\BoundTreeGenerator\\CompilersBoundTreeGenerator.csproj",
+ "src\\Tools\\Source\\CompilerGeneratorTools\\Source\\CSharpErrorFactsGenerator\\CSharpErrorFactsGenerator.csproj",
+ "src\\Tools\\Source\\CompilerGeneratorTools\\Source\\CSharpSyntaxGenerator\\CSharpSyntaxGenerator.csproj",
+ "src\\Tools\\Source\\CompilerGeneratorTools\\Source\\VisualBasicSyntaxGenerator\\VisualBasicSyntaxGenerator.vbproj",
+ "src\\Tools\\Source\\CompilerGeneratorTools\\Source\\VisualBasicErrorFactsGenerator\\VisualBasicErrorFactsGenerator.vbproj",
+ "src\\Workspaces\\Core\\Desktop\\Microsoft.CodeAnalysis.Workspaces.Desktop.csproj",
+ "src\\Workspaces\\Core\\MSBuild\\Microsoft.CodeAnalysis.Workspaces.MSBuild.csproj",
+ "src\\Workspaces\\CSharp\\Portable\\Microsoft.CodeAnalysis.CSharp.Workspaces.csproj",
+ "src\\Workspaces\\VisualBasic\\Portable\\Microsoft.CodeAnalysis.VisualBasic.Workspaces.vbproj",
+ "src\\Features\\VisualBasic\\Portable\\Microsoft.CodeAnalysis.VisualBasic.Features.vbproj",
+ "src\\Features\\CSharp\\Portable\\Microsoft.CodeAnalysis.CSharp.Features.csproj",
+ "src\\Features\\Core\\Portable\\Microsoft.CodeAnalysis.Features.csproj",
+ "src\\Scripting\\VisualBasic\\Microsoft.CodeAnalysis.VisualBasic.Scripting.vbproj",
+ "src\\Scripting\\Core\\Microsoft.CodeAnalysis.Scripting.csproj",
+ "src\\Scripting\\CSharp\\Microsoft.CodeAnalysis.CSharp.Scripting.csproj",
+ "src\\ExpressionEvaluator\\Package\\ExpressionEvaluatorPackage.csproj",
+ "src\\ExpressionEvaluator\\CSharp\\Source\\ExpressionCompiler\\Microsoft.CodeAnalysis.CSharp.ExpressionCompiler.csproj",
+ "src\\ExpressionEvaluator\\VisualBasic\\Source\\ExpressionCompiler\\Microsoft.CodeAnalysis.VisualBasic.ExpressionCompiler.vbproj",
+ "src\\ExpressionEvaluator\\Core\\Source\\ExpressionCompiler\\Microsoft.CodeAnalysis.ExpressionCompiler.csproj",
+ "src\\Compilers\\Core\\AnalyzerDriver\\AnalyzerDriver.shproj",
+ "src\\ExpressionEvaluator\\VisualBasic\\Source\\ResultProvider\\BasicResultProvider.shproj",
+ "src\\ExpressionEvaluator\\VisualBasic\\Source\\ResultProvider\\NetFX20\\BasicResultProvider.NetFX20.vbproj",
+ "src\\ExpressionEvaluator\\VisualBasic\\Source\\ResultProvider\\Portable\\Microsoft.CodeAnalysis.VisualBasic.ResultProvider.vbproj",
+ "src\\ExpressionEvaluator\\CSharp\\Source\\ResultProvider\\CSharpResultProvider.shproj",
+ "src\\ExpressionEvaluator\\CSharp\\Source\\ResultProvider\\NetFX20\\CSharpResultProvider.NetFX20.csproj",
+ "src\\ExpressionEvaluator\\CSharp\\Source\\ResultProvider\\Portable\\Microsoft.CodeAnalysis.CSharp.ResultProvider.csproj",
+ "src\\ExpressionEvaluator\\Core\\Source\\ResultProvider\\ResultProvider.shproj",
+ "src\\ExpressionEvaluator\\Core\\Source\\ResultProvider\\NetFX20\\ResultProvider.NetFX20.csproj",
+ "src\\ExpressionEvaluator\\Core\\Source\\ResultProvider\\Portable\\Microsoft.CodeAnalysis.ResultProvider.csproj",
+ "src\\Compilers\\VisualBasic\\vbc\\vbc.csproj",
+ "src\\Compilers\\VisualBasic\\BasicAnalyzerDriver\\BasicAnalyzerDriver.shproj",
+ "src\\Compilers\\CSharp\\CSharpAnalyzerDriver\\CSharpAnalyzerDriver.shproj",
+ "src\\Compilers\\Core\\CommandLine\\CommandLine.shproj",
+ "src\\Compilers\\Extension\\Roslyn.Compilers.Extension.csproj",
+ "src\\Dependencies\\CodeAnalysis.Debugging\\Microsoft.CodeAnalysis.Debugging.shproj",
+ "src\\Dependencies\\PooledObjects\\Microsoft.CodeAnalysis.PooledObjects.shproj",
+ "src\\Workspaces\\Remote\\Core\\Microsoft.CodeAnalysis.Remote.Workspaces.csproj",
+ "src\\Workspaces\\Remote\\ServiceHub\\Microsoft.CodeAnalysis.Remote.ServiceHub.csproj",
+ "src\\Compilers\\Core\\MSBuildTask\\Microsoft.Build.Tasks.CodeAnalysis.csproj",
+ "src\\Tools\\BuildBoss\\BuildBoss.csproj",
+ "src\\ExpressionEvaluator\\Core\\Source\\FunctionResolver\\Microsoft.CodeAnalysis.FunctionResolver.csproj",
+ "src\\CodeStyle\\Core\\Analyzers\\Microsoft.CodeAnalysis.CodeStyle.csproj",
+ "src\\CodeStyle\\Core\\CodeFixes\\Microsoft.CodeAnalysis.CodeStyle.Fixes.csproj",
+ "src\\CodeStyle\\CSharp\\Analyzers\\Microsoft.CodeAnalysis.CSharp.CodeStyle.csproj",
+ "src\\CodeStyle\\CSharp\\CodeFixes\\Microsoft.CodeAnalysis.CSharp.CodeStyle.Fixes.csproj",
+ "src\\CodeStyle\\VisualBasic\\Analyzers\\Microsoft.CodeAnalysis.VisualBasic.CodeStyle.vbproj",
+ "src\\CodeStyle\\VisualBasic\\CodeFixes\\Microsoft.CodeAnalysis.VisualBasic.CodeStyle.Fixes.vbproj",
+ "src\\Tools\\AnalyzerRunner\\AnalyzerRunner.csproj",
+ "src\\Dependencies\\CodeAnalysis.Debugging\\Microsoft.CodeAnalysis.Debugging.Package.csproj",
+ "src\\Dependencies\\PooledObjects\\Microsoft.CodeAnalysis.PooledObjects.Package.csproj",
+ "src\\NuGet\\Microsoft.Net.Compilers\\Microsoft.Net.Compilers.Package.csproj",
+ "src\\NuGet\\Microsoft.NETCore.Compilers\\Microsoft.NETCore.Compilers.Package.csproj",
+ "src\\NuGet\\Microsoft.CodeAnalysis.Compilers.Package.csproj",
+ "src\\NuGet\\Microsoft.CodeAnalysis.Scripting.Package.csproj",
+ "src\\NuGet\\Microsoft.CodeAnalysis.EditorFeatures.Package.csproj",
+ "src\\NuGet\\Microsoft.CodeAnalysis.Package.csproj",
+ "src\\Setup\\DevDivVsix\\CompilersPackage\\Microsoft.CodeAnalysis.Compilers.Setup.csproj",
+ "src\\Setup\\Installer\\Installer.Package.csproj",
+ "src\\Setup\\DevDivInsertionFiles\\DevDivInsertionFiles.csproj",
+ "src\\Tools\\ExternalAccess\\FSharp\\Microsoft.CodeAnalysis.ExternalAccess.FSharp.csproj",
+ "src\\Tools\\ExternalAccess\\Razor\\Microsoft.CodeAnalysis.ExternalAccess.Razor.csproj",
+ "src\\NuGet\\Microsoft.Net.Compilers.Toolset\\Microsoft.Net.Compilers.Toolset.Package.csproj",
+ "src\\Features\\LanguageServer\\Protocol\\Microsoft.CodeAnalysis.LanguageServer.Protocol.csproj",
+ "src\\Tools\\ExternalAccess\\Debugger\\Microsoft.CodeAnalysis.ExternalAccess.Debugger.csproj",
+ "src\\Tools\\ExternalAccess\\Xamarin.Remote\\Microsoft.CodeAnalysis.ExternalAccess.Xamarin.Remote.csproj",
+ "src\\Tools\\ExternalAccess\\Apex\\Microsoft.CodeAnalysis.ExternalAccess.Apex.csproj",
+ "src\\Tools\\IdeBenchmarks\\IdeBenchmarks.csproj",
+ "src\\Tools\\Source\\CompilerGeneratorTools\\Source\\IOperationGenerator\\CompilersIOperationGenerator.csproj",
+ "src\\Features\\Lsif\\Generator\\Microsoft.CodeAnalysis.LanguageServerIndexFormat.Generator.csproj",
+ "src\\Workspaces\\SharedUtilitiesAndExtensions\\Compiler\\Core\\CompilerExtensions.shproj",
+ "src\\Workspaces\\SharedUtilitiesAndExtensions\\Workspace\\Core\\WorkspaceExtensions.shproj",
+ "src\\Workspaces\\SharedUtilitiesAndExtensions\\Compiler\\CSharp\\CSharpCompilerExtensions.shproj",
+ "src\\Workspaces\\SharedUtilitiesAndExtensions\\Workspace\\CSharp\\CSharpWorkspaceExtensions.shproj",
+ "src\\Workspaces\\SharedUtilitiesAndExtensions\\Compiler\\VisualBasic\\VisualBasicCompilerExtensions.shproj",
+ "src\\Workspaces\\SharedUtilitiesAndExtensions\\Workspace\\VisualBasic\\VisualBasicWorkspaceExtensions.shproj",
+ "src\\Analyzers\\Core\\Analyzers\\Analyzers.shproj",
+ "src\\Analyzers\\Core\\CodeFixes\\CodeFixes.shproj",
+ "src\\Analyzers\\CSharp\\Analyzers\\CSharpAnalyzers.shproj",
+ "src\\Analyzers\\CSharp\\CodeFixes\\CSharpCodeFixes.shproj",
+ "src\\Analyzers\\VisualBasic\\Analyzers\\VisualBasicAnalyzers.shproj",
+ "src\\Analyzers\\VisualBasic\\CodeFixes\\VisualBasicCodeFixes.shproj",
+ "src\\Tools\\IdeCoreBenchmarks\\IdeCoreBenchmarks.csproj",
+ "src\\Tools\\BuildValidator\\BuildValidator.csproj",
+ "src\\Tools\\BuildActionTelemetryTable\\BuildActionTelemetryTable.csproj",
+ "src\\CodeStyle\\Tools\\CodeStyleConfigFileGenerator.csproj",
+ "src\\Dependencies\\Collections\\Microsoft.CodeAnalysis.Collections.shproj",
+ "src\\Dependencies\\Collections\\Microsoft.CodeAnalysis.Collections.Package.csproj",
+ "src\\Compilers\\Core\\Rebuild\\Microsoft.CodeAnalysis.Rebuild.csproj",
+ "src\\Tools\\ExternalAccess\\OmniSharp\\Microsoft.CodeAnalysis.ExternalAccess.OmniSharp.csproj",
+ "src\\Tools\\ExternalAccess\\OmniSharp.CSharp\\Microsoft.CodeAnalysis.ExternalAccess.OmniSharp.CSharp.csproj",
+ "src\\Workspaces\\Remote\\ServiceHub.CoreComponents\\Microsoft.CodeAnalysis.Remote.ServiceHub.CoreComponents.csproj"
+ ]
+ }
+}
\ No newline at end of file
diff --git a/eng/SourceBuild.props b/eng/SourceBuild.props
index 92e316a4744..9905b35467e 100644
--- a/eng/SourceBuild.props
+++ b/eng/SourceBuild.props
@@ -11,7 +11,7 @@
-->
<Target Name="ConfigureInnerBuildArg" BeforeTargets="GetSourceBuildCommandConfiguration">
<PropertyGroup>
- <InnerBuildArgs>$(InnerBuildArgs) /p:Projects="$(InnerSourceBuildRepoRoot)\Roslyn.sln"</InnerBuildArgs>
+ <InnerBuildArgs>$(InnerBuildArgs) /p:Projects="$(InnerSourceBuildRepoRoot)\Roslyn.SourceBuild.slnf"</InnerBuildArgs>
</PropertyGroup>
</Target>
--
2.31.1

View file

@ -0,0 +1,29 @@
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
From: Eric Erhardt <eric.erhardt@microsoft.com>
Date: Mon, 18 Oct 2021 15:47:39 -0500
Subject: [PATCH] DotNetHost packages are not created during source-build
The subset `host.pkg` is not producing the DotNetHost* NuGet packages. This is because the "Pack" target is getting invoked on the pkgprojs, but pkgprojs expect the "Build" target to be called. Since the "Pack" target is overriden in the Directory.Build.targets to be empty, no one is calling the "Build" target on the pkgprojs.
In an official build, a later subset `packs.tests` comes through and builds `Microsoft.DotNet.CoreSetup.Packaging.Tests.csproj`, which explicitly calls "Build" on the pkgprojs. So official builds still get these packages produced.
In source-build, we are no longer building the `packs.tests` subset, so the packages are not produced.
See also:
* https://github.com/dotnet/runtime/pull/60575
* https://github.com/dotnet/runtime/pull/60577
---
src/installer/Directory.Build.targets | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/src/installer/Directory.Build.targets b/src/installer/Directory.Build.targets
index c6e8cf1a140..dccb8277ba7 100644
--- a/src/installer/Directory.Build.targets
+++ b/src/installer/Directory.Build.targets
@@ -15,5 +15,5 @@
<Import Project="..\..\Directory.Build.targets" />
<!-- Provide default targets which can be hooked onto or overridden as necessary -->
- <Target Name="Pack" />
+ <Target Name="Pack" DependsOnTargets="Build" />
</Project>

View file

@ -0,0 +1,66 @@
From 3540e85a194dda1e5448e0aab3212c8aeb5a1aff Mon Sep 17 00:00:00 2001
From: Eric Erhardt <eric.erhardt@microsoft.com>
Date: Fri, 22 Oct 2021 20:48:25 +0000
Subject: [PATCH] Build Microsoft.NET.Build.Tasks for netfx
Required for omnisharp to work with a source-built .NET SDK.
Patch removal issue: https://github.com/dotnet/sdk/issues/22281
---
.../Microsoft.DotNet.Compatibility.csproj | 1 -
.../Microsoft.DotNet.PackageValidation.csproj | 1 -
.../Microsoft.NET.Build.Extensions.Tasks.csproj | 1 -
.../Microsoft.NET.Build.Tasks/Microsoft.NET.Build.Tasks.csproj | 1 -
4 files changed, 4 deletions(-)
diff --git a/src/Compatibility/Microsoft.DotNet.Compatibility/Microsoft.DotNet.Compatibility.csproj b/src/Compatibility/Microsoft.DotNet.Compatibility/Microsoft.DotNet.Compatibility.csproj
index 92624be845..f9f8e46329 100644
--- a/src/Compatibility/Microsoft.DotNet.Compatibility/Microsoft.DotNet.Compatibility.csproj
+++ b/src/Compatibility/Microsoft.DotNet.Compatibility/Microsoft.DotNet.Compatibility.csproj
@@ -2,7 +2,6 @@
<PropertyGroup>
<TargetFrameworks>net6.0;net472</TargetFrameworks>
- <TargetFrameworks Condition=" '$(DotNetBuildFromSource)' == 'true' ">net6.0</TargetFrameworks>
<IsPackable>true</IsPackable>
<IsShippingPackage>true</IsShippingPackage>
<StrongNameKeyId>Open</StrongNameKeyId>
diff --git a/src/Compatibility/Microsoft.DotNet.PackageValidation/Microsoft.DotNet.PackageValidation.csproj b/src/Compatibility/Microsoft.DotNet.PackageValidation/Microsoft.DotNet.PackageValidation.csproj
index 7a8b648652..4241f4577e 100644
--- a/src/Compatibility/Microsoft.DotNet.PackageValidation/Microsoft.DotNet.PackageValidation.csproj
+++ b/src/Compatibility/Microsoft.DotNet.PackageValidation/Microsoft.DotNet.PackageValidation.csproj
@@ -2,7 +2,6 @@
<PropertyGroup>
<TargetFrameworks>net6.0;net472</TargetFrameworks>
- <TargetFrameworks Condition=" '$(DotNetBuildFromSource)' == 'true' ">net6.0</TargetFrameworks>
<StrongNameKeyId>Open</StrongNameKeyId>
</PropertyGroup>
diff --git a/src/Tasks/Microsoft.NET.Build.Extensions.Tasks/Microsoft.NET.Build.Extensions.Tasks.csproj b/src/Tasks/Microsoft.NET.Build.Extensions.Tasks/Microsoft.NET.Build.Extensions.Tasks.csproj
index 13ada82225..280fbdc83e 100644
--- a/src/Tasks/Microsoft.NET.Build.Extensions.Tasks/Microsoft.NET.Build.Extensions.Tasks.csproj
+++ b/src/Tasks/Microsoft.NET.Build.Extensions.Tasks/Microsoft.NET.Build.Extensions.Tasks.csproj
@@ -16,7 +16,6 @@
<OutputType>Library</OutputType>
<RootNamespace>Microsoft.NET.Build.Tasks</RootNamespace>
<TargetFrameworks>$(SdkTargetFramework);net472</TargetFrameworks>
- <TargetFrameworks Condition=" '$(DotNetBuildFromSource)' == 'true' ">$(SdkTargetFramework)</TargetFrameworks>
</PropertyGroup>
<PropertyGroup>
diff --git a/src/Tasks/Microsoft.NET.Build.Tasks/Microsoft.NET.Build.Tasks.csproj b/src/Tasks/Microsoft.NET.Build.Tasks/Microsoft.NET.Build.Tasks.csproj
index 604ef43bf2..bce39c67d4 100644
--- a/src/Tasks/Microsoft.NET.Build.Tasks/Microsoft.NET.Build.Tasks.csproj
+++ b/src/Tasks/Microsoft.NET.Build.Tasks/Microsoft.NET.Build.Tasks.csproj
@@ -13,7 +13,6 @@
<Description>The MSBuild targets and properties for building .NET Core projects.</Description>
<OutputType>Library</OutputType>
<TargetFrameworks>$(SdkTargetFramework);net472</TargetFrameworks>
- <TargetFrameworks Condition=" '$(DotNetBuildFromSource)' == 'true' ">$(SdkTargetFramework)</TargetFrameworks>
<Nullable>annotations</Nullable>
</PropertyGroup>
--
2.31.1

View file

@ -1,30 +0,0 @@
From c0ec49b887cae58bb860a18982115c5910f29821 Mon Sep 17 00:00:00 2001
From: MichaelSimons <msimons@microsoft.com>
Date: Tue, 14 Sep 2021 22:54:01 +0000
Subject: [PATCH] pin nuget versions
Temporary fix for https://github.com/dotnet/source-build/issues/2455 to unblock source-build
---
Directory.Build.targets | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/Directory.Build.targets b/Directory.Build.targets
index 0dc99916..7c45fda3 100644
--- a/Directory.Build.targets
+++ b/Directory.Build.targets
@@ -12,9 +12,9 @@
<PackageReference Update="Microsoft.Extensions.Logging.Console" Version="$(MicrosoftExtensionsLoggingConsolePackageVersion)" />
<PackageReference Update="Microsoft.Extensions.Logging.Abstractions" Version="$(MicrosoftExtensionsLoggingAbstractionsPackageVersion)" />
<PackageReference Update="Newtonsoft.Json" Version="$(NewtonsoftJsonPackageVersion)" />
- <PackageReference Update="NuGet.Configuration" Version="$(NuGetConfigurationPackageVersion)" />
- <PackageReference Update="NuGet.Credentials" Version="$(NuGetCredentialsPackageVersion)" />
- <PackageReference Update="NuGet.Protocol" Version="$(NuGetProtocolPackageVersion)" />
+ <PackageReference Update="NuGet.Configuration" Version="6.0.0-preview.3.179" />
+ <PackageReference Update="NuGet.Credentials" Version="6.0.0-preview.3.179" />
+ <PackageReference Update="NuGet.Protocol" Version="6.0.0-preview.3.179" />
</ItemGroup>
<ItemGroup Condition="'$(TargetFrameworkIdentifier)' == '.NETCoreApp' AND '$(BuildingInsideVisualStudio)' != 'true'">
--
2.29.2

View file

@ -0,0 +1,27 @@
From e5fa6b10f5e4bcb14e3930e4eeae7181765529ee Mon Sep 17 00:00:00 2001
From: Chris Rummel <crummel@microsoft.com>
Date: Thu, 21 Oct 2021 16:29:32 -0500
Subject: [PATCH] Also build for netstandard2.0 to support NuGet.
Patch removal is tracked by https://github.com/dotnet/source-build/issues/2557.
---
.../Microsoft.Web.XmlTransform.csproj | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/src/Microsoft.Web.XmlTransform/Microsoft.Web.XmlTransform.csproj b/src/Microsoft.Web.XmlTransform/Microsoft.Web.XmlTransform.csproj
index 7cb81d1..f272d7f 100644
--- a/src/Microsoft.Web.XmlTransform/Microsoft.Web.XmlTransform.csproj
+++ b/src/Microsoft.Web.XmlTransform/Microsoft.Web.XmlTransform.csproj
@@ -3,7 +3,7 @@
<Import Project="$(RepositoryEngineeringDir)\Package.props" />
<PropertyGroup>
- <TargetFrameworks>netstandard2.1</TargetFrameworks>
+ <TargetFrameworks>netstandard2.0;netstandard2.1</TargetFrameworks>
<PlatformTarget>AnyCPU</PlatformTarget>
<IsPackable>true</IsPackable>
<IsShipping>false</IsShipping>
--
2.31.1

View file

@ -5,7 +5,7 @@
</head> </head>
<body> <body>
<div align="left" style="font-family: Helvetica;padding-left:10px"> <div align="left" style="font-family: Helvetica;padding-left:10px">
<p>The following was installed at /usr/local/share/dotnet</h2> <p>The following was installed</h2>
<ul> <ul>
<li>.NET SDK {DOTNETSDKVERSION}</li> <li>.NET SDK {DOTNETSDKVERSION}</li>
<li>.NET Runtime {DOTNETRUNTIMEVERSION}</li> <li>.NET Runtime {DOTNETRUNTIMEVERSION}</li>

View file

@ -5,7 +5,7 @@
</head> </head>
<body> <body>
<div align="left" style="font-family: Helvetica;padding-left:10px"> <div align="left" style="font-family: Helvetica;padding-left:10px">
<p>The following was installed at /usr/local/share/dotnet</h2> <p>The following was installed</h2>
<ul> <ul>
<li>.NET SDK {DOTNETSDKVERSION}</li> <li>.NET SDK {DOTNETSDKVERSION}</li>
<li>.NET Runtime {DOTNETRUNTIMEVERSION}</li> <li>.NET Runtime {DOTNETRUNTIMEVERSION}</li>

View file

@ -5,7 +5,7 @@
</head> </head>
<body> <body>
<div align="left" style="font-family: Helvetica;padding-left:10px"> <div align="left" style="font-family: Helvetica;padding-left:10px">
<p>The following was installed at /usr/local/share/dotnet</h2> <p>The following was installed</h2>
<ul> <ul>
<li>.NET SDK {DOTNETSDKVERSION}</li> <li>.NET SDK {DOTNETSDKVERSION}</li>
<li>.NET Runtime {DOTNETRUNTIMEVERSION}</li> <li>.NET Runtime {DOTNETRUNTIMEVERSION}</li>

View file

@ -5,7 +5,7 @@
</head> </head>
<body> <body>
<div align="left" style="font-family: Helvetica;padding-left:10px"> <div align="left" style="font-family: Helvetica;padding-left:10px">
<p>The following was installed at /usr/local/share/dotnet</h2> <p>The following was installed</h2>
<ul> <ul>
<li>.NET SDK {DOTNETSDKVERSION}</li> <li>.NET SDK {DOTNETSDKVERSION}</li>
<li>.NET Runtime {DOTNETRUNTIMEVERSION}</li> <li>.NET Runtime {DOTNETRUNTIMEVERSION}</li>

View file

@ -5,7 +5,7 @@
</head> </head>
<body> <body>
<div align="left" style="font-family: Helvetica;padding-left:10px"> <div align="left" style="font-family: Helvetica;padding-left:10px">
<p>The following was installed at /usr/local/share/dotnet</h2> <p>The following was installed</h2>
<ul> <ul>
<li>.NET SDK {DOTNETSDKVERSION}</li> <li>.NET SDK {DOTNETSDKVERSION}</li>
<li>.NET Runtime {DOTNETRUNTIMEVERSION}</li> <li>.NET Runtime {DOTNETRUNTIMEVERSION}</li>

View file

@ -5,7 +5,7 @@
</head> </head>
<body> <body>
<div align="left" style="font-family: Helvetica;padding-left:10px"> <div align="left" style="font-family: Helvetica;padding-left:10px">
<p>The following was installed at /usr/local/share/dotnet</h2> <p>The following was installed</h2>
<ul> <ul>
<li>.NET SDK {DOTNETSDKVERSION}</li> <li>.NET SDK {DOTNETSDKVERSION}</li>
<li>.NET Runtime {DOTNETRUNTIMEVERSION}</li> <li>.NET Runtime {DOTNETRUNTIMEVERSION}</li>

View file

@ -5,7 +5,7 @@
</head> </head>
<body> <body>
<div align="left" style="font-family: Helvetica;padding-left:10px"> <div align="left" style="font-family: Helvetica;padding-left:10px">
<p>The following was installed at /usr/local/share/dotnet</h2> <p>The following was installed</h2>
<ul> <ul>
<li>.NET SDK {DOTNETSDKVERSION}</li> <li>.NET SDK {DOTNETSDKVERSION}</li>
<li>.NET Runtime {DOTNETRUNTIMEVERSION}</li> <li>.NET Runtime {DOTNETRUNTIMEVERSION}</li>

View file

@ -5,7 +5,7 @@
</head> </head>
<body> <body>
<div align="left" style="font-family: Helvetica;padding-left:10px"> <div align="left" style="font-family: Helvetica;padding-left:10px">
<p>The following was installed at /usr/local/share/dotnet</h2> <p>The following was installed</h2>
<ul> <ul>
<li>.NET SDK {DOTNETSDKVERSION}</li> <li>.NET SDK {DOTNETSDKVERSION}</li>
<li>.NET Runtime {DOTNETRUNTIMEVERSION}</li> <li>.NET Runtime {DOTNETRUNTIMEVERSION}</li>

View file

@ -5,7 +5,7 @@
</head> </head>
<body> <body>
<div align="left" style="font-family: Helvetica;padding-left:10px"> <div align="left" style="font-family: Helvetica;padding-left:10px">
<p>The following was installed at /usr/local/share/dotnet</h2> <p>The following was installed</h2>
<ul> <ul>
<li>.NET SDK {DOTNETSDKVERSION}</li> <li>.NET SDK {DOTNETSDKVERSION}</li>
<li>.NET Runtime {DOTNETRUNTIMEVERSION}</li> <li>.NET Runtime {DOTNETRUNTIMEVERSION}</li>

View file

@ -5,7 +5,7 @@
</head> </head>
<body> <body>
<div align="left" style="font-family: Helvetica;padding-left:10px"> <div align="left" style="font-family: Helvetica;padding-left:10px">
<p>The following was installed at /usr/local/share/dotnet</h2> <p>The following was installed</h2>
<ul> <ul>
<li>.NET SDK {DOTNETSDKVERSION}</li> <li>.NET SDK {DOTNETSDKVERSION}</li>
<li>.NET Runtime {DOTNETRUNTIMEVERSION}</li> <li>.NET Runtime {DOTNETRUNTIMEVERSION}</li>

View file

@ -5,7 +5,7 @@
</head> </head>
<body> <body>
<div align="left" style="font-family: Helvetica;padding-left:10px"> <div align="left" style="font-family: Helvetica;padding-left:10px">
<p>The following was installed at /usr/local/share/dotnet</h2> <p>The following was installed</h2>
<ul> <ul>
<li>.NET SDK {DOTNETSDKVERSION}</li> <li>.NET SDK {DOTNETSDKVERSION}</li>
<li>.NET Runtime {DOTNETRUNTIMEVERSION}</li> <li>.NET Runtime {DOTNETRUNTIMEVERSION}</li>

View file

@ -5,7 +5,7 @@
</head> </head>
<body> <body>
<div align="left" style="font-family: Helvetica;padding-left:10px"> <div align="left" style="font-family: Helvetica;padding-left:10px">
<p>The following was installed at /usr/local/share/dotnet</h2> <p>The following was installed</h2>
<ul> <ul>
<li>.NET SDK {DOTNETSDKVERSION}</li> <li>.NET SDK {DOTNETSDKVERSION}</li>
<li>.NET Runtime {DOTNETRUNTIMEVERSION}</li> <li>.NET Runtime {DOTNETRUNTIMEVERSION}</li>

View file

@ -5,7 +5,7 @@
</head> </head>
<body> <body>
<div align="left" style="font-family: Helvetica;padding-left:10px"> <div align="left" style="font-family: Helvetica;padding-left:10px">
<p>The following was installed at /usr/local/share/dotnet</h2> <p>The following was installed</h2>
<ul> <ul>
<li>.NET SDK {DOTNETSDKVERSION}</li> <li>.NET SDK {DOTNETSDKVERSION}</li>
<li>.NET Runtime {DOTNETRUNTIMEVERSION}</li> <li>.NET Runtime {DOTNETRUNTIMEVERSION}</li>

View file

@ -5,7 +5,7 @@
</head> </head>
<body> <body>
<div align="left" style="font-family: Helvetica;padding-left:10px"> <div align="left" style="font-family: Helvetica;padding-left:10px">
<p>The following was installed at /usr/local/share/dotnet</h2> <p>The following was installed</h2>
<ul> <ul>
<li>.NET SDK {DOTNETSDKVERSION}</li> <li>.NET SDK {DOTNETSDKVERSION}</li>
<li>.NET Runtime {DOTNETRUNTIMEVERSION}</li> <li>.NET Runtime {DOTNETRUNTIMEVERSION}</li>

View file

@ -424,6 +424,13 @@ namespace EndToEnd.Tests
{ {
buildArgs += $" --framework {framework}"; buildArgs += $" --framework {framework}";
} }
// Remove this (or formalize it) after https://github.com/dotnet/installer/issues/12479 is resolved.
if (language == "F#")
{
buildArgs += $" /p:_NETCoreSdkIsPreview=true";
}
string dotnetRoot = Path.GetDirectoryName(RepoDirectoriesProvider.DotnetUnderTest); string dotnetRoot = Path.GetDirectoryName(RepoDirectoriesProvider.DotnetUnderTest);
new BuildCommand() new BuildCommand()
.WithEnvironmentVariable("PATH", dotnetRoot) // override PATH since razor rely on PATH to find dotnet .WithEnvironmentVariable("PATH", dotnetRoot) // override PATH since razor rely on PATH to find dotnet

View file

@ -163,12 +163,6 @@
<![CDATA[ <![CDATA[
<configuration> <configuration>
<packageSources> <packageSources>
<add key="dotnet-core" value="https://dotnetfeed.blob.core.windows.net/dotnet-core/index.json" />
<add key="dotnet-windowsdesktop" value="https://dotnetfeed.blob.core.windows.net/dotnet-windowsdesktop/index.json" />
<add key="aspnet-aspnetcore" value="https://dotnetfeed.blob.core.windows.net/aspnet-aspnetcore/index.json" />
<add key="aspnet-aspnetcore-tooling" value="https://dotnetfeed.blob.core.windows.net/aspnet-aspnetcore-tooling/index.json" />
<add key="aspnet-entityframeworkcore" value="https://dotnetfeed.blob.core.windows.net/aspnet-entityframeworkcore/index.json" />
<add key="aspnet-extensions" value="https://dotnetfeed.blob.core.windows.net/aspnet-extensions/index.json" />
</packageSources> </packageSources>
</configuration> </configuration>
]]> ]]>