-
Notifications
You must be signed in to change notification settings - Fork 10
50 lines (40 loc) · 1.81 KB
/
meson.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
name: CI_meson
on:
workflow_dispatch:
pull_request:
push:
branches:
- main
jobs:
meson-build:
strategy:
fail-fast: false
matrix:
platform:
- { name: Linux GCC 12, os: ubuntu-latest, compiler: g++12, cxx: "g++-12", backend: "ninja", build: "linux-libstdc++", args: ""}
- { name: Linux GCC 12 nounity, os: ubuntu-latest, compiler: g++12, cxx: "g++-12", backend: "ninja", build: "linux-libstdc++", args: "-Dunity_build=false"}
- { name: Linux Clang 14, os: ubuntu-latest, compiler: clang-14, cxx: "clang++-14", backend: "ninja", build: "linux-libc++", args: ""}
- { name: Windows 64, os: windows-latest, compiler: msvc, cxx: "cl", backend: "vs2022 --vsenv", build: "win64-vs2022", args: ""}
- { name: MacOS, os: macos-latest, compiler: clang++, cxx: "clang++", backend: "ninja", build: "osx-libc++", args: ""}
build-type:
- release
name: ${{matrix.platform.name}} ${{matrix.build-type}} ${{matrix.config.name}}
runs-on: ${{matrix.platform.os}}
defaults:
run:
shell: bash
steps:
- name: Checkout code
uses: actions/checkout@v3
- uses: actions/setup-python@v4
with:
python-version: '3.x'
- run: pip install meson ninja
- name: meson setup
run: CXX=${{matrix.platform.cxx}} meson setup ${{matrix.platform.build}} --backend=${{matrix.platform.backend}} -Dbuildtype=${{matrix.build-type}} -Dprefix=`pwd`/../install ${{matrix.platform.args}}
- name: Build
run: meson compile -C ${{matrix.platform.build}}
- name: Install
run: meson install -C ${{matrix.platform.build}}
- name: Test single header
run: meson test -C ${{matrix.platform.build}}