OmniOS #41
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
name: OmniOS | |
on: | |
pull_request: | |
paths: | |
- '.github/actions/**' | |
- '.github/workflows/omnios.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: 600M | |
CCACHE_COMPRESS: 1 | |
# 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: | |
omnios: | |
name: 'OmniOS: system libs, no BDB, no GUI' | |
runs-on: ubuntu-latest | |
defaults: | |
run: | |
shell: omnios {0} | |
steps: | |
- name: Checkout Bitcoin Core repo | |
uses: actions/checkout@v4 | |
with: | |
repository: bitcoin/bitcoin | |
- name: Start OmniOS VM | |
uses: vmactions/omnios-vm@v1 | |
with: | |
envs: 'CCACHE_COMPILERCHECK CCACHE_DIR CCACHE_MAXSIZE CCACHE_COMPRESS' | |
prepare: | | |
pkg list -H -o name,publisher,version > packages_before | |
pkg install cmake git gcc14 pkg-config ccache sqlite-3 python-312 | |
pkg set-publisher -g https://sfe.opencsw.org/localhostomnios localhostomnios | |
pkg install boost/header-boost libevent2 | |
pkg list -H -o name,publisher,version > packages_after | |
diff -w packages_before packages_after | grep '^>' | |
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 }} | |
export CMAKE_PREFIX_PATH="/usr/g++" # For boost/header-boost package. | |
export PKG_CONFIG_PATH="/usr/gnu/lib/amd64/pkgconfig" # For libevent2 package. | |
# Workaround for a bug in the FindThreads module. | |
# See: https://gitlab.kitware.com/cmake/cmake/-/issues/26063 | |
export CXXFLAGS="-pthread" | |
cmake -B build -DBUILD_BENCH=ON -DBUILD_FUZZ_BINARY=ON -DWERROR=ON | |
- name: Build | |
uses: ./ci/nightly/.github/actions/build-with-ccache | |
with: | |
vm: omnios | |
- name: Check 'bitcoind' executable | |
run: | | |
set -e | |
cd ${{ github.workspace }} | |
export LD_LIBRARY_PATH="/opt/gcc-14/lib/amd64:/usr/gnu/lib/amd64" | |
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: omnios | |
envs: 'LD_LIBRARY_PATH="/opt/gcc-14/lib/amd64:/usr/gnu/lib/amd64"' | |
# TODO: https://github.com/bitcoin/bitcoin/pull/31580 | |
# TODO: Fix the code, then enable system_tests. | |
options: '--exclude-regex "^(net_tests|system_tests)$"' | |
- name: Run functional tests | |
if: ${{ ! inputs.skip_functional_tests }} | |
run: | | |
cd ${{ github.workspace }} | |
export LD_LIBRARY_PATH="/opt/gcc-14/lib/amd64:/usr/gnu/lib/amd64" | |
./build/test/functional/test_runner.py --ci --extended -j ${{ env.CI_NCPU }} --combinedlogslen=99999999 --quiet --tmpdirprefix . --timeout-factor=8 |