Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 4 additions & 2 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -34,11 +34,13 @@ on:
- LICENSE
- meta/**
- README.md

env:
ACTIONS_STEP_DEBUG: true
ACTIONS_RUNNER_DEBUG: true
jobs:
call-boost-ci:
name: Run Boost.CI
uses: boostorg/boost-ci/.github/workflows/reusable.yml@master
uses: boostorg/boost-ci/.github/workflows/reusable.yml@node24
# Customization:
with:
enable_reflection: true
Expand Down
70 changes: 49 additions & 21 deletions .github/workflows/reusable.yml
Original file line number Diff line number Diff line change
Expand Up @@ -122,8 +122,9 @@ env:
B2_LINK: shared,static
LCOV_BRANCH_COVERAGE: ${{ inputs.branch_coverage && '1' || '0' }}
CODECOV_NAME: Github Actions
ACTIONS_ALLOW_USE_UNSECURE_NODE_VERSION: true
DEPINST: ${{ inputs.depinst_args }}
ACTIONS_STEP_DEBUG: true
ACTIONS_RUNNER_DEBUG: true

jobs:
generate-posix-matrix:
Expand Down Expand Up @@ -290,8 +291,10 @@ jobs:
container:
image: ${{matrix.container}}
volumes:
- /node20217:/node20217:rw,rshared
- ${{ startsWith(matrix.container, 'ubuntu:1') && '/node20217:/__e/node20:ro,rshared' || ' ' }}
- /node20_217:/node20_217:rw,rshared
- /node24_217:/node24_217:rw,rshared
- ${{ startsWith(matrix.container, 'ubuntu:1') && '/node20_217:/__e/node20:ro,rshared' || ' ' }}
- ${{ startsWith(matrix.container, 'ubuntu:1') && '/node24_217:/__e/node24:ro,rshared' || ' ' }}

env: {B2_USE_CCACHE: 1}

Expand All @@ -303,16 +306,19 @@ jobs:
export DEBIAN_FRONTEND=noninteractive
fi
if [ -n "${{matrix.container}}" ] && [ -f "/etc/debian_version" ]; then
echo "::group::Install core tools"
apt-get -o Acquire::Retries=$NET_RETRY_COUNT update
apt-get -o Acquire::Retries=$NET_RETRY_COUNT -y -q --no-install-suggests --no-install-recommends install sudo software-properties-common curl
echo "::endgroup::"
echo "::group::Check & setup git version"
if ! git_version=$(git --version 2>/dev/null); then
git_version=0.0.0
fi
# Extract version number from e.g. "git version 2.7.4"
version=${git_version##* }
echo "Git version: $version"
required_git_version="2.9"
if [[ ${GIT_FETCH_JOBS:-1} != "1" ]] && [[ "$(printf '%s\n' "$required" "$version" | sort -V | head -n1)" != "$required" ]]; then
required_git_version="2.18" # actions/checkout requires git 2.18
if [[ "$(printf '%s\n' "$required_git_version" "$version" | sort -V | head -n1)" != "$required_git_version" ]]; then
# Need (newer) git, and the older Ubuntu container may require requesting the key manually using port 80
key_server="keyserver.boost.org"
echo "Downloading key from $key_server"
Expand All @@ -321,16 +327,22 @@ jobs:
sudo -E add-apt-repository -y ppa:git-core/ppa && break || sleep 10
done
fi
echo "::endgroup::"
echo "::group::Update APT cache"
apt-get -o Acquire::Retries=$NET_RETRY_COUNT update
osver=$(lsb_release -sr | cut -f1 -d.)
echo "::endgroup::"
pkgs="g++ git xz-utils"
osver=$(lsb_release -sr | cut -f1 -d.)
echo "OS version: $osver"
# Ubuntu 22+ has only Python 3 in the repos
if [ -n "$osver" ] && [ "$osver" -ge "20" ]; then
pkgs+=" python-is-python3 libpython3-dev"
else
pkgs+=" python libpython-dev"
fi
echo "::group::Install $pkgs"
apt-get -o Acquire::Retries=$NET_RETRY_COUNT -y -q --no-install-suggests --no-install-recommends install $pkgs
echo "::endgroup::"
fi
# For jobs not compatible with ccache, use "ccache: no" in the matrix
if [[ "${{ matrix.ccache }}" == "no" ]]; then
Expand All @@ -344,25 +356,41 @@ jobs:
fi
git config --global pack.threads 0
if [[ "${{matrix.container}}" == "ubuntu:1"* ]]; then
# Node 20 doesn't work with Ubuntu 16/18 glibc: https://github.com/actions/checkout/issues/1590
curl -sL https://archives.boost.io/misc/node/node-v20.9.0-linux-x64-glibc-217.tar.xz | tar -xJ --strip-components 1 -C /node20217
echo "::group::Update node"
which node || true
node --version || true
for d in "/node20_217" "/node24_217" "/__e/node20" "/__e/node24"; do
echo "$d";
find "$d" -type f || true
done
# Install a node version that works with the glibc 2.17 of Ubuntu 16/18: https://github.com/actions/checkout/issues/1590
curl -sL https://archives.boost.io/misc/node/node-v20.9.0-linux-x64-glibc-217.tar.xz | tar -xJ --strip-components 1 -C /node20_217
curl -sL https://archives.boost.io/misc/node/node-v24.15.0-linux-x64-glibc-217.tar.xz | tar -xJ --strip-components 1 -C /node24_217
node --version || true
for d in "/node20_217" "/node24_217" "/__e/node20" "/__e/node24"; do
echo "$d";
find "$d" -type f || true
done
/node20_217/bin/node --version || true
/node24_217/bin/node --version || true
echo "::endgroup::"
fi

- uses: actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5 # v4.3.1
- uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0
with:
# For coverage builds fetch the whole history, else only 1 commit using a 'fake ternary'
fetch-depth: ${{ matrix.coverage && '0' || '1' }}

- name: Cache ccache
uses: actions/cache@0057852bfaa89a56745cba8c7296529d2fc39830 # v4.3.0
uses: actions/cache@2c8a9bd7457de244a408f35966fab2fb45fda9c8 # v6.0.0
if: env.B2_USE_CCACHE
with:
path: ~/.ccache
key: ${{matrix.os}}-${{matrix.container}}-${{matrix.xcode_app}}${{matrix.compiler}}-${{github.sha}}
restore-keys: ${{matrix.os}}-${{matrix.container}}-${{matrix.xcode_app}}${{matrix.compiler}}-

- name: Fetch Boost.CI
uses: actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5 # v4.3.1
uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0
with:
repository: boostorg/boost-ci
ref: master
Expand Down Expand Up @@ -568,10 +596,10 @@ jobs:
matrix: ${{fromJson(needs.generate-windows-matrix.outputs.matrix)}}

steps:
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
- uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0

- name: Fetch Boost.CI
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0
with:
repository: boostorg/boost-ci
ref: master
Expand All @@ -584,7 +612,7 @@ jobs:

- name: Setup cygwin
if: ${{ matrix.target-os == 'cygwin' }}
uses: cygwin/cygwin-install-action@711d29f3da23c9f4a1798e369a6f01198c13b11a # v6.1
uses: cygwin/cygwin-install-action@3f0a3f9f988f7e96b8c18098ae05eaec175f5b52 # v6.1
with:
site: ${{ matrix.address-model == '64' && 'https://www.mirrorservice.org/sites/sourceware.org/pub/cygwin' || 'https://ftp-stud.hs-esslingen.de/pub/Mirrors/sources.redhat.com/cygwin-archive/20221123' }}
packages: coreutils, gcc-g++, libstdc++6, make, moreutils, openssl, libbz2-devel, libgmp-devel, libicu-devel, libjpeg-devel, libmpfr-devel, libpng-devel, libssl-devel, libtiff-devel, libxslt-devel, libzstd-devel
Expand Down Expand Up @@ -697,18 +725,18 @@ jobs:
matrix: ${{fromJson(needs.generate-mingw-matrix.outputs.matrix)}}

steps:
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
- uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0

- name: Setup MSYS2 environment for MinGW
uses: msys2/setup-msys2@4f806de0a5a7294ffabaff804b38a9b435a73bda # v2.30.0
uses: msys2/setup-msys2@66cd2cce69caa17b53920067426061ca1de3a884 # v2.32.0
with:
msystem: ${{matrix.sys}}
update: true
install: git python
pacboy: gcc:p cmake:p ninja:p

- name: Fetch Boost.CI
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0
with:
repository: boostorg/boost-ci
ref: master
Expand Down Expand Up @@ -769,7 +797,7 @@ jobs:
- name: Cache CMake
if: matrix.cmake_version
id: cache-cmake
uses: actions/cache@cdf6c1fa76f9f475f3d7449005a359c84ca0f306 # v5.0.3
uses: actions/cache@2c8a9bd7457de244a408f35966fab2fb45fda9c8 # v6.0.0
with:
path: /tmp/cmake
key: ${{runner.os}}-cmake-${{matrix.cmake_version}}
Expand Down Expand Up @@ -802,17 +830,17 @@ jobs:
cmake --build __build -- -j 3
cmake --build __build --target install

- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
- uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0

- name: Cache ccache
uses: hendrikmuhs/ccache-action@5ebbd400eff9e74630f759d94ddd7b6c26299639 # v1.2.20
uses: hendrikmuhs/ccache-action@d62db5f07c26379fc4b4e0916f098a92573c3b03 # v1.2.23
if: runner.os == 'Linux'
with:
create-symlink: true
key: ${{matrix.os}}-${{matrix.build_shared}}

- name: Fetch Boost.CI
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0
with:
repository: boostorg/boost-ci
ref: master
Expand Down
Loading