@@ -172,6 +172,9 @@ $vswhere = "${env:ProgramFiles(x86)}\Microsoft Visual Studio\Installer\vswhere.e
172
172
$VSInstallRoot = & $vswhere - nologo - latest - products " *" - all - prerelease - property installationPath
173
173
$msbuild = " $VSInstallRoot \MSBuild\Current\Bin\$BuildArchName \MSBuild.exe"
174
174
175
+ # Hoist to global scope as this is used in two sites.
176
+ $WiXVersion = " 4.0.5"
177
+
175
178
# Avoid $env:ProgramFiles in case this script is running as x86
176
179
$UnixToolsBinDir = " $env: SystemDrive \Program Files\Git\usr\bin"
177
180
@@ -621,7 +624,8 @@ function Fetch-Dependencies {
621
624
}
622
625
623
626
function Extract-ZipFile {
624
- param (
627
+ param
628
+ (
625
629
[string ]$ZipFileName ,
626
630
[string ]$BinaryCache ,
627
631
[string ]$ExtractPath
@@ -647,7 +651,8 @@ function Fetch-Dependencies {
647
651
}
648
652
649
653
function Extract-Toolchain {
650
- param (
654
+ param
655
+ (
651
656
[string ]$InstallerExeName ,
652
657
[string ]$BinaryCache ,
653
658
[string ]$ToolchainName
@@ -678,13 +683,15 @@ function Fetch-Dependencies {
678
683
}
679
684
}
680
685
681
- $WiXVersion = " 4.0.4"
686
+ if ($SkipBuild -and $SkipPackaging ) { return }
687
+
682
688
$WiXURL = " https://www.nuget.org/api/v2/package/wix/$WiXVersion "
683
- $WiXHash = " A9CA12214E61BB49430A8C6E5E48AC5AE6F27DC82573B5306955C4D35F2D34E2 "
689
+ $WiXHash = " DF9BDB347183716F82EFE2CECB8C54BB3554AA907A69F47A41741D6FA4D0A754 "
684
690
DownloadAndVerify $WixURL " $BinaryCache \WiX-$WiXVersion .zip" $WiXHash
685
-
686
691
Extract- ZipFile WiX- $WiXVersion.zip $BinaryCache WiX- $WiXVersion
687
692
693
+ if ($SkipBuild ) { return }
694
+
688
695
DownloadAndVerify $PinnedBuild " $BinaryCache \$PinnedToolchain .exe" $PinnedSHA256
689
696
690
697
# TODO(compnerd) stamp/validate that we need to re-extract
@@ -2376,15 +2383,13 @@ function Stage-BuildArtifacts($Arch) {
2376
2383
} else {
2377
2384
New-Item - Type Directory - Path " $ ( $Arch.BinaryCache ) \installer\$ ( $Arch.VSName ) \" - ErrorAction Ignore | Out-Null
2378
2385
}
2379
- Invoke-Program " $BinaryCache \wix-4.0.4 \tools\net6.0\any\wix.exe" -- burn detach " $ ( $Arch.BinaryCache ) \installer\Release\$ ( $Arch.VSName ) \installer.exe" - engine " $Stage \installer-engine.exe" - intermediateFolder " $ ( $Arch.BinaryCache ) \installer\$ ( $Arch.VSName ) \"
2386
+ Invoke-Program " $BinaryCache \wix-$WiXVersion \tools\net6.0\any\wix.exe" -- burn detach " $ ( $Arch.BinaryCache ) \installer\Release\$ ( $Arch.VSName ) \installer.exe" - engine " $Stage \installer-engine.exe" - intermediateFolder " $ ( $Arch.BinaryCache ) \installer\$ ( $Arch.VSName ) \"
2380
2387
}
2381
2388
2382
2389
# -------------------------------------------------------------------
2383
2390
try {
2384
2391
2385
- if (-not $SkipBuild ) {
2386
- Fetch- Dependencies
2387
- }
2392
+ Fetch- Dependencies
2388
2393
2389
2394
if (-not $SkipBuild ) {
2390
2395
Invoke-BuildStep Build-CMark $BuildArch
0 commit comments