Skip to content

Commit

Permalink
ci: Move "Windows cross" job from Cirrus CI to GHA CI
Browse files Browse the repository at this point in the history
This change is required for testing cross-built executables on Windows
natively.
  • Loading branch information
hebasto committed Jan 6, 2025
1 parent 8888ee4 commit 041cfc9
Show file tree
Hide file tree
Showing 2 changed files with 47 additions and 12 deletions.
9 changes: 0 additions & 9 deletions .cirrus.yml
Original file line number Diff line number Diff line change
Expand Up @@ -130,15 +130,6 @@ task:
env:
FILE_ENV: "./ci/test/00_setup_env_arm.sh"

task:
name: 'Win64-cross'
<< : *GLOBAL_TASK_TEMPLATE
persistent_worker:
labels:
type: small
env:
FILE_ENV: "./ci/test/00_setup_env_win64.sh"

task:
name: '32-bit CentOS, dash, gui'
<< : *GLOBAL_TASK_TEMPLATE
Expand Down
50 changes: 47 additions & 3 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -146,7 +146,7 @@ jobs:
# https://github.com/actions/cache/blob/main/tips-and-workarounds.md#update-a-cache
key: ${{ github.job }}-${{ matrix.job-type }}-ccache-${{ github.run_id }}

win64-native:
windows-native:
name: ${{ matrix.job-name }}
# Use latest image, but hardcode version to avoid silent upgrades (and breaks).
# See: https://github.com/actions/runner-images#available-images.
Expand All @@ -165,10 +165,10 @@ jobs:
include:
- job-type: standard
generate-options: '-DBUILD_GUI=ON -DWITH_BDB=ON -DWITH_ZMQ=ON -DBUILD_BENCH=ON -DWERROR=ON'
job-name: 'Win64 native, VS 2022'
job-name: 'Windows native, VS 2022'
- job-type: fuzz
generate-options: '-DVCPKG_MANIFEST_NO_DEFAULT_FEATURES=ON -DVCPKG_MANIFEST_FEATURES="sqlite" -DBUILD_GUI=OFF -DBUILD_FOR_FUZZING=ON -DWERROR=ON'
job-name: 'Win64 native fuzz, VS 2022'
job-name: 'Windows native, fuzz, VS 2022'

steps:
- name: Checkout
Expand Down Expand Up @@ -259,6 +259,50 @@ jobs:
run: |
py -3 test\fuzz\test_runner.py --par %NUMBER_OF_PROCESSORS% --loglevel DEBUG %RUNNER_TEMP%\qa-assets\fuzz_corpora
windows-cross:
name: 'Windows cross, unit tests, no gui tests, no functional tests'
runs-on: ubuntu-latest
if: ${{ vars.SKIP_BRANCH_PUSH != 'true' || github.event_name == 'pull_request' }}

env:
FILE_ENV: './ci/test/00_setup_env_win64.sh'
DANGER_CI_ON_HOST_FOLDERS: 1

steps:
- name: Checkout
uses: actions/checkout@v4

- name: Set CI directories
run: |
echo "CCACHE_DIR=${{ runner.temp }}/ccache_dir" >> "$GITHUB_ENV"
echo "BASE_ROOT_DIR=${{ runner.temp }}" >> "$GITHUB_ENV"
echo "DEPENDS_DIR=${{ runner.temp }}/depends" >> "$GITHUB_ENV"
echo "BASE_BUILD_DIR=${{ runner.temp }}/build" >> "$GITHUB_ENV"
- name: Depends cache
uses: actions/cache@v4
with:
path: ${{ env.DEPENDS_DIR }}/built
key: ${{ github.job }}-depends-${{ hashFiles('depends/**', 'ci/test/00_setup_env_win64.sh') }}

- name: Restore Ccache cache
id: ccache-cache
uses: actions/cache/restore@v4
with:
path: ${{ env.CCACHE_DIR }}
key: ${{ github.job }}-ccache-${{ github.run_id }}
restore-keys: ${{ github.job }}-ccache-

- name: CI script
run: ./ci/test_run_all.sh

- name: Save Ccache cache
uses: actions/cache/save@v4
if: github.event_name != 'pull_request' && steps.ccache-cache.outputs.cache-hit != 'true'
with:
path: ${{ env.CCACHE_DIR }}
key: ${{ github.job }}-ccache-${{ github.run_id }}

asan-lsan-ubsan-integer-no-depends-usdt:
name: 'ASan + LSan + UBSan + integer, no depends, USDT'
runs-on: ubuntu-24.04 # has to match container in ci/test/00_setup_env_native_asan.sh for tracing tools
Expand Down

0 comments on commit 041cfc9

Please sign in to comment.