forked from bitcoin/bitcoin
-
Notifications
You must be signed in to change notification settings - Fork 1.2k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge bitcoin#21551: ci: Move Windows MSVC build from AppVeyor to Cirrus
97292b1 ci: Drop AppVeyor CI integration (Hennadii Stepanov) 1fb7079 ci: Add Windows task to Cirrus CI (Hennadii Stepanov) Pull request description: This PR: - gets rid off unreliable AppVeyor CI - places all CI configs in one place - allows to enable functional tests in the future (using a persistent worker) | no populated `vcpkg` cache | populated `vcpkg` cache | |---|---| |  |  | Currently, AppVeyor builds take about 44..48 minutes. ACKs for top commit: sipsorcery: re-ACK 97292b1. Tree-SHA512: 3af50d9fd68eb12f39724810dacf948e4068573b5dfd0dbaeb05d19d4bd6f10bd9a432656dcc32b742684b438d31305eace85c602296d7a1bf84b2f1fcc06f02
- Loading branch information
Showing
2 changed files
with
73 additions
and
4 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -10,8 +10,12 @@ env: | |
CCACHE_DIR: "/tmp/ccache_dir" | ||
|
||
# https://cirrus-ci.org/guide/tips-and-tricks/#sharing-configuration-between-tasks | ||
base_template: &BASE_TEMPLATE | ||
filter_template: &FILTER_TEMPLATE | ||
skip: $CIRRUS_REPO_FULL_NAME == "bitcoin-core/gui" && $CIRRUS_PR == "" # No need to run on the read-only mirror, unless it is a PR. https://cirrus-ci.org/guide/writing-tasks/#conditional-task-execution | ||
stateful: false # https://cirrus-ci.org/guide/writing-tasks/#stateful-tasks | ||
|
||
base_template: &BASE_TEMPLATE | ||
<< : *FILTER_TEMPLATE | ||
merge_base_script: | ||
# Unconditionally install git (used in fingerprint_script) and set the | ||
# default git author name (used in verify-commits.py) | ||
|
@@ -21,7 +25,6 @@ base_template: &BASE_TEMPLATE | |
- if [ "$CIRRUS_PR" = "" ]; then exit 0; fi | ||
- git fetch $CIRRUS_REPO_CLONE_URL $CIRRUS_BASE_BRANCH | ||
- git merge FETCH_HEAD # Merge base to detect silent merge conflicts | ||
stateful: false # https://cirrus-ci.org/guide/writing-tasks/#stateful-tasks | ||
|
||
global_task_template: &GLOBAL_TASK_TEMPLATE | ||
<< : *BASE_TEMPLATE | ||
|
@@ -47,7 +50,6 @@ compute_credits_template: &CREDITS_TEMPLATE | |
# Only use credits for pull requests to the main repo | ||
use_compute_credits: $CIRRUS_REPO_FULL_NAME == 'dashpay/dash' && $CIRRUS_PR != "" | ||
|
||
|
||
task: | ||
name: 'lint [bookworm]' | ||
<< : *BASE_TEMPLATE | ||
|
@@ -63,6 +65,73 @@ task: | |
lint_script: | ||
- ./ci/lint_run_all.sh | ||
|
||
task: | ||
name: "Win64 native [unit tests, no functional tests] [msvc]" | ||
<< : *FILTER_TEMPLATE | ||
windows_container: | ||
cpu: 4 | ||
memory: 16G | ||
image: cirrusci/windowsservercore:visualstudio2019 | ||
timeout_in: 120m | ||
env: | ||
CIRRUS_SHELL: powershell | ||
PATH: 'C:\Python39;C:\Python39\Scripts;C:\Program Files (x86)\Microsoft Visual Studio\2019\BuildTools\MSBuild\Current\Bin;%PATH%' | ||
PYTHONUTF8: 1 | ||
VCPKG_TAG: '75522bb1f2e7d863078bcd06322348f053a9e33f' | ||
VCPKG_FEATURE_FLAGS: 'manifests' | ||
QT_DOWNLOAD_URL: 'https://github.com/sipsorcery/qt_win_binary/releases/download/qt51211x64_static_vs2019_160900/Qt5.12.11_x64_static_vs2019_160900.zip' | ||
QT_DOWNLOAD_HASH: 'b24436bbc49ac69d992efc148e640f02e8dec426bed5f8497abf735e7d7d59d0' | ||
QT_LOCAL_PATH: 'C:\Qt5.12.11_x64_static_vs2019_160900' | ||
IgnoreWarnIntDirInTempDetected: 'true' | ||
merge_script: | ||
- git config --global user.email "[email protected]" | ||
- git config --global user.name "ci" | ||
- git config core.filemode false | ||
- git reset --hard | ||
- if ($env:CIRRUS_PR -eq $null) { exit 0; } | ||
- git fetch $env:CIRRUS_REPO_CLONE_URL $env:CIRRUS_BASE_BRANCH | ||
- git merge FETCH_HEAD | ||
vcpkg_cache: | ||
folder: 'C:\Users\ContainerAdministrator\AppData\Local\vcpkg\archives' | ||
install_python_script: | ||
- choco install --yes --no-progress python3 --version=3.9.6 | ||
- Write-Host "" | ||
- python -VV | ||
install_vcpkg_script: | ||
- cd .. | ||
- git clone --quiet https://github.com/microsoft/vcpkg.git | ||
- cd vcpkg | ||
- git -c advice.detachedHead=false checkout $env:VCPKG_TAG | ||
- .\bootstrap-vcpkg -disableMetrics | ||
- Add-Content "triplets\x64-windows-static.cmake" "set(VCPKG_BUILD_TYPE release)" | ||
- .\vcpkg integrate install | ||
- Write-Host "" | ||
- .\vcpkg version | ||
download_qt_binaries_script: | | ||
Invoke-WebRequest -Uri $env:QT_DOWNLOAD_URL -Out qtdownload.zip; | ||
Write-Host "Qt binaries successfully downloaded, checking hash against $env:QT_DOWNLOAD_HASH..."; | ||
if ((Get-FileHash qtdownload.zip).Hash -eq $env:QT_DOWNLOAD_HASH) { | ||
Write-Host "Downloaded Qt binaries archive matched the expected hash."; | ||
Expand-Archive qtdownload.zip -DestinationPath $env:QT_LOCAL_PATH; | ||
} | ||
else { | ||
Write-Host "ERROR: Downloaded Qt binaries archive did not match the expected hash."; | ||
exit 1; | ||
} | ||
build_environment_script: | ||
- choco list --localonly | ||
- Write-Host "" | ||
- msbuild -version | ||
build_script: | ||
- cd $env:CIRRUS_WORKING_DIR | ||
- python build_msvc\msvc-autogen.py | ||
- msbuild build_msvc\bitcoin.sln -property:Configuration=Release -maxCpuCount -verbosity:minimal -noLogo | ||
unit_tests_script: | ||
- src\test_bitcoin.exe | ||
- src\bench_bitcoin.exe > $null | ||
- python test\util\test_runner.py | ||
- python test\util\rpcauth-test.py | ||
|
||
task: | ||
name: 'ARM [unit tests, no functional tests] [buster]' | ||
<< : *GLOBAL_TASK_TEMPLATE | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters