[WIP] Add simple CMake presets #144
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
--- | |
name: CI-Linux | |
on: [push, pull_request] | |
jobs: | |
build: | |
name: Build and Test | |
runs-on: ${{ matrix.os }} | |
strategy: | |
fail-fast: false | |
matrix: | |
os: [ubuntu-22.04] | |
compiler: | |
- gcc-9 | |
- gcc-10 | |
- gcc-11 | |
- clang-12 | |
- clang-13 | |
- clang-14 | |
steps: | |
- name: Update system | |
run: sudo apt-get update | |
- name: Install prerequisites | |
run: >- | |
sudo apt-get install -y | |
libgcrypt20-dev | |
${{ matrix.compiler }} | |
cmake | |
ninja-build | |
doxygen | |
graphviz | |
- uses: actions/checkout@v3 | |
- name: Configure | |
run: | | |
export CXX=$(echo ${{ matrix.compiler }} | sed -E 's/^(g|clang)(cc)?/\1++/') | |
cmake --preset default --fresh | |
- name: Build | |
run: cmake --build --preset srecord-executables | |
- name: Smoke test | |
run: cmake --build --preset srecord-executables-version | |
- name: Build test prerequisites | |
run: cmake --build --preset prepare-test | |
- name: Test | |
working-directory: build | |
run: ctest --output-on-failure --output-junit ctest.junit.xml |