From afc78d18c645d38930c99b1ad175bb86b6ae0150 Mon Sep 17 00:00:00 2001 From: Robin Kuzmin Date: Thu, 18 Mar 2021 13:24:30 -0700 Subject: [PATCH] Fixed prerequisites.ps1 --- src/QirRuntime/prerequisites.ps1 | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/src/QirRuntime/prerequisites.ps1 b/src/QirRuntime/prerequisites.ps1 index 43a7337012f..72ae1b5079c 100644 --- a/src/QirRuntime/prerequisites.ps1 +++ b/src/QirRuntime/prerequisites.ps1 @@ -2,10 +2,11 @@ # Licensed under the MIT License. if ($Env:ENABLE_QIRRUNTIME -ne "false") { - if (($IsWindows) -or ((Test-Path Env:AGENT_OS) -and ($Env:AGENT_OS.StartsWith("Win"))) -and - !(Get-Command clang -ErrorAction SilentlyContinue)) { - choco install llvm - choco install ninja + if (($IsWindows) -or ((Test-Path Env:AGENT_OS) -and ($Env:AGENT_OS.StartsWith("Win")))) { + if (!(Get-Command clang -ErrorAction SilentlyContinue)) { + choco install llvm + choco install ninja + } } elseif ($IsMacOS) { brew install ninja } else {