From df3cf0012cfe82d258c80ac43ac852a738d862ca Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Mikko=20Pitk=C3=A4nen?= Date: Mon, 24 Jun 2019 16:48:48 +0300 Subject: [PATCH] Add MSVC builds to Appveyor and notify commit author of failed builds --- appveyor.yml | 80 ++++++++++++++----- ...{kvazaar_VS2013.sln => kvazaar_VS2015.sln} | 2 +- build/kvazaar_cli/kvazaar_cli.vcxproj | 9 ++- build/kvazaar_lib/kvazaar_lib.vcxproj | 9 ++- build/kvazaar_tests/kvazaar_tests.vcxproj | 11 +-- 5 files changed, 79 insertions(+), 32 deletions(-) rename build/{kvazaar_VS2013.sln => kvazaar_VS2015.sln} (99%) diff --git a/appveyor.yml b/appveyor.yml index 88bf6e3c..6ead1170 100644 --- a/appveyor.yml +++ b/appveyor.yml @@ -1,28 +1,72 @@ +# Only the whitelisted branches get built, regardless of build config branches: only: - master - - appveyor -environment: - matrix: - - MSYSTEM: MINGW64 - - MSYSTEM: MINGW32 +# Email the author if their commit either failed to build or fixed a failed build +# good -> bad, bad -> bad, bad -> good but not good -> good +notifications: + - provider: Email + to: + - '{{commitAuthorEmail}}' + on_build_failure: true + on_build_status_changed: true +# Download only a zip file of the latest commit +# Downloading the whole history of the repository would be unnecessary shallow_clone: true + +# Only try building the app, don't run any tests test: off -install: - # Update core packages - - C:\msys64\usr\bin\pacman -Syyuu --noconfirm --noprogressbar - # Update non-core packages - - C:\msys64\usr\bin\pacman -Suu --noconfirm --noprogressbar - # Install required MSYS2 packages - - C:\msys64\usr\bin\pacman -S --noconfirm --noprogressbar --needed automake-wrapper make - # Now MSYS2 is up to date, do the rest of the install from a bash script - - C:\msys64\usr\bin\bash -lc "cd \"$APPVEYOR_BUILD_FOLDER\" && exec ./tools/appveyor-install.sh" +# Don't bother with debug builds +configuration: + - Release -build_script: - - C:\msys64\usr\bin\bash -lc "cd \"$APPVEYOR_BUILD_FOLDER\" && exec ./tools/appveyor-build.sh" +# Build with multiple compilers / build suites +image: Visual Studio 2015 +environment: + matrix: + - platform: Win32 + - platform: x64 + - MSYSTEM: MINGW32 + - MSYSTEM: MINGW64 -cache: - - C:\msys64\var\cache\pacman\pkg +for: +- + # MinGW builds need all kinds of build scripts + matrix: + only: + - MSYSTEM: MINGW32 + - MSYSTEM: MINGW64 + + install: + # Update core packages + - C:\msys64\usr\bin\pacman -Syyuu --noconfirm --noprogressbar + # Update non-core packages + - C:\msys64\usr\bin\pacman -Suu --noconfirm --noprogressbar + # Install required MSYS2 packages + - C:\msys64\usr\bin\pacman -S --noconfirm --noprogressbar --needed automake-wrapper make + # Now MSYS2 is up to date, do the rest of the install from a bash script + - C:\msys64\usr\bin\bash -lc "cd \"$APPVEYOR_BUILD_FOLDER\" && exec ./tools/appveyor-install.sh" + + build_script: + - C:\msys64\usr\bin\bash -lc "cd \"$APPVEYOR_BUILD_FOLDER\" && exec ./tools/appveyor-build.sh" + + cache: + - C:\msys64\var\cache\pacman\pkg +- + # MSVC builds only need vsyasm and the solution file + matrix: + except: + - MSYSTEM: MINGW32 + - MSYSTEM: MINGW64 + + install: + - ps: $url = "http://ultravideo.cs.tut.fi/vsyasm.exe" + - ps: $output = "C:\Tools\vsyasm.exe" + - ps: "(New-Object System.Net.WebClient).DownloadFile($url, $output)" + - ps: '$env:Path += ";$output\.."' + + build: + project: .\build\kvazaar_VS2015.sln diff --git a/build/kvazaar_VS2013.sln b/build/kvazaar_VS2015.sln similarity index 99% rename from build/kvazaar_VS2013.sln rename to build/kvazaar_VS2015.sln index dda84746..8d4369a0 100644 --- a/build/kvazaar_VS2013.sln +++ b/build/kvazaar_VS2015.sln @@ -1,6 +1,6 @@  Microsoft Visual Studio Solution File, Format Version 12.00 -# Visual Studio 2013 +# Visual Studio 14 VisualStudioVersion = 12.0.30723.0 MinimumVisualStudioVersion = 10.0.40219.1 Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "kvazaar_lib", "kvazaar_lib\kvazaar_lib.vcxproj", "{EEA3BDD1-8A08-41C1-BA57-E05D5C2CD8FF}" diff --git a/build/kvazaar_cli/kvazaar_cli.vcxproj b/build/kvazaar_cli/kvazaar_cli.vcxproj index 173acd36..75ab5c03 100644 --- a/build/kvazaar_cli/kvazaar_cli.vcxproj +++ b/build/kvazaar_cli/kvazaar_cli.vcxproj @@ -22,23 +22,24 @@ {C755308D-9B3E-4712-99AB-7F6F4E2DA567} Win32Proj kvazaar_cli + 8.1 true - v120 + v140 true - v120 + v140 false - v120 + v140 false - v120 + v140 diff --git a/build/kvazaar_lib/kvazaar_lib.vcxproj b/build/kvazaar_lib/kvazaar_lib.vcxproj index 1869aad2..7deee08e 100644 --- a/build/kvazaar_lib/kvazaar_lib.vcxproj +++ b/build/kvazaar_lib/kvazaar_lib.vcxproj @@ -22,27 +22,28 @@ {EEA3BDD1-8A08-41C1-BA57-E05D5C2CD8FF} Win32Proj kvazaar_lib + 8.1 StaticLibrary true - v120 + v140 StaticLibrary true - v120 + v140 StaticLibrary false - v120 + v140 StaticLibrary false - v120 + v140 diff --git a/build/kvazaar_tests/kvazaar_tests.vcxproj b/build/kvazaar_tests/kvazaar_tests.vcxproj index 9766bc1e..d027bdcb 100644 --- a/build/kvazaar_tests/kvazaar_tests.vcxproj +++ b/build/kvazaar_tests/kvazaar_tests.vcxproj @@ -22,23 +22,24 @@ {3CD1C68B-542C-46D8-9B8A-6C91C5A3F312} Win32Proj kvazaar_tests + 8.1 true - v120 + v140 true - v120 + v140 false - v120 + v140 false - v120 + v140 @@ -115,4 +116,4 @@ - + \ No newline at end of file