-
Notifications
You must be signed in to change notification settings - Fork 0
150 lines (129 loc) · 4.51 KB
/
openbsd.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
name: OpenBSD
on:
pull_request:
paths:
- '.github/actions/**'
- '.github/workflows/openbsd.yml'
schedule:
- cron: '22 02 * * *'
workflow_dispatch:
inputs:
skip_functional_tests:
description: 'Skip functional tests'
required: true
default: false
type: boolean
concurrency:
group: ${{ github.workflow }}${{ github.event_name != 'pull_request' && github.run_id || github.ref }}
cancel-in-progress: true
env:
CCACHE_COMPILERCHECK: content
CCACHE_DIR: ${{ github.workspace }}/ccache
CCACHE_MAXSIZE: 300M
# See https://docs.github.com/en/actions/using-github-hosted-runners/using-github-hosted-runners/about-github-hosted-runners#standard-github-hosted-runners-for-public-repositories
CI_NCPU: 4
jobs:
openbsd-syslibs:
name: 'OpenBSD: system libs, no BDB, no GUI'
runs-on: ubuntu-latest
defaults:
run:
shell: openbsd {0}
steps:
- name: Checkout Bitcoin Core repo
uses: actions/checkout@v4
with:
repository: bitcoin/bitcoin
- name: Start OpenBSD VM
uses: vmactions/openbsd-vm@v1
with:
envs: 'CCACHE_COMPILERCHECK CCACHE_DIR CCACHE_MAXSIZE'
prepare: pkg_add -v cmake git ccache boost libevent sqlite3 zeromq python py3-zmq
run: git config --global --add safe.directory ${{ github.workspace }}
sync: 'rsync'
copyback: false
- name: Checkout helper actions
uses: actions/checkout@v4
with:
sparse-checkout: .github/actions
path: ci/nightly
- name: Generate buildsystem
run: |
cd ${{ github.workspace }}
cmake -B build -DWITH_ZMQ=ON -DBUILD_BENCH=ON -DBUILD_FUZZ_BINARY=ON -DWERROR=ON
- name: Build
uses: ./ci/nightly/.github/actions/build-with-ccache
with:
vm: openbsd
- name: Check 'bitcoind' executable
run: |
set -e
cd ${{ github.workspace }}
ls -l ./build/src/bitcoind
file ./build/src/bitcoind
ldd ./build/src/bitcoind
./build/src/bitcoind -version
- name: Run test suite
uses: ./ci/nightly/.github/actions/run-test-suite
with:
vm: openbsd
- name: Run functional tests
if: ${{ ! inputs.skip_functional_tests }}
run: |
cd ${{ github.workspace }}
./build/test/functional/test_runner.py --ci --extended -j ${{ env.CI_NCPU }} --combinedlogslen=99999999 --quiet --tmpdirprefix . --timeout-factor=8
openbsd-depends:
name: 'OpenBSD: depends, no MP'
runs-on: ubuntu-latest
defaults:
run:
shell: openbsd {0}
steps:
- name: Checkout Bitcoin Core repo
uses: actions/checkout@v4
with:
repository: bitcoin/bitcoin
- name: Start OpenBSD VM
uses: vmactions/openbsd-vm@v1
with:
envs: 'CCACHE_COMPILERCHECK CCACHE_DIR CCACHE_MAXSIZE'
prepare: pkg_add bash curl gmake gtar-- cmake git ccache python py3-zmq
run: git config --global --add safe.directory ${{ github.workspace }}
sync: 'rsync'
copyback: false
- name: Checkout helper actions
uses: actions/checkout@v4
with:
sparse-checkout: .github/actions
path: ci/nightly
- name: Build depends
uses: ./ci/nightly/.github/actions/build-depends
with:
vm: openbsd
# TODO: Fix capnp compilation and enable MULTIPROCESS.
# options: "MULTIPROCESS=1"
- name: Generate buildsystem
run: |
cd ${{ github.workspace }}
cmake -B build --toolchain depends/$(./depends/config.guess)/toolchain.cmake -DBUILD_BENCH=ON -DBUILD_FUZZ_BINARY=ON -DWERROR=ON
- name: Build
uses: ./ci/nightly/.github/actions/build-with-ccache
with:
vm: openbsd
- name: Check 'bitcoind' executable
run: |
set -e
cd ${{ github.workspace }}
ls -l ./build/src/bitcoind
file ./build/src/bitcoind
ldd ./build/src/bitcoind
./build/src/bitcoind -version
- name: Run test suite
uses: ./ci/nightly/.github/actions/run-test-suite
with:
vm: openbsd
- name: Run functional tests
if: ${{ ! inputs.skip_functional_tests }}
run: |
cd ${{ github.workspace }}
./build/test/functional/test_runner.py --ci --extended -j ${{ env.CI_NCPU }} --combinedlogslen=99999999 --quiet --tmpdirprefix . --timeout-factor=8