-
Notifications
You must be signed in to change notification settings - Fork 1
92 lines (89 loc) · 2.61 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
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
name: C/C++ CI
on:
push:
branches: [ master ]
pull_request:
branches: [ master ]
jobs:
build:
timeout-minutes: 30
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: apt update
run: sudo apt update
- name: dpkg / rpm prep (debug)
run: echo "sudo -E apt-get install -y uuid-dev uuid libuuid1 libaio-dev libaio1 libgcrypt20 openssl libssl-dev `apt-cache search librocksdb | awk '{print $1}'` uncrustify libasan5 libtsan0"
- name: dpkg / rpm prep
run: sudo -E apt-get install -y uuid-dev uuid libuuid1 libaio-dev libaio1 libgcrypt20 openssl libssl-dev `apt-cache search librocksdb | awk '{print $1}'` uncrustify libasan5 libtsan0
# capture gcc and clang versions
- name: gcc version
run: gcc --version
- name: clang version
run: clang --version
# build backtrace submodule
- name: submodule init
run: git submodule init && git submodule update
# build backtrace submodule
- name: build libbacktrace
run: cd modules/libbacktrace/ && ./configure && make && sudo make install
# default build
- name: prepare default build
run: ./prepare.sh
- name: configure
run: ./configure
- name: make
run: make -j 4
- name: make check (default)
run: make check
- name: Dump logs if failure
run: find test -name \*.log -exec cat {} \;
if: ${{ failure() }}
# asan build
- name: distclean
run: make distclean
- name: prepare address sanitizer build
run: ./prepare.sh
- name: configure with address-sanitizer
run: ./configure --enable-asan --enable-devel
- name: make
run: make -j 4
- name: make check (asan)
run: make check
- name: Dump logs if failure
run: find test -name \*.log -exec cat {} \;
if: ${{ failure() }}
# clang build
- name: distclean
run: make distclean
- name: prepare clang build
run: ./prepare.sh
- name: configure CC=clang
run: ./configure CC=clang
- name: make
run: make -j 4
- name: make check (clang)
run: make check
- name: Dump logs if failure
run: find test -name \*.log -exec cat {} \;
if: ${{ failure() }}
# other targets
- name: uncrustify version (debug)
run: uncrustify -v
- name: make autofmt-check
run: make autofmt-check
# gather some system stats
- name: memory
run: free
- name: net
run: ip a
- name: disk
run: df -h
- name: process
run: ps auxfw
- name: cpu
run: cat /proc/cpuinfo
- name: ulimit
run: ulimit -a
- name: limits.conf
run: cat /etc/security/limits.conf