2019-02-06 20:55:42 -05:00
|
|
|
branches:
|
|
|
|
only:
|
|
|
|
- master
|
|
|
|
|
|
|
|
skip_branch_with_pr: true
|
|
|
|
|
2017-04-02 15:24:42 -04:00
|
|
|
|
|
|
|
platform:
|
|
|
|
- x86
|
|
|
|
- x64
|
|
|
|
|
|
|
|
configuration:
|
|
|
|
- Debug
|
|
|
|
- Release
|
|
|
|
|
|
|
|
image:
|
|
|
|
- Visual Studio 2015
|
|
|
|
- Visual Studio 2017
|
|
|
|
|
2018-06-15 13:13:11 -04:00
|
|
|
environment:
|
2019-02-06 20:55:42 -05:00
|
|
|
access_token:
|
|
|
|
secure: JoKQ6wDekwtEk9su/zJWT12TtHMsHAacSLnPe47/SV22BAfVSMMR8VCyDF/W9bE2
|
2018-06-15 13:13:11 -04:00
|
|
|
matrix:
|
|
|
|
- GSL_CXX_STANDARD: 14
|
|
|
|
- GSL_CXX_STANDARD: 17
|
|
|
|
|
|
|
|
matrix:
|
|
|
|
exclude:
|
|
|
|
- image: Visual Studio 2015
|
|
|
|
GSL_CXX_STANDARD: 17
|
|
|
|
|
2017-04-02 15:24:42 -04:00
|
|
|
cache:
|
2017-07-13 16:53:56 -04:00
|
|
|
- C:\cmake-3.8.0-win32-x86
|
2017-04-02 15:24:42 -04:00
|
|
|
|
|
|
|
install:
|
|
|
|
- ps: |
|
2017-07-13 16:53:56 -04:00
|
|
|
if (![IO.File]::Exists("C:\cmake-3.8.0-win32-x86\bin\cmake.exe")) {
|
|
|
|
Start-FileDownload 'https://cmake.org/files/v3.8/cmake-3.8.0-win32-x86.zip'
|
|
|
|
7z x -y cmake-3.8.0-win32-x86.zip -oC:\
|
2017-04-02 15:24:42 -04:00
|
|
|
}
|
2017-07-13 16:53:56 -04:00
|
|
|
$env:PATH="C:\cmake-3.8.0-win32-x86\bin;$env:PATH"
|
2017-04-02 15:24:42 -04:00
|
|
|
|
|
|
|
before_build:
|
|
|
|
- ps: |
|
|
|
|
mkdir build
|
|
|
|
cd build
|
2018-06-15 13:13:11 -04:00
|
|
|
|
2017-04-02 15:24:42 -04:00
|
|
|
if ("$env:APPVEYOR_JOB_NAME" -match "Image: Visual Studio 2015") {
|
|
|
|
$env:generator="Visual Studio 14 2015"
|
|
|
|
} else {
|
|
|
|
$env:generator="Visual Studio 15 2017"
|
|
|
|
}
|
|
|
|
if ($env:PLATFORM -eq "x64") {
|
|
|
|
$env:generator="$env:generator Win64"
|
|
|
|
}
|
|
|
|
echo generator="$env:generator"
|
2019-02-06 20:55:42 -05:00
|
|
|
cmake .. -G "$env:generator" -DGSL_CXX_STANDARD="$env:GSL_CXX_STANDARD" -DGSL_ASM_FOLDER="$($env:APPVEYOR_BUILD_WORKER_IMAGE)_$($env:GSL_CXX_STANDARD)_$($env:PLATFORM)_$($env:CONFIGURATION)"
|
2017-04-02 15:24:42 -04:00
|
|
|
|
|
|
|
build_script:
|
|
|
|
- cmake --build . --config %CONFIGURATION% -- /m /v:minimal
|
|
|
|
|
|
|
|
test_script:
|
|
|
|
- ctest -j2
|
|
|
|
|
2019-02-06 20:55:42 -05:00
|
|
|
on_success:
|
|
|
|
- git config --global credential.helper store
|
|
|
|
- ps: Add-Content "$HOME\.git-credentials" "https://$($env:access_token):x-oauth-basic@github.com`n"
|
|
|
|
- git config --global user.email "dadonenf@microsoft.com"
|
|
|
|
- git config --global user.name "Daniel Donenfeld"
|
|
|
|
- cd %APPVEYOR_BUILD_FOLDER%
|
|
|
|
- git checkout %APPVEYOR_REPO_BRANCH%
|
|
|
|
- git add "asm\%APPVEYOR_BUILD_WORKER_IMAGE%_%GSL_CXX_STANDARD%_%PLATFORM%_%CONFIGURATION%"
|
|
|
|
- git commit -m "[skip ci] Update ASM for %APPVEYOR_BUILD_WORKER_IMAGE%_%GSL_CXX_STANDARD%_%PLATFORM%_%CONFIGURATION%"
|
|
|
|
- git push
|
|
|
|
|
|
|
|
|
2017-04-02 15:24:42 -04:00
|
|
|
deploy: off
|