new sync IO api #3193
Workflow file for this run
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
# TODO(2.0): Support g++ once they fix coroutines. This also blocks MinGW and ManyLinux builds. | |
name: Quick Tests | |
on: | |
pull_request: | |
paths-ignore: | |
- 'doc/**' | |
push: | |
branches: | |
- master | |
- v2 | |
- 'release-*' | |
jobs: | |
Linux-musl: | |
runs-on: ubuntu-20.04 | |
# We depend on both clang and libc++. Alpine Linux 3.17 seems to be the first version to include | |
# a libc++ package (based on LLVM 15), but building capnproto failed when I tried it. | |
# Alpine Linux 3.18's libc++ package is from LLVM 16, however, and worked out-of-the-box, so | |
# Clang 16 appears to be the earliest Clang version we can run easily on Alpine Linux. | |
container: alpine:3.18.2 | |
steps: | |
- uses: actions/checkout@v4 | |
- name: install dependencies | |
run: apk add autoconf automake bash build-base cmake libtool libucontext-dev linux-headers openssl-dev clang16 libc++-dev | |
- name: super-test | |
run: ./super-test.sh quick clang-16 | |
Linux-clang: | |
runs-on: ubuntu-latest | |
strategy: | |
fail-fast: false | |
matrix: | |
clang: [11, 12, 13, 14, 15] | |
driver: [bazel, super-test] | |
include: | |
- driver: bazel | |
run-test: cd c++ && bazel test --verbose_failures --test_output=errors -k //... | |
- driver: super-test | |
run-test: ./super-test.sh quick | |
- clang: 12 | |
# clang-12 on Ubuntu requires libunwind to be installed explicitly | |
libunwind: libunwind-12-dev | |
steps: | |
- uses: actions/checkout@v4 | |
- name: install dependencies | |
# I observed 404s for some packages and added an `apt-get update`. Then, I observed package | |
# conflicts between LLVM 14 and 15, and added the line which removes LLVM 14, the default on | |
# Ubuntu as of this writing. | |
run: | | |
export DEBIAN_FRONTEND=noninteractive | |
sudo apt-get update | |
sudo apt-get remove clang-14 libc++1-14 libc++abi1-14 libc++-14-dev libc++abi-14-dev libunwind-14 libunwind-14-dev | |
sudo apt-get install -y build-essential git zlib1g-dev cmake libssl-dev clang-${{ matrix.clang }} libc++-${{ matrix.clang }}-dev libc++abi-${{ matrix.clang }}-dev ${{ matrix.libunwind }} | |
- name: test | |
run: | | |
export CC=clang-${{ matrix.clang }} | |
export CXX=clang++-${{ matrix.clang }} | |
${{ matrix.run-test }} | |
Linux-lock-tracking: | |
runs-on: ubuntu-latest | |
strategy: | |
fail-fast: false | |
matrix: | |
compiler: [clang-14] | |
features: ["-DKJ_TRACK_LOCK_BLOCKING=1 -DKJ_SAVE_ACQUIRED_LOCK_INFO=1 -DKJ_CONTENTION_WARNING_THRESHOLD=200"] | |
steps: | |
- uses: actions/checkout@v4 | |
- name: install dependencies | |
run: | | |
export DEBIAN_FRONTEND=noninteractive | |
sudo apt-get install -y build-essential git zlib1g-dev cmake libssl-dev ${{ matrix.compiler }} | |
- name: super-test ${{ matrix.compiler }} | |
run: | | |
# librt is used for timer_create in the unit tests for lock tracking (mutex-test.c++). | |
./super-test.sh quick ${{ matrix.compiler }} cpp-features "${{matrix.features}}" extra-libs "-lrt" | |
MacOS: | |
runs-on: macos-latest | |
strategy: | |
fail-fast: false | |
steps: | |
- uses: actions/checkout@v4 | |
- name: install dependencies | |
run: | | |
brew install autoconf automake libtool pkg-config | |
- name: super-test | |
run: | | |
./super-test.sh quick | |
MSVC: | |
runs-on: ${{ matrix.os }} | |
strategy: | |
fail-fast: false | |
matrix: | |
os: ['windows-latest'] | |
include: | |
- os: windows-latest | |
target: 'Visual Studio 17 2022' | |
arch: -A x64 | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Include $CONDA in $PATH | |
run: | | |
echo "$Env:CONDA\condabin" >> $env:GITHUB_PATH | |
- name: Install dependencies via Conda | |
run: | | |
conda update -n base -c defaults -q conda | |
conda install -n base -c defaults -q ninja openssl zlib | |
- name: Build and test | |
shell: cmd | |
run: | | |
echo "Activate conda base environment" | |
call activate base | |
echo "Building Cap'n Proto with ${{ matrix.target }}" | |
cmake -Hc++ -Bbuild-output ${{ matrix.arch }} -G "${{ matrix.target }}" -DCMAKE_BUILD_TYPE=debug -DCMAKE_PREFIX_PATH="%CONDA_PREFIX%" -DCMAKE_INSTALL_PREFIX=%CD%\capnproto-c++-install | |
cmake --build build-output --config debug --target install | |
echo "Building Cap'n Proto samples with ${{ matrix.target }}" | |
cmake -Hc++/samples -Bbuild-output-samples ${{ matrix.arch }} -G "${{ matrix.target }}" -DCMAKE_BUILD_TYPE=debug -DCMAKE_PREFIX_PATH=%CD%\capnproto-c++-install | |
cmake --build build-output-samples --config debug | |
cd build-output\src | |
ctest -V -C debug |