-
Notifications
You must be signed in to change notification settings - Fork 1
31 lines (29 loc) · 983 Bytes
/
linux.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
name: linux
on: [push, pull_request]
jobs:
build:
runs-on: ${{matrix.config.os}}
strategy:
fail-fast: false
matrix:
config:
# https://github.com/actions/virtual-environments/tree/main/images/linux
- { os: "ubuntu-20.04", cc: "gcc-7", cxx: "g++-7" }
- { os: "ubuntu-20.04", cc: "clang-7", cxx: "clang++-7" }
- { os: "ubuntu-22.04", cc: "gcc-12", cxx: "g++-12" }
- { os: "ubuntu-22.04", cc: "clang-14", cxx: "clang++-14" }
name: "${{matrix.config.cxx}}"
steps:
- name: Setup
run: sudo apt-get -y install cmake ninja-build ${{matrix.config.cc}} ${{matrix.config.cxx}}
- name: Checkout
uses: actions/checkout@v3
with:
submodules: true
- name: Build
run: |
cmake --preset linux-${{matrix.config.cc}}
cmake --build --preset linux-${{matrix.config.cc}}-release
- name: Test
run: |
ctest --preset linux-${{matrix.config.cc}}-release