forked from grobian/carbon-c-relay
-
Notifications
You must be signed in to change notification settings - Fork 0
118 lines (113 loc) · 3.59 KB
/
build-test-ci.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
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
# GitHub actions workflow.
# https://docs.github.com/en/actions/learn-github-actions/workflow-syntax-for-github-actions
name: Build+Test CI
on:
push:
branches:
- master
tags:
- v*
pull_request:
types:
- opened
branches:
- master
jobs:
make-check-ubuntu-x64:
strategy:
matrix:
os:
- ubuntu-latest
cc:
- gcc
- clang
features:
# everything disabled, this MUST work
- >
--without-gzip --without-lz4 --without-ssl
--without-oniguruma --without-pcre2 --without-pcre
# gzip
- --with-gzip --without-lz4 --without-ssl
# lz4
- --without-gzip --with-lz4 --without-ssl
# gzip/lz4
- --with-gzip --with-lz4 --without-ssl
# gzip/lz4/ssl
- --with-gzip --with-lz4 --with-ssl
# oniguruma
- --with-oniguruma --without-pcre2 --without-pcre
# pcre
- --without-oniguruma --without-pcre2 --with-pcre
# all defaults (detect)
- ""
runs-on: ${{ matrix.os }}
env:
CC: ${{ matrix.cc }}
steps:
- name: install deps
run: >
sudo apt-get install -y
libonig-dev libpcre3-dev libssl-dev
zlib1g-dev libsnappy-dev liblz4-dev
wget
- uses: actions/checkout@v2
- name: fix timestamps
# workaround git not retaining mtimes and bison/flex not being
# uptodate
run: |
touch conffile.yy.c conffile.tab.c conffile.tab.h
touch configure.ac Makefile.am aclocal.m4 configure
touch Makefile.in config.h.in
- name: configure variant ${{ matrix.features }}
run: ./configure --disable-maintainer-mode ${{ matrix.features }}
- name: make variant ${{ matrix.features }}
run: make CFLAGS="-O3 -Wall -Werror -Wshadow -pipe" clean check
make-check-macos-x64:
strategy:
matrix:
os:
- macos-latest
cc:
- clang
features:
# everything disabled, this MUST work
- >
--without-gzip --without-lz4 --without-ssl
--without-oniguruma --without-pcre2 --without-pcre
# all defaults (detect)
- ""
runs-on: ${{ matrix.os }}
env:
CC: ${{ matrix.cc }}
steps:
- name: install deps
run: brew install lz4 pcre pcre2 snappy openssl
- uses: actions/checkout@v2
- name: fix timestamps
# workaround git not retaining mtimes and bison/flex not being
# uptodate
run: |
touch conffile.yy.c conffile.tab.c conffile.tab.h
touch configure.ac Makefile.am aclocal.m4 configure
touch Makefile.in config.h.in
- name: configure variant ${{ matrix.features }}
run: ./configure --disable-maintainer-mode ${{ matrix.features }}
- name: make variant ${{ matrix.features }}
run: make CFLAGS="-O3 -Wall -Werror -Wshadow -pipe" clean check
coverity:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: fix timestamps
# workaround git not retaining mtimes and bison/flex not being
# uptodate
run: |
touch conffile.yy.c conffile.tab.c conffile.tab.h
touch configure.ac Makefile.am aclocal.m4 configure
touch Makefile.in config.h.in
- name: configure
run: ./configure --disable-maintainer-mode
- uses: vapier/coverity-scan-action@v1
with:
email: ${{ secrets.COVERITY_SCAN_EMAIL }}
token: ${{ secrets.COVERITY_SCAN_TOKEN }}