-
Notifications
You must be signed in to change notification settings - Fork 13
42 lines (38 loc) · 1.09 KB
/
c-cpp.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
name: C/C++ CI
on:
push:
branches: [ master ]
pull_request:
branches: [ master ]
jobs:
build:
permissions:
checks: write
pull-requests: write
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Checkout submodules
run: git submodule update --init --recursive
- name: apt-get update
run: sudo apt-get update
- name: Install packages
run: sudo apt-get install libcmocka-dev liburing-dev cmake ninja-build
- name: configure
run: |
mkdir build
echo 'add_compile_options(-fsanitize=address)' > build/local.cmake
echo 'add_link_options(-fsanitize=address)' >> build/local.cmake
cmake -B build -G Ninja -DCMAKE_BUILD_TYPE=Debug
- name: make
run: cmake --build build
- name: test
run: cmake --build build --target test
- name: test-log
if: failure()
run: cat build/Testing/Temporary/LastTest.log
- name: Publish Unit Test Results
uses: EnricoMi/[email protected]
if: always()
with:
files: build/*.xml