-
Notifications
You must be signed in to change notification settings - Fork 8
71 lines (61 loc) · 1.48 KB
/
clang.yml
File metadata and controls
71 lines (61 loc) · 1.48 KB
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
name: clang
on:
push:
tags:
- 'v*'
branches:
- 'main'
paths-ignore:
- LICENSE
- README.md
- 'docs/**'
- 'schemas/**'
pull_request:
paths-ignore:
- LICENSE
- README.md
- 'docs/**'
- 'schemas/**'
jobs:
build:
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
os: [ubuntu-latest]
build_type: [Release]
c_compiler: [clang]
cpp_compiler: [clang++]
steps:
- name: Checkout
uses: actions/checkout@v4
with:
submodules: recursive
- name: Install clang (Linux)
if: matrix.os == 'ubuntu-latest'
shell: bash -el {0}
run: |
sudo apt install clang
- name: Cache build dependencies
uses: actions/cache@v3
with:
path: |
build/_deps
~/.vcpkg
~/.cache
key: ${{ runner.os }}-build-${{ hashFiles('**/CMakeLists.txt') }}
restore-keys: |
${{ runner.os }}-build-
- name: Configure CMake
shell: bash -el {0}
run: >
cmake -S . -B build -G Ninja
-DCMAKE_CXX_COMPILER=${{ matrix.cpp_compiler }}
-DCMAKE_C_COMPILER=${{ matrix.c_compiler }}
- name: Build
shell: bash -el {0}
run: cmake --build build --target dynohook --config ${{ matrix.build_type }} --parallel
# - name: Test
# shell: bash -el {0}
# working-directory: build
# run: ctest --build-config ${{ matrix.build_type }}