Merge pull request #2631 from kehonsyo/vs2017enterprise

add Visual studio 2017 "Enterprise" edition to edition check.
This commit is contained in:
Alexey 2019-03-18 20:46:26 +03:00 committed by GitHub
commit 78fccc2588
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 7 additions and 3 deletions

View File

@ -30,12 +30,16 @@ if ($vcpkg_triplet -Match "x86") {
if ($null -eq (Get-Command "cl.exe" -ErrorAction SilentlyContinue)) {
$vstype = "Professional"
if (Test-Path "C:\Program Files (x86)\Microsoft Visual Studio\2017\${vstype}\Common7\Tools") {
Write-Host "Found VS 2017 Professional"
}
else {
$vstype = "Enterprise"
if (Test-Path "C:\Program Files (x86)\Microsoft Visual Studio\2017\${vstype}\Common7\Tools") {
}
else {
$vstype = "Community"
Write-Host "Found VS 2017 Community"
}
}
Write-Host "Found VS 2017 ${vstype}"
Push-Location "C:\Program Files (x86)\Microsoft Visual Studio\2017\${vstype}\Common7\Tools"
cmd /c "VsDevCmd.bat -arch=x64 & set" |
ForEach-Object {