Skip to content

Commit 6526354

Browse files
Add 2022 vc alternate path
1 parent bc3986f commit 6526354

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

build.psm1

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -253,6 +253,10 @@ function Start-BuildNativeWindowsBinaries {
253253
$alternateVCPath = (Get-ChildItem "${env:ProgramFiles(x86)}\Microsoft Visual Studio\2017" -Filter "VC" -Directory -Recurse -ErrorAction SilentlyContinue) | Select-Object -First 1 -ExpandProperty FullName
254254
}
255255

256+
if (-not $alternateVCPath) {
257+
$alternateVCPath = (Get-ChildItem "${env:ProgramFiles}\Microsoft Visual Studio\2022" -Filter "VC" -Directory -Recurse -ErrorAction SilentlyContinue) | Select-Object -First 1 -ExpandProperty FullName
258+
}
259+
256260
Write-Verbose -Verbose "alternateVCPath: $alternateVCPath"
257261

258262
$atlBaseFound = $false
@@ -294,7 +298,7 @@ function Start-BuildNativeWindowsBinaries {
294298
{
295299
Write-Verbose -Verbose "checking 2017 path"
296300
$vcvarsallbatPathVS2017 = ( Get-ChildItem $alternateVCPath -Filter vcvarsall.bat -Recurse -File -ErrorAction SilentlyContinue | Select-Object -First 1 -ExpandProperty FullName)
297-
Write-Vebose -Verbose "vcvarsallbatPathVS2017: $vcvarsallbatPathVS2017"
301+
Write-Verbose -Verbose "vcvarsallbatPathVS2017: $vcvarsallbatPathVS2017"
298302

299303
if(Test-Path $vcvarsallbatPathVS2017)
300304
{

0 commit comments

Comments
 (0)