diff --git a/patches/msbuild/0001-Update-RoslynTools-verison-to-msbuild-specific-versi.patch b/patches/msbuild/0001-Update-RoslynTools-verison-to-msbuild-specific-versi.patch deleted file mode 100644 index 74fb13f214..0000000000 --- a/patches/msbuild/0001-Update-RoslynTools-verison-to-msbuild-specific-versi.patch +++ /dev/null @@ -1,26 +0,0 @@ -From 8767e665cf966e63cc67df2fe931cf5290d96526 Mon Sep 17 00:00:00 2001 -From: dseefeld -Date: Wed, 25 Apr 2018 21:54:15 +0000 -Subject: [PATCH] Update RoslynTools verison to msbuild specific version until - the msbuild repo is updated to the current version. - ---- - build/Versions.props | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) - -diff --git a/build/Versions.props b/build/Versions.props -index 53de55a..7f10d05 100644 ---- a/build/Versions.props -+++ b/build/Versions.props -@@ -40,7 +40,7 @@ - 2.1.300-preview2-008530 - - true -- 1.0.0-beta-62705-01 -+ 1.0.0-msbuild-62811-02 - 2.2.7 - - 2.1.0-prerelease-02404-02 --- -1.8.3.1 - diff --git a/patches/msbuild/0001-Update-build-sh-to-uptake-source-built-repotoolset.patch b/patches/msbuild/0001-Update-build-sh-to-uptake-source-built-repotoolset.patch new file mode 100644 index 0000000000..40770d654a --- /dev/null +++ b/patches/msbuild/0001-Update-build-sh-to-uptake-source-built-repotoolset.patch @@ -0,0 +1,67 @@ +From c46510737402f30f28c23b06a0b309354f98e29a Mon Sep 17 00:00:00 2001 +From: dseefeld +Date: Thu, 3 May 2018 22:30:30 +0000 +Subject: [PATCH] Update build.sh to uptake source-built repotoolset + +--- + build/build.sh | 30 ++++++++++++++++++++++++------ + 1 file changed, 24 insertions(+), 6 deletions(-) + +diff --git a/build/build.sh b/build/build.sh +index 141f779..310cf85 100755 +--- a/build/build.sh ++++ b/build/build.sh +@@ -278,19 +278,36 @@ function InstallDotNetCli { + } + + function InstallRepoToolset { ++ CreateDirectory "$RepoToolsetDir" + ReadJson "$RepoRoot/global.json" "RoslynTools.RepoToolset" + RepoToolsetVersion=$readjsonvalue +- RepoToolsetDir="$NuGetPackageRoot/roslyntools.repotoolset/$RepoToolsetVersion/tools" +- RepoToolsetBuildProj="$RepoToolsetDir/Build.proj" ++ RepoToolsetLocationFile="$RepoToolsetDir/$RepoToolsetVersion.txt" ++ ++ if [[ -a "$RepoToolsetLocationFile" ]]; then ++ local path=`cat $RepoToolsetLocationFile` ++ if [[ -a "$path" ]]; then ++ RepoToolsetBuildProj=$path ++ return ++ fi ++ fi ++ if [[ "$restore" != true ]]; then ++ ExitIfError 2 "Toolset version $RepoToolsetVersion has not been restored." ++ fi + + echo "Using repo tools version: $readjsonvalue" ++ local proj="$RepoToolsetDir/restore.proj" ++ echo '' > $proj + + local logCmd=$(GetLogCmd Toolset) ++ CallMSBuild $(QQ $proj) /t:__WriteToolsetLocation /m /nologo /clp:None /warnaserror $logCmd /p:__ToolsetLocationOutputFile=$RepoToolsetLocationFile ++ local lastexitcode=$? + +- if [ ! -d "$RepoToolsetBuildProj" ] +- then +- local ToolsetProj="$ScriptRoot/Toolset.csproj" +- CallMSBuild $(QQ $ToolsetProj) /t:build /m /clp:Summary /warnaserror /v:$verbosity $logCmd $properties ++ ExitIfError $lastexitcode "Failed to restore toolset (exit code '$lastexitcode')." ++ ++ RepoToolsetBuildProj=`cat $RepoToolsetLocationFile` ++ ++ if [[ ! -a "$RepoToolsetBuildProj" ]]; then ++ ExitIfError 3 "Invalid toolset path: $RepoToolsetBuildProj" + fi + } + +@@ -392,6 +409,7 @@ ArtifactsConfigurationDir="$ArtifactsDir/$configuration" + PackagesDir="$ArtifactsConfigurationDir/packages" + LogDir="$ArtifactsConfigurationDir/log" + VersionsProps="$ScriptRoot/Versions.props" ++RepoToolsetDir="$ArtifactsDir/toolset" + + #https://github.com/dotnet/source-build + if $dotnetBuildFromSource +-- +1.8.3.1 + diff --git a/repos/msbuild.proj b/repos/msbuild.proj index 3d5e48cf6f..52731f183b 100644 --- a/repos/msbuild.proj +++ b/repos/msbuild.proj @@ -10,6 +10,7 @@ $(ProjectDirectory)build/build$(ShellExtension) build -DotNetBuildFromSource -DotNetCoreSdkDir $(DotNetCliToolDir) -bootstraponly -skiptests -pack -configuration $(Configuration) /p:GitHeadSha=$(GitCommitHash) $(OutputVersionArgs) true false + true