-
Notifications
You must be signed in to change notification settings - Fork 5
73 lines (71 loc) · 2.07 KB
/
ci-linux.yml
File metadata and controls
73 lines (71 loc) · 2.07 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
72
73
name: ci-linux
on:
push:
paths:
- "**"
- "!COPYING"
- "!COPYING-asm"
- "!INSTALL"
- "!**.md"
- "!.clang*"
- "!.gitignore"
- "!.gitattributes"
- "!.github/workflows/*"
- ".github/workflows/ci-linux.yml"
pull_request:
paths:
- "**"
- "!COPYING"
- "!COPYING-asm"
- "!INSTALL"
- "!**.md"
- "!.clang*"
- "!.gitignore"
- "!.gitattributes"
- "!.github/workflows/*"
- ".github/workflows/ci-linux.yml"
jobs:
ci-linux:
runs-on: ubuntu-latest
strategy:
matrix:
compiler: [gcc, clang]
generator: [make, ninja]
include:
- compiler: gcc
cc: gcc
cxx: g++
- compiler: clang
cc: clang
cxx: clang++
- generator: make
cmake_generator: "Unix Makefiles"
- generator: ninja
cmake_generator: "Ninja"
steps:
- name: Install dependencies
run: |
if ! apt-fast -- help &> /dev/null; then
sudo add-apt-repository -u -y ppa:apt-fast/stable
sudo apt-get update
echo debconf apt-fast/maxdownloads string 16 | sudo debconf-set-selections
echo debconf apt-fast/dlflag boolean true | sudo debconf-set-selections
echo debconf apt-fast/aptmanager string apt-get | sudo debconf-set-selections
DEBIAN_FRONTEND=noninteractive sudo apt install -y apt-fast
else
sudo apt-fast update
fi
sudo apt-fast install -y libboost-all-dev ninja-build
- name: Checkout code
uses: actions/checkout@master
- name: Configure
env:
OVERRIDE_CC: ${{ matrix.cc }}
OVERRIDE_CXX: ${{ matrix.cxx }}
run: |
export CC=$(which $OVERRIDE_CC)
export CXX=$(which $OVERRIDE_CXX)
cmake -S . -B build -G "${{ matrix.cmake_generator }}"
- name: Build
run: |
cmake --build build -j2