azure: Add clang-cl/ninja to matrix
Note that Vs2017 tools are also in PATH for llvm build
This commit is contained in:
parent
bb0bbfc2ab
commit
48351e70cd
|
@ -44,6 +44,10 @@ jobs:
|
||||||
arch: x64
|
arch: x64
|
||||||
compiler: msvc2017
|
compiler: msvc2017
|
||||||
backend: vs2017
|
backend: vs2017
|
||||||
|
clangclx64ninja:
|
||||||
|
arch: x64
|
||||||
|
compiler: clang-cl
|
||||||
|
backend: ninja
|
||||||
|
|
||||||
steps:
|
steps:
|
||||||
- template: ci/azure-steps.yml
|
- template: ci/azure-steps.yml
|
||||||
|
|
|
@ -49,12 +49,26 @@ steps:
|
||||||
$env:Path = "$env:SYSTEM_WORKFOLDER;$env:Path"
|
$env:Path = "$env:SYSTEM_WORKFOLDER;$env:Path"
|
||||||
|
|
||||||
# import visual studio variables
|
# import visual studio variables
|
||||||
|
if ($env:compiler -eq 'msvc2015') {
|
||||||
|
$vsver = $env:compiler.Replace('msvc', '')
|
||||||
|
} else {
|
||||||
|
$vsver = '2017'
|
||||||
|
}
|
||||||
Set-PSRepository -Name PSGallery -InstallationPolicy Trusted
|
Set-PSRepository -Name PSGallery -InstallationPolicy Trusted
|
||||||
Install-Module Pscx -Scope CurrentUser -AllowClobber
|
Install-Module Pscx -Scope CurrentUser -AllowClobber
|
||||||
Install-Module VSSetup -Scope CurrentUser
|
Install-Module VSSetup -Scope CurrentUser
|
||||||
$vsver = $env:compiler.Replace('msvc', '')
|
|
||||||
Import-VisualStudioVars -VisualStudioVersion $vsver -Architecture $(arch)
|
Import-VisualStudioVars -VisualStudioVersion $vsver -Architecture $(arch)
|
||||||
|
|
||||||
|
# install llvm for clang-cl builds
|
||||||
|
# (note that we use LIB, WINDRES from VS, so leave those in PATH)
|
||||||
|
if ($env:compiler -eq 'clang-cl') {
|
||||||
|
DownloadFile -Source 'http://releases.llvm.org/7.0.0/LLVM-7.0.0-win64.exe' -Destination LLVM-7.0.0-win64.exe
|
||||||
|
Start-Process .\LLVM-7.0.0-win64.exe -ArgumentList '/S' -Wait
|
||||||
|
$env:Path = "C:\Program Files\LLVM\bin;$env:Path"
|
||||||
|
$env:CC = "clang-cl"
|
||||||
|
$env:CXX = "clang-cl"
|
||||||
|
}
|
||||||
|
|
||||||
# add .NET framework tools to path for resgen for C# tests
|
# add .NET framework tools to path for resgen for C# tests
|
||||||
# (always use 32-bit tool, as there doesn't seem to be a 64-bit tool)
|
# (always use 32-bit tool, as there doesn't seem to be a 64-bit tool)
|
||||||
if ((Get-Command "resgen.exe" -ErrorAction SilentlyContinue) -eq $null) {
|
if ((Get-Command "resgen.exe" -ErrorAction SilentlyContinue) -eq $null) {
|
||||||
|
|
Loading…
Reference in New Issue