@@ -64,67 +64,11 @@ try {
6464
6565 if ($buildStage1 )
6666 {
67- & $PSScriptRoot \Common\Build.ps1 - restore - build - ci - msbuildEngine $msbuildEngine / p:CreateBootstrap= true @properties
67+ & $PSScriptRoot \Common\Build.ps1 - restore - build - test - ci - msbuildEngine $msbuildEngine / p:CreateBootstrap= true @properties
6868 }
6969
7070 KillProcessesFromRepo
7171
72- $bootstrapRoot = Join-Path $Stage1BinDir " bootstrap"
73-
74- # we need to do this to guarantee we have/know where dotnet.exe is installed
75- $dotnetToolPath = InitializeDotNetCli $true
76- $dotnetExePath = Join-Path $dotnetToolPath " dotnet.exe"
77-
78- if ($msbuildEngine -eq ' vs' )
79- {
80- $buildToolPath = Join-Path $bootstrapRoot " net472\MSBuild\Current\Bin\MSBuild.exe"
81- $buildToolCommand = " " ;
82- $buildToolFramework = " net472"
83-
84- if ($configuration -eq " Debug-MONO" -or $configuration -eq " Release-MONO" )
85- {
86- # Copy MSBuild.dll to MSBuild.exe so we can run it without a host
87- $sourceDll = Join-Path $bootstrapRoot " net472\MSBuild\Current\Bin\MSBuild.dll"
88- Copy-Item - Path $sourceDll - Destination $msbuildToUse
89- }
90- }
91- else
92- {
93- $buildToolPath = $dotnetExePath
94- $buildToolCommand = Join-Path $bootstrapRoot " net8.0\MSBuild\MSBuild.dll"
95- $buildToolFramework = " net8.0"
96- }
97-
98- # Use separate artifacts folder for stage 2
99- # $env:ArtifactsDir = Join-Path $ArtifactsDir "2\"
100-
101- & $dotnetExePath build-server shutdown
102-
103- if ($buildStage1 )
104- {
105- if (Test-Path $Stage1Dir )
106- {
107- Remove-Item - Force - Recurse $Stage1Dir
108- }
109-
110- Move-Item - Path $ArtifactsDir - Destination $Stage1Dir - Force
111- }
112-
113- $buildTool = @ { Path = $buildToolPath ; Command = $buildToolCommand ; Tool = $msbuildEngine ; Framework = $buildToolFramework }
114- $global :_BuildTool = $buildTool
115-
116- # Ensure that debug bits fail fast, rather than hanging waiting for a debugger attach.
117- $env: MSBUILDDONOTLAUNCHDEBUGGER = " true"
118-
119- # Opt into performance logging. https://github.com/dotnet/msbuild/issues/5900
120- $env: DOTNET_PERFLOG_DIR = $PerfLogDir
121-
122- # When using bootstrapped MSBuild:
123- # - Turn off node reuse (so that bootstrapped MSBuild processes don't stay running and lock files)
124- # - Do run tests
125- # - Don't try to create a bootstrap deployment
126- & $PSScriptRoot \Common\Build.ps1 - restore - build - test - ci / p:CreateBootstrap= false / nr:false @properties
127-
12872 exit $lastExitCode
12973}
13074catch {
0 commit comments