2016-09-19 00:21:17 +02:00
version : 2.3 .0 -rc1_b{build}-{branch}
2015-03-16 10:30:43 +01:00
2015-09-06 01:01:48 +02:00
os : Visual Studio 2015
2015-03-16 10:30:43 +01:00
2015-03-16 11:26:03 +01:00
environment :
2015-08-05 05:48:15 +02:00
COVERALLS_REPO_TOKEN :
2015-04-12 16:38:36 +02:00
secure : 5nuCg+faxFPeppoNNcSwVobswAVFUf8ut83vw8CX/4W2y0kZkGmwEfCUxSQWiQDU
2015-08-20 06:14:29 +02:00
CI_NAME : appveyor
CI_JOB_ID : $(APPVEYOR_JOB_ID)
GCOV_PREFIX : $(APPVEYOR_BUILD_FOLDER)
2016-09-03 14:59:30 +02:00
PYTHON_BIN : python
2016-01-19 22:33:35 +01:00
PYTHONIOENCODING : "utf-8" # consider cmd encoding to be unicode
2016-02-06 23:06:53 +01:00
CRAM_SHELL : "C:\\msys64\\usr\\bin\\sh.exe"
2015-09-06 01:01:48 +02:00
matrix :
- COMPILER : mingw
2015-09-06 02:52:13 +02:00
GENERATOR : "MSYS Makefiles"
2016-09-03 14:59:30 +02:00
BUILD_FLAGS : -j2
2015-09-06 02:04:06 +02:00
- COMPILER : msvc
2016-09-03 14:59:30 +02:00
GENERATOR : "Visual Studio 14 2015 Win64"
2015-09-27 13:59:40 +02:00
CFLAGS : /MP
CXXFLAGS : /MP
2016-09-03 14:59:30 +02:00
BUILD_FLAGS : /verbosity:m
2015-03-16 11:26:03 +01:00
2016-09-03 14:59:30 +02:00
init :
- git config --global core.autocrlf input
- set MSYSTEM=MINGW64
# Disable windows process crash popup
# See: https://msdn.microsoft.com/en-us/library/bb513638%28VS.85%29.aspx
- reg add "HKLM\SYSTEM\CurrentControlSet\Control\Windows" /f /v ErrorMode /t REG_DWORD /d 2
- reg add "HKLM\Software\Microsoft\Windows\Windows Error Reporting" /f /v DontShowUI /t REG_DWORD /d 1
- reg add "HKLM\Software\Microsoft\Windows\Windows Error Reporting" /f /v Disable /t REG_DWORD /d 1
2016-09-03 15:18:25 +02:00
- set PATH=C:\Python35;C:\Python35\Scripts;C:\msys64\mingw64\bin;C:\msys64\mingw32\bin;C:\msys64\usr\bin;%PATH%
2016-09-03 14:59:30 +02:00
- set PATH=%PATH%;%APPVEYOR_BUILD_FOLDER%\build;%APPVEYOR_BUILD_FOLDER%\build\Debug;%APPVEYOR_BUILD_FOLDER%\build\external\bin;%APPVEYOR_BUILD_FOLDER%\build\external\lib"
- set MSYSTEM=MINGW64
- pip install cram==0.7
# Remove Xamarin msbuild warnings
- del "C:\Program Files (x86)\MSBuild\14.0\Microsoft.Common.targets\ImportAfter\Xamarin.Common.targets"
2015-03-16 10:30:43 +01:00
2016-09-03 14:59:30 +02:00
clone_depth : 5
2015-03-16 10:30:43 +01:00
2015-09-21 20:09:43 +02:00
configuration :
- Debug
- RelWithDebInfo
2015-03-16 10:30:43 +01:00
install :
2015-09-07 11:16:31 +02:00
- ps : $env:RELEASE_NAME = $env:APPVEYOR_REPO_BRANCH -replace "/", "-"
2015-08-20 06:14:29 +02:00
# Hack to make git think it is on the tip of the repo branch
2015-08-20 06:30:23 +02:00
- 'git checkout -B %APPVEYOR_REPO_BRANCH%'
2016-09-03 14:59:30 +02:00
# Patch buggy cram
- sh -c "patch /c/Python35/lib/site-packages/cram/_test.py .cmake/cram-env.patch"
2015-08-20 06:14:29 +02:00
# Configure project
2015-08-20 05:52:52 +02:00
- 'mkdir build && cd build'
2015-09-06 02:52:13 +02:00
- >
cmake
-Wno-dev
2015-09-22 00:16:45 +02:00
-DCTESTS=ON
2015-11-01 10:02:19 +01:00
-DI18N=OFF
2015-09-07 11:16:31 +02:00
-DCMAKE_INSTALL_PREFIX="criterion-%RELEASE_NAME%"
2015-09-21 20:09:43 +02:00
-DCMAKE_BUILD_TYPE="%CONFIGURATION%"
2015-10-07 17:43:17 +02:00
%CMAKE_OPTS%
2015-09-06 02:52:13 +02:00
-G "%GENERATOR%"
..
2015-03-16 10:30:43 +01:00
build_script :
2016-09-03 14:59:30 +02:00
# open dummy fd 0 to prevent errors at configure time for autoconf dependencies
- cmake --build . -- %BUILD_FLAGS% 0<nul
2015-04-12 18:07:49 +02:00
2015-09-06 01:01:48 +02:00
before_deploy :
2015-09-06 01:22:58 +02:00
- ps : |
2015-09-07 11:16:31 +02:00
$archive = "criterion-$env:RELEASE_NAME-windows-$env:COMPILER-$env:PLATFORM"
cmake --build . --target install
7z a -ttar "$archive.tar" "criterion-$env:RELEASE_NAME"
7z a -tbzip2 "../$archive.tar.bz2" "$archive.tar"
Push-AppveyorArtifact "../$archive.tar.bz2"
2015-08-20 05:52:52 +02:00
2015-03-16 10:30:43 +01:00
test_script :
2015-09-09 19:19:58 +02:00
- cmake --build . --target criterion_tests
2015-11-16 16:34:00 +01:00
- ps : |
2016-04-19 22:51:50 +02:00
sh -c "ctest --output-on-failure --timeout 10"
2015-11-16 16:34:00 +01:00
if (-not $lastexitcode -eq 0) {
2016-01-20 14:03:02 +01:00
$host.setshouldexit(1)
2015-11-16 16:34:00 +01:00
}
2015-03-16 10:30:43 +01:00
2015-09-04 03:33:27 +02:00
#after_test:
# - 'make coveralls'
2015-03-17 01:06:41 +01:00
2015-08-20 03:12:00 +02:00
deploy :
provider : GitHub
auth_token :
secure : MnZZQeoxBVnpV9GSSvVok5Je0/N2d/fzG4+ITw95/tYSgZ8rleBV23a5sCwAea3r
2015-09-07 11:16:31 +02:00
artifact : 'criterion-$(RELEASE_NAME)-windows-$(COMPILER)-$(PLATFORM).tar.bz2'
2015-08-20 03:12:00 +02:00
draft : false
prerelease : false
on :
appveyor_repo_tag : true
2015-09-21 20:09:43 +02:00
configuration : RelWithDebInfo