Merge the CI workflow files
This commit is contained in:
85
.github/workflows/ci.yaml
vendored
Normal file
85
.github/workflows/ci.yaml
vendored
Normal file
@@ -0,0 +1,85 @@
|
||||
name: ci
|
||||
|
||||
on: [push, pull_request]
|
||||
|
||||
jobs:
|
||||
ci:
|
||||
name: ${{ matrix.name }}
|
||||
runs-on: ${{ matrix.os }}
|
||||
|
||||
env:
|
||||
CTEST_OUTPUT_ON_FAILURE: ON
|
||||
CTEST_PARALLEL_LEVEL: 2
|
||||
|
||||
strategy:
|
||||
fail-fast: false
|
||||
matrix:
|
||||
include:
|
||||
- name: gcc-static
|
||||
os: ubuntu-20.04
|
||||
compiler: gcc
|
||||
generator: Ninja
|
||||
cmake-args: "-DBUILD_SHARED_LIBS=OFF"
|
||||
- name: gcc-dynamic
|
||||
os: ubuntu-20.04
|
||||
compiler: gcc
|
||||
generator: Ninja
|
||||
cmake-args: "-DBUILD_SHARED_LIBS=ON"
|
||||
- name: gcc-minimal
|
||||
os: ubuntu-20.04
|
||||
compiler: gcc
|
||||
generator: Ninja
|
||||
cmake-args: "-DSODIUM_MINIMAL=ON"
|
||||
- name: clang-static
|
||||
os: ubuntu-20.04
|
||||
compiler: clang
|
||||
generator: Ninja
|
||||
cmake-args: "-DBUILD_SHARED_LIBS=OFF"
|
||||
- name: clang-dynamic
|
||||
os: ubuntu-20.04
|
||||
compiler: clang
|
||||
generator: Ninja
|
||||
cmake-args: "-DBUILD_SHARED_LIBS=ON"
|
||||
- name: clang-minimal
|
||||
os: ubuntu-20.04
|
||||
compiler: clang
|
||||
generator: Ninja
|
||||
cmake-args: "-DSODIUM_MINIMAL=ON"
|
||||
- name: windows-2019-cl-x86
|
||||
os: windows-2019
|
||||
generator: Visual Studio 16 2019
|
||||
cmake-args: -A Win32
|
||||
- name: windows-2019-cl-x64
|
||||
os: windows-2019
|
||||
generator: Visual Studio 16 2019
|
||||
cmake-args: -A x64
|
||||
|
||||
steps:
|
||||
- uses: actions/checkout@v3
|
||||
with:
|
||||
submodules: true
|
||||
|
||||
- uses: actions/setup-python@v3
|
||||
with:
|
||||
python-version: "3.10"
|
||||
|
||||
- name: Install
|
||||
run: pip install cmake==3.22.4 ninja==1.10.2.3 --upgrade
|
||||
|
||||
- name: Setup
|
||||
run: echo "CC=${{ matrix.compiler }}" >> $GITHUB_ENV
|
||||
if: startsWith(matrix.os, 'ubuntu')
|
||||
|
||||
- name: CMake
|
||||
run: cmake -S . -B build -G "${{ matrix.generator }}" ${{ matrix.cmake-args }}
|
||||
|
||||
- name: Build
|
||||
run: cmake --build build
|
||||
|
||||
- name: Test
|
||||
run: (cd build && ctest)
|
||||
if: startsWith(matrix.os, 'ubuntu')
|
||||
|
||||
- name: Test
|
||||
run: (cd build && ctest -C Debug )
|
||||
if: startsWith(matrix.os, 'windows')
|
||||
Reference in New Issue
Block a user