-
Notifications
You must be signed in to change notification settings - Fork 0
43 lines (39 loc) · 1.09 KB
/
cmake.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
name: CMake
on:
push:
branches: [ "main" ]
pull_request:
branches: [ "main" ]
jobs:
build:
name: ${{ matrix.os }}.${{ matrix.compiler }}.${{ matrix.build_type }}
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
os: [ ubuntu-22.04 ]
compiler: [ 'g++-12', 'g++-11', 'clang-14' ]
build_type: [ 'Debug', 'Release' ]
env:
MATRIX_OS: ${{ matrix.os }}
MATRIX_COMPILER: ${{ matrix.compiler }}
MATRIX_BUILD_TYPE: ${{ matrix.build_type }}
steps:
- uses: actions/checkout@v3
- name: Install software
shell: bash
run: |
sudo apt install ${{ matrix.compiler }}
sudo apt install libboost-all-dev
sudo apt install cmake ninja-build
- name: Configure CMake
shell: bash
run: |
source ${{github.workspace}}/actions_config.sh
cmake -B ${{github.workspace}}/build $CMAKE_ARGS -G Ninja
- name: Build
working-directory: ${{github.workspace}}/build
run: ninja
- name: Test
working-directory: ${{github.workspace}}/build
run: ctest