Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/dotnet/runtime.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authordotnet-maestro[bot] <42748379+dotnet-maestro[bot]@users.noreply.github.com>2020-09-23 12:59:47 +0300
committerGitHub <noreply@github.com>2020-09-23 12:59:47 +0300
commitfc296c5381479d3dc9195d8b58b043725defc34e (patch)
tree156e3b5a4573a3a549ea67c35dd9b7725560671c /eng/common/tools.ps1
parent661ac50e08421dc1a508dda2a9be625ed11e02b3 (diff)
[master] Update dependencies from dotnet/xharness mono/linker dotnet/arcade Microsoft/vstest dotnet/llvm-project dotnet/icu (#42201)
[master] Update dependencies from dotnet/xharness mono/linker dotnet/arcade Microsoft/vstest dotnet/llvm-project dotnet/icu - Merge branch 'master' into darc-master-c2f56120-c0a9-49ac-83ec-d0550f2e6a36 - Fix merge conflict - Revert override of local changes to send-to-helix.yml - Fix path to ILLink.Tasks.dll - Revert override of local changes to send-to-helix.yml - Revert override of local changes to send-to-helix.yml - Fix path to ILLink.Tasks.dll - Fix another path to ILLink.Tasks.dll
Diffstat (limited to 'eng/common/tools.ps1')
-rw-r--r--eng/common/tools.ps125
1 files changed, 18 insertions, 7 deletions
diff --git a/eng/common/tools.ps1 b/eng/common/tools.ps1
index 37a3a3d6800..60066083b34 100644
--- a/eng/common/tools.ps1
+++ b/eng/common/tools.ps1
@@ -312,9 +312,15 @@ function InitializeVisualStudioMSBuild([bool]$install, [object]$vsRequirements =
return $global:_MSBuildExe
}
- $vsMinVersionReqdStr = '16.5'
+ # Minimum VS version to require.
+ $vsMinVersionReqdStr = '16.8'
$vsMinVersionReqd = [Version]::new($vsMinVersionReqdStr)
+ # If the version of msbuild is going to be xcopied,
+ # use this version. Version matches a package here:
+ # https://dev.azure.com/dnceng/public/_packaging?_a=package&feed=dotnet-eng&package=RoslynTools.MSBuild&protocolType=NuGet&version=16.8.0-preview3&view=overview
+ $defaultXCopyMSBuildVersion = '16.8.0-preview3'
+
if (!$vsRequirements) { $vsRequirements = $GlobalJson.tools.vs }
$vsMinVersionStr = if ($vsRequirements.version) { $vsRequirements.version } else { $vsMinVersionReqdStr }
$vsMinVersion = [Version]::new($vsMinVersionStr)
@@ -349,23 +355,28 @@ function InitializeVisualStudioMSBuild([bool]$install, [object]$vsRequirements =
$xcopyMSBuildVersion = $GlobalJson.tools.'xcopy-msbuild'
$vsMajorVersion = $xcopyMSBuildVersion.Split('.')[0]
} else {
- #if vs version provided in global.json is incompatible then use the default version for xcopy msbuild download
+ #if vs version provided in global.json is incompatible (too low) then use the default version for xcopy msbuild download
if($vsMinVersion -lt $vsMinVersionReqd){
- Write-Host "Using xcopy-msbuild version of $vsMinVersionReqdStr.0-alpha since VS version $vsMinVersionStr provided in global.json is not compatible"
- $vsMajorVersion = $vsMinVersionReqd.Major
- $vsMinorVersion = $vsMinVersionReqd.Minor
+ Write-Host "Using xcopy-msbuild version of $defaultXCopyMSBuildVersion since VS version $vsMinVersionStr provided in global.json is not compatible"
+ $xcopyMSBuildVersion = $defaultXCopyMSBuildVersion
}
else{
+ # If the VS version IS compatible, look for an xcopy msbuild package
+ # with a version matching VS.
+ # Note: If this version does not exist, then an explicit version of xcopy msbuild
+ # can be specified in global.json. This will be required for pre-release versions of msbuild.
$vsMajorVersion = $vsMinVersion.Major
$vsMinorVersion = $vsMinVersion.Minor
+ $xcopyMSBuildVersion = "$vsMajorVersion.$vsMinorVersion.0"
}
-
- $xcopyMSBuildVersion = "$vsMajorVersion.$vsMinorVersion.0-alpha"
}
$vsInstallDir = $null
if ($xcopyMSBuildVersion.Trim() -ine "none") {
$vsInstallDir = InitializeXCopyMSBuild $xcopyMSBuildVersion $install
+ if ($vsInstallDir -eq $null) {
+ throw "Could not xcopy msbuild. Please check that package 'RoslynTools.MSBuild @ $xcopyMSBuildVersion' exists on feed 'dotnet-eng'."
+ }
}
if ($vsInstallDir -eq $null) {
throw 'Unable to find Visual Studio that has required version and components installed'