$Env:Path="$CMAKE_BIN;$path"
}
-$ErrorActionPreference = "Continue"
-if (-NOT (sort.exe /? 2>$null | Select-String "SORT")) {
- $ErrorActionPreference = "Stop"
- echo "Moving C:\WINDOWS\system32 to front of PATH in order to find Windows' sort"
- $Env:Path="C:\WINDOWS\system32;$Env:Path"
-}
-$ErrorActionPreference = "Stop"
-
-$script:all_programs += " sort"
-
-
echo "Final check where all utilites are found:"
$script:all_programs.Trim().Split(" ") | ForEach {
$exit_status = 1
}
-$ErrorActionPreference = "Continue"
-if (-NOT (sort.exe /? 2>$null | Select-String "SORT")) {
- $ErrorActionPreference = "Stop"
- $exe = (Get-Command sort.exe 2>$null).Source
- Write-Error -EA Continue "Found an unknown sort at $exe"
- $exit_status = 1
-}
-$ErrorActionPreference = "Stop"
-
if ($exit_status -eq 0) {
echo "All utilities have been found. Happy building!"
} else {