forked from scylladb/seastar
-
Notifications
You must be signed in to change notification settings - Fork 21
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
4 changed files
with
194 additions
and
95 deletions.
There are no files selected for viewing
This file was deleted.
Oops, something went wrong.
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
name: Python format | ||
|
||
on: [push, pull_request] | ||
|
||
jobs: | ||
python-format: | ||
name: Enforce python format | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v4 | ||
- uses: psf/[email protected] | ||
with: | ||
version: "24.8.0" | ||
src: ./scripts | ||
# override options so that we can specify only specific files for now | ||
options: "--check --diff --include=.*addr2line.*" |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,114 @@ | ||
name: Test | ||
|
||
permissions: | ||
contents: read | ||
|
||
on: | ||
workflow_call: | ||
inputs: | ||
compiler: | ||
description: 'the C++ compiler to use' | ||
type: string | ||
required: true | ||
standard: | ||
description: 'the C++ standard to use' | ||
type: number | ||
required: true | ||
mode: | ||
description: 'build mode (debug, dev or release)' | ||
type: string | ||
required: true | ||
enables: | ||
description: 'the --enable-* option passed to configure.py' | ||
type: string | ||
default: '' | ||
required: false | ||
enable-ccache: | ||
description: 'build with ccache enabled' | ||
type: boolean | ||
default: true | ||
required: false | ||
options: | ||
description: 'additional options passed to configure.py' | ||
type: string | ||
default: '' | ||
required: false | ||
crypto_provider: | ||
description: 'cryptographic provider to use' | ||
type: string | ||
default: 'GnuTLS' | ||
required: false | ||
|
||
jobs: | ||
test: | ||
timeout-minutes: 40 | ||
runs-on: ubuntu-latest | ||
container: fedora:40 | ||
steps: | ||
- name: Install Git | ||
run: | | ||
sudo dnf -y install git | ||
- uses: actions/checkout@v4 | ||
with: | ||
submodules: "${{ contains(inputs.enables, 'dpdk') }}" | ||
|
||
- name: Install build dependencies | ||
run: | | ||
sudo ./install-dependencies.sh | ||
- name: Install clang++ | ||
if: ${{ inputs.compiler == 'clang++' }} | ||
run: | | ||
sudo dnf -y install clang | ||
- name: Install clang-scan-deps | ||
if: ${{ contains(inputs.enables, 'cxx-modules') }} | ||
run: | | ||
sudo dnf -y install clang-tools-extra | ||
- name: Install ccache | ||
if: ${{ inputs.enable-ccache }} | ||
run: | | ||
sudo dnf -y install ccache | ||
- name: Setup ccache | ||
if: ${{ inputs.enable-ccache }} | ||
uses: hendrikmuhs/ccache-action@v1 | ||
with: | ||
key: ${{ inputs.compiler }}-${{ inputs.standard }}-${{ inputs.mode }}-${{ inputs.enables }} | ||
|
||
- name: Configure | ||
run: | | ||
if [ ${{ inputs.compiler }} = "clang++" ]; then | ||
CC=clang | ||
else | ||
CC=gcc | ||
fi | ||
if ${{ inputs.enable-ccache }}; then | ||
MAYBE_CCACHE_OPT="--ccache" | ||
fi | ||
./configure.py \ | ||
--c++-standard ${{ inputs.standard }} \ | ||
--compiler ${{ inputs.compiler }} \ | ||
--c-compiler $CC \ | ||
--mode ${{ inputs.mode }} \ | ||
$MAYBE_CCACHE_OPT \ | ||
${{ inputs.options }} \ | ||
${{ inputs.enables }} \ | ||
--crypto-provider ${{ inputs.crypto_provider }} | ||
- name: Build | ||
run: cmake --build build/${{inputs.mode}} | ||
|
||
- name: Check Header | ||
if: ${{ inputs.mode == 'dev' && inputs.compiler == 'clang++' }} | ||
run: cmake --build build/${{ inputs.mode }} --target checkheaders | ||
|
||
- name: Build with C++20 modules | ||
if: ${{ contains(inputs.enables, 'cxx-modules') }} | ||
run: cmake --build build/${{ inputs.mode }} --target hello_cxx_module | ||
|
||
- name: Test | ||
if: ${{ ! contains(inputs.enables, 'cxx-modules') }} | ||
run: ./test.py --mode=${{ inputs.mode }} |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,64 @@ | ||
name: Test | ||
|
||
permissions: | ||
contents: read | ||
|
||
on: [push, pull_request] | ||
|
||
concurrency: | ||
group: ${{ github.workflow }}-${{ github.ref }} | ||
cancel-in-progress: ${{ startsWith(github.ref, 'refs/pull/') }} | ||
|
||
jobs: | ||
regular_test: | ||
name: "Test (${{ matrix.compiler }}, C++${{ matrix.standard}}, ${{ matrix.mode }}, ${{ matrix.crypto_provider }})" | ||
uses: ./.github/workflows/test.yaml | ||
strategy: | ||
fail-fast: false | ||
matrix: | ||
compiler: [clang++, g++] | ||
standard: [20, 23] | ||
mode: [dev, debug, release] | ||
crypto_provider: [GnuTLS, OpenSSL] | ||
with: | ||
compiler: ${{ matrix.compiler }} | ||
standard: ${{ matrix.standard }} | ||
mode: ${{ matrix.mode }} | ||
enables: ${{ matrix.enables }} | ||
options: ${{ matrix.options }} | ||
crypto_provider: ${{ matrix.crypto_provider }} | ||
build_with_dpdk: | ||
name: "Test with DPDK enabled" | ||
uses: ./.github/workflows/test.yaml | ||
strategy: | ||
fail-fast: false | ||
with: | ||
compiler: clang++ | ||
standard: 23 | ||
mode: release | ||
enables: --enable-dpdk | ||
options: --cook dpdk | ||
build_with_cxx_modules_gnutls: | ||
name: "Test with C++20 modules enabled (GnuTLS)" | ||
uses: ./.github/workflows/test.yaml | ||
strategy: | ||
fail-fast: false | ||
with: | ||
compiler: clang++ | ||
standard: 23 | ||
mode: debug | ||
enables: --enable-cxx-modules | ||
enable-ccache: false | ||
crypto_provider: GnuTLS | ||
build_with_cxx_modules_openssl: | ||
name: "Test with C++20 modules enabled (OpenSSL)" | ||
uses: ./.github/workflows/test.yaml | ||
strategy: | ||
fail-fast: false | ||
with: | ||
compiler: clang++ | ||
standard: 23 | ||
mode: debug | ||
enables: --enable-cxx-modules | ||
enable-ccache: false | ||
crypto_provider: OpenSSL |