Add CMake CI with implicit & explicit OpenSSL libs (#1924)

* Add CMake Win32 and CMake x64 with DISABLE_INTERNAL_OPENSSL=ON

* Put CMake jobs ahead for quick testing

* Fix yaml typo

* Use CMake VisualStudio generator instead of NMake

* Fix string concat

* Add double quotes

* CMake: build only RelWithDebInfo

* Add --config RelWithDebInfo

* Fix -DCMAKE_BUILD_TYPE=RelWithDebInfo

* ctest -C instead of --config

* ctest misconfig
This commit is contained in:
zosrothko 2017-10-06 16:04:05 +02:00 committed by Aleksandar Fabijanic
parent c31af5d369
commit 1bb38ed4d5

View File

@ -68,6 +68,12 @@ environment:
OPENSSL64: C:\OpenSSL-Win64
matrix:
- builder: cmake
vsver: 140
- builder: cmake
vsver: 150
- builder: msbuild
vsver: 140
linkmode: shared
@ -96,12 +102,6 @@ environment:
# vsver: 150
# linkmode: static_mt
- builder: cmake
vsver: 140
- builder: cmake
vsver: 150
- builder: cygwin
matrix:
@ -433,10 +433,22 @@ build_script:
{
$openssl = $env:OPENSSL64
}
$defs =' -G"NMake Makefiles"';
$defs+=" -DCMAKE_BUILD_TYPE=$env:configuration";
$defs+=" -DOPENSSL_ROOT_DIR=$openssl";
$defs+=" -DENABLE_NETSSL=OFF";
if ($env:vsver -eq "140")
{
$generator = '"Visual Studio 14 2015"'
}
if ($env:vsver -eq "150")
{
$generator = '"Visual Studio 15 2017"'
}
$defs = "--config RelWithDebInfo"
$defs+=" -G" + $generator;
$defs+=" -DCMAKE_BUILD_TYPE=RelWithDebInfo";
if ($env:vsver -eq "150")
{
$defs+=" -DDISABLE_INTERNAL_OPENSSL=ON";
}
$defs+=" -DENABLE_NETSSL=ON";
$defs+=" -DENABLE_NETSSL_WIN=ON";
$defs+=" -DENABLE_DATA_MYSQL=OFF";
$defs+=" -DENABLE_REDIS=OFF";
@ -565,11 +577,11 @@ test_script:
{
pushd cmake-build;
Write-Host -ForegroundColor Yellow $line;
ctest -N
ctest --config RelWithDebInfo -N
Write-Host -ForegroundColor Yellow $line;
Write-Host -ForegroundColor Yellow 'ctest -VV -E Data*'
ctest -VV -E Data* -E Crypto*
Write-Host -ForegroundColor Yellow 'ctest -C Debug -VV -E Data*'
ctest -C Debug -VV -E Data*
popd
}
Write-Host $runs' runs, ' $fails' fails'