-
Notifications
You must be signed in to change notification settings - Fork 34
97 lines (86 loc) · 2 KB
/
check.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
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
name: Push and PR
on:
push:
paths-ignore:
- '**.md'
- '**.txt'
- 'docs/**'
- '.*'
branches:
- master
pull_request:
paths-ignore:
- '**.md'
- '**.txt'
- 'docs/**'
- '.*'
jobs:
check:
strategy:
fail-fast: false
matrix:
include:
- os: ubuntu-22.04
shell: bash
- os: macos-12
shell: bash
- os: windows-2022
msystem: 'MINGW32'
shell: msys2
- os: windows-2022
msystem: 'UCRT64'
shell: msys2
runs-on: ${{ matrix.os }}
defaults:
run:
shell: ${{ matrix.shell }} {0}
steps:
- uses: actions/checkout@v4
# cmake pulls ninja by default
- name: Install dependencies (MSYS)
if: matrix.os == 'windows-2022'
uses: msys2/setup-msys2@v2
with:
msystem: ${{ matrix.msystem }}
update: true
install: >-
git
pacboy: >-
toolchain:p
glib2:p
cmake:p
- name: Install dependencies (Ubuntu)
if: matrix.os == 'ubuntu-22.04'
run: >
sudo apt-get install -y
build-essential
cmake
ninja-build
libglib2.0-dev
libxml2-utils
- name: Install dependencies (MacOS)
if: matrix.os == 'macos-12'
run: |
brew install cmake ninja
- name: Pre-build
run: |
cmake -G Ninja -S . -B build -DCMAKE_BUILD_TYPE=RelWithDebInfo
- name: Build
run: |
cmake --build build -v
- name: Test prefixed install
run: |
cmake --install build --prefix inst --strip -v
- name: Basic CTest
continue-on-error: true
id: basic_ctest
env:
MSYS2_PATH_TYPE: inherit
run: |
cd build && ctest
- name: Rerun failed tests
if: steps.basic_ctest.outcome == 'failure'
env:
MSYS2_PATH_TYPE: inherit
run: |
cd build && ctest --rerun-failed --output-on-failure -V