mirror of
https://github.com/curl/curl.git
synced 2026-04-11 12:01:42 +08:00
appveyor: add support for using custom CMake versions
To allow more flexibility and not be limited by defaults offered by the runner machines: - Visual Studio 2013: CMake 3.12.2 - Visual Studio 2015, 2017: CMake 3.16.2 Ref: https://www.appveyor.com/docs/windows-images-software/ Start using 3.18.4, 3.19.8, 3.20.6 in older VS jobs to add variations. Time cost is a couple of seconds per job. Ref: #18704 (Discussion) Ref: #16973 Closes #19737
This commit is contained in:
parent
376c7bddc4
commit
c9e50e9e39
17
appveyor.sh
17
appveyor.sh
@ -42,6 +42,23 @@ elif [ "${APPVEYOR_BUILD_WORKER_IMAGE}" = 'Visual Studio 2019' ]; then
|
||||
fi
|
||||
|
||||
if [ "${BUILD_SYSTEM}" = 'CMake' ]; then
|
||||
# Install custom cmake version
|
||||
if [ -n "${CMAKE_VERSION:-}" ]; then
|
||||
cmake_ver=$(printf '%02d%02d' \
|
||||
"$(echo "$CMAKE_VERSION" | cut -f1 -d.)" \
|
||||
"$(echo "$CMAKE_VERSION" | cut -f2 -d.)")
|
||||
if [ "${cmake_ver}" -ge '0320' ]; then
|
||||
fn="cmake-${CMAKE_VERSION}-windows-x86_64"
|
||||
else
|
||||
fn="cmake-${CMAKE_VERSION}-win64-x64"
|
||||
fi
|
||||
curl --disable --fail --silent --show-error --connect-timeout 15 --max-time 60 --retry 3 --retry-connrefused \
|
||||
--location "https://github.com/Kitware/CMake/releases/download/v${CMAKE_VERSION}/${fn}.zip" --output bin.zip
|
||||
7z x -y bin.zip >/dev/null
|
||||
rm -f bin.zip
|
||||
PATH="$PWD/${fn}/bin:$PATH"
|
||||
fi
|
||||
|
||||
# Set env CHKPREFILL to the value '_chkprefill' to compare feature detection
|
||||
# results with and without the pre-fill feature. They have to match.
|
||||
for _chkprefill in '' ${CHKPREFILL:-}; do
|
||||
|
||||
@ -79,6 +79,7 @@ environment:
|
||||
SHARED: 'ON'
|
||||
- job_name: 'CM VS2013, Debug, x64, Schannel, Shared, Build-only'
|
||||
APPVEYOR_BUILD_WORKER_IMAGE: 'Visual Studio 2015'
|
||||
CMAKE_VERSION: '3.18.4'
|
||||
PRJ_GEN: 'Visual Studio 12 2013'
|
||||
TARGET: '-A x64'
|
||||
PRJ_CFG: Debug
|
||||
@ -87,6 +88,7 @@ environment:
|
||||
TFLAGS: 'skipall'
|
||||
- job_name: 'CM VS2015, Debug, x64, Schannel, Static, Build-only'
|
||||
APPVEYOR_BUILD_WORKER_IMAGE: 'Visual Studio 2015'
|
||||
CMAKE_VERSION: '3.19.8'
|
||||
PRJ_GEN: 'Visual Studio 14 2015'
|
||||
TARGET: '-A x64'
|
||||
PRJ_CFG: Debug
|
||||
@ -94,6 +96,7 @@ environment:
|
||||
TFLAGS: 'skipall'
|
||||
- job_name: 'CM VS2017, Debug, x64, Schannel, Shared, Build-only'
|
||||
APPVEYOR_BUILD_WORKER_IMAGE: 'Visual Studio 2017'
|
||||
CMAKE_VERSION: '3.20.6'
|
||||
PRJ_GEN: 'Visual Studio 15 2017'
|
||||
TARGET: '-A x64'
|
||||
PRJ_CFG: Debug
|
||||
|
||||
Loading…
Reference in New Issue
Block a user