diff options
author | Jack Lloyd <[email protected]> | 2019-11-15 08:39:27 -0500 |
---|---|---|
committer | Jack Lloyd <[email protected]> | 2019-11-15 08:39:27 -0500 |
commit | 6c56fff65fede68dd0adf6459cca2cb09b6af1d2 (patch) | |
tree | 7dbe809410f1687b9ea0b1fdda4b5b547e0611b6 /src | |
parent | 1cea876f7be7a3a6349f1e1f1f61d991eed427c8 (diff) | |
parent | a420e040e3e2e489c03d086e7d44260f62ac17ff (diff) |
Merge GH #2194 Add MinGW build to AppVeyor CI
Diffstat (limited to 'src')
-rw-r--r-- | src/scripts/ci/appveyor.yml | 28 | ||||
-rw-r--r-- | src/scripts/ci/setup_appveyor.bat | 14 | ||||
-rwxr-xr-x | src/scripts/ci_build.py | 3 |
3 files changed, 32 insertions, 13 deletions
diff --git a/src/scripts/ci/appveyor.yml b/src/scripts/ci/appveyor.yml index ad9c34406..b323a1f6d 100644 --- a/src/scripts/ci/appveyor.yml +++ b/src/scripts/ci/appveyor.yml @@ -8,8 +8,16 @@ environment: matrix: + # MinGW GCC + - CC: MinGW + PLATFORM: x86_amd64 + TARGET: static + APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2019 + MAKE_TOOL: mingw32-make + TARGET_CC: gcc + # MSVC 2015 DLL x86-32 - - MSVS: 2015 + - CC: VC2015 PLATFORM: x86 TARGET: shared APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2015 @@ -17,9 +25,10 @@ environment: BOOST_LIBRARYDIR: "C:\\Libraries\\boost_1_69_0\\lib32-msvc-14.0" BOOST_SYSTEM_LIBRARY: "libboost_system-vc140-mt-x32-1_69.lib" MAKE_TOOL: nmake + TARGET_CC: msvc # MSVC 2017 DLL x86-32 - - MSVS: 2017 + - CC: VC2017 PLATFORM: x86 TARGET: shared APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2017 @@ -27,9 +36,10 @@ environment: BOOST_LIBRARYDIR: "C:\\Libraries\\boost_1_69_0\\lib32-msvc-14.1" BOOST_SYSTEM_LIBRARY: "libboost_system-vc141-mt-x32-1_69.lib" MAKE_TOOL: jom + TARGET_CC: msvc # MSVC 2017 DLL x86-64 - - MSVS: 2017 + - CC: VC2017 PLATFORM: x86_amd64 TARGET: shared APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2017 @@ -37,9 +47,10 @@ environment: BOOST_LIBRARYDIR: "C:\\Libraries\\boost_1_69_0\\lib64-msvc-14.1" BOOST_SYSTEM_LIBRARY: "libboost_system-vc141-mt-x64-1_69.lib" MAKE_TOOL: jom + TARGET_CC: msvc # MSVC 2017 static x86-64 - - MSVS: 2017 + - CC: VC2017 PLATFORM: x86_amd64 TARGET: static APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2017 @@ -47,26 +58,29 @@ environment: BOOST_LIBRARYDIR: "C:\\Libraries\\boost_1_69_0\\lib64-msvc-14.1" BOOST_SYSTEM_LIBRARY: "libboost_system-vc141-mt-x64-1_69.lib" MAKE_TOOL: jom + TARGET_CC: msvc # MSVC 2019 static x86-64 w/debug iterators - - MSVS: 2019 + - CC: VC2019 PLATFORM: x86_amd64 TARGET: sanitizer APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2019 MAKE_TOOL: jom + TARGET_CC: msvc # MSVC 2019 x86-64 preview - - MSVS: 2019p + - CC: VC2019p PLATFORM: x86_amd64 TARGET: static APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2019 Preview MAKE_TOOL: jom + TARGET_CC: msvc install: - call src\scripts\ci\setup_appveyor.bat build_script: - - python src\scripts\ci_build.py --os=windows --cc=msvc --without-python3 --compiler-cache=sccache --make-tool=%MAKE_TOOL% --cpu=%PLATFORM% %TARGET% + - python src\scripts\ci_build.py --os=windows --cc=%TARGET_CC% --without-python3 --compiler-cache=sccache --make-tool=%MAKE_TOOL% --cpu=%PLATFORM% %TARGET% # whitelist branches to avoid testing feature branches twice (as branch and as pull request) branches: diff --git a/src/scripts/ci/setup_appveyor.bat b/src/scripts/ci/setup_appveyor.bat index ed7a8f1a9..443c89791 100644 --- a/src/scripts/ci/setup_appveyor.bat +++ b/src/scripts/ci/setup_appveyor.bat @@ -1,13 +1,15 @@ -echo Current build setup MSVS="%MSVS%" PLATFORM="%PLATFORM%" TARGET="%TARGET%" +echo Current build setup CC="%CC%" PLATFORM="%PLATFORM%" TARGET="%TARGET%" -if %MSVS% == 2015 call "%ProgramFiles(x86)%\Microsoft Visual Studio 14.0\VC\vcvarsall.bat" %PLATFORM% -if %MSVS% == 2017 call "%ProgramFiles(x86)%\Microsoft Visual Studio\2017\Community\VC\Auxiliary\Build\vcvarsall.bat" %PLATFORM% -if %MSVS% == 2019 call "%ProgramFiles(x86)%\Microsoft Visual Studio\2019\Community\VC\Auxiliary\Build\vcvarsall.bat" %PLATFORM% -if %MSVS% == 2019p call "%ProgramFiles(x86)%\Microsoft Visual Studio\2019\Preview\VC\Auxiliary\Build\vcvarsall.bat" %PLATFORM% +if %CC% == VC2015 call "%ProgramFiles(x86)%\Microsoft Visual Studio 14.0\VC\vcvarsall.bat" %PLATFORM% +if %CC% == VC2017 call "%ProgramFiles(x86)%\Microsoft Visual Studio\2017\Community\VC\Auxiliary\Build\vcvarsall.bat" %PLATFORM% +if %CC% == VC2019 call "%ProgramFiles(x86)%\Microsoft Visual Studio\2019\Community\VC\Auxiliary\Build\vcvarsall.bat" %PLATFORM% +if %CC% == VC2019p call "%ProgramFiles(x86)%\Microsoft Visual Studio\2019\Preview\VC\Auxiliary\Build\vcvarsall.bat" %PLATFORM% +if %CC% == MinGW set PATH=%PATH%;C:\msys64\mingw64\bin rem check compiler version -cl +if %CC% == MinGW g++ -v +if not %CC% == MinGW cl appveyor DownloadFile https://github.com/mozilla/sccache/releases/download/%SCCACHE_VERSION%/sccache-%SCCACHE_VERSION%-x86_64-pc-windows-msvc.tar.gz tar -xf sccache-%SCCACHE_VERSION%-x86_64-pc-windows-msvc.tar.gz diff --git a/src/scripts/ci_build.py b/src/scripts/ci_build.py index 5ca132a8f..b75b52e84 100755 --- a/src/scripts/ci_build.py +++ b/src/scripts/ci_build.py @@ -46,6 +46,9 @@ def determine_flags(target, target_os, target_cpu, target_cc, cc_bin, ccache, ro elif target in ['cross-android-arm32', 'cross-android-arm64']: target_os = 'android' + if target_os == 'windows' and target_cc == 'gcc': + target_os = 'mingw' + make_prefix = [] test_prefix = [] test_cmd = [os.path.join(root_dir, 'botan-test')] |