-
Notifications
You must be signed in to change notification settings - Fork 11
30 lines (24 loc) · 1.26 KB
/
all_platforms.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
name: All Platforms
on: [push]
jobs:
build:
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ubuntu-22.04, ubuntu-20.04, macos-12, macos-11, windows-2022, windows-2019]
build_type: ['Release', 'Debug']
cxx_std: [11, 14, 17, 20]
steps:
- uses: actions/checkout@v3
- name: Build with cxx standard specified
run: |
cmake -B ${{github.workspace}}/build/${{matrix.build_type}} -DCMAKE_CXX_STANDARD=${{matrix.cxx_std}} -DCMAKE_INSTALL_PREFIX="${{github.workspace}}/install/${{matrix.build_type}}" -DDEPS=REMOTE
cmake --build ${{github.workspace}}/build/${{matrix.build_type}} --config ${{matrix.build_type}} --target install
- name: Build tests with install space
run: |
cmake -S ${{github.workspace}}/tests -B ${{github.workspace}}/build-tests-standalone/${{matrix.build_type}} -DCMAKE_CXX_STANDARD=${{matrix.cxx_std}} -DCMAKE_PREFIX_PATH="${{github.workspace}}/install/${{matrix.build_type}}" -DDEPS=REMOTE
cmake --build ${{github.workspace}}/build-tests-standalone/${{matrix.build_type}} --config ${{matrix.build_type}}
- name: Test
env:
CTEST_OUTPUT_ON_FAILURE: 1
run: ctest -C ${{matrix.build_type}} --test-dir ${{github.workspace}}/build/${{matrix.build_type}}