diff --git a/scripts/bootstrap.ps1 b/scripts/bootstrap.ps1 index c37ffd57fc..149134dfff 100644 --- a/scripts/bootstrap.ps1 +++ b/scripts/bootstrap.ps1 @@ -5,7 +5,6 @@ param( ) Set-StrictMode -Version Latest $scriptsDir = split-path -parent $script:MyInvocation.MyCommand.Definition -$vcpkgRootDir = $scriptsDir $withVSPath = $withVSPath -replace "\\$" # Remove potential trailing backslash function vcpkgHasProperty([Parameter(Mandatory=$true)][AllowNull()]$object, [Parameter(Mandatory=$true)]$propertyName) @@ -34,6 +33,7 @@ function getProgramFiles32bit() return $out } +$vcpkgRootDir = $scriptsDir while (!($vcpkgRootDir -eq "") -and !(Test-Path "$vcpkgRootDir\.vcpkg-root")) { Write-Verbose "Examining $vcpkgRootDir for .vcpkg-root"