@@ -23,6 +23,9 @@ if (-not (Test-Path env:CONFIG)) {
2323}
2424$CONFIG = $env: CONFIG
2525
26+ # Add 7-zip to Path
27+ $env: Path += " ;C:\Program Files\7-Zip"
28+
2629# Set BUILD_CACHE, defauting to the original value
2730if (-not (Test-Path env:BUILD_CACHE)) {
2831 $BUILD_CACHE = " gs://cloud-cpp-kokoro-results/" +
@@ -57,18 +60,18 @@ if ($LastExitCode) {
5760
5861Write-Host " Downloading build cache."
5962Get-Date - Format o
60- gsutil cp $BUILD_CACHE .
63+ gsutil cp $BUILD_CACHE vcpkg - installed.zip
6164if ($LastExitCode ) {
6265 # Ignore errors, caching failures should not break the build.
63- Write-Host " extracting build cache failed with exit code $LastExitCode "
66+ Write-Host " gsutil download failed with exit code $LastExitCode "
6467}
6568
6669Write-Host " Extracting build cache."
6770Get-Date - Format o
68- cmd / c 7z x vcpkg- installed.zip - aoa
71+ C:\Windows\system32\ cmd / c 7z x vcpkg- installed.zip - aoa
6972if ($LastExitCode ) {
7073 # Ignore errors, caching failures should not break the build.
71- Write-Host " gsutil download failed with exit code $LastExitCode "
74+ Write-Host " extracting build cache failed with exit code $LastExitCode "
7275}
7376
7477Write-Host " Bootstrap vcpkg."
@@ -119,7 +122,7 @@ Write-Host "================================================================"
119122Write-Host " ================================================================"
120123Write-Host " Create cache zip file."
121124Get-Date - Format o
122- cmd / c 7z a vcpkg- installed.zip installed\
125+ C:\Windows\system32\ cmd / c 7z a vcpkg- installed.zip installed\
123126if ($LastExitCode ) {
124127 # Ignore errors, caching failures should not break the build.
125128 Write-Host " zip build cache failed with exit code $LastExitCode "
0 commit comments