-
Notifications
You must be signed in to change notification settings - Fork 14
/
.gitlab-ci.yml
61 lines (50 loc) · 1.48 KB
/
.gitlab-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
image: ubuntu:latest
stages:
- test
.setup_linux: &setup_linux |
DEBIAN_FRONTEND=noninteractive
# set time-zone
TZ=Canada/Pacific
ln -snf /usr/share/zoneinfo/$TZ /etc/localtime && echo $TZ > /etc/timezone
# for downloading
apt-get update -qq
apt-get install -y --no-install-recommends curl gnupg ca-certificates
# keys used by apt
apt-key adv --keyserver keyserver.ubuntu.com --recv-keys 3B4FE6ACC0B21F32
apt-key adv --keyserver keyserver.ubuntu.com --recv-keys 40976EAF437D05B5
apt-key adv --keyserver keyserver.ubuntu.com --recv-keys 1E9377A2BA9EF27F
.setup_cpp: &setup_cpp |
curl -LJO "https://github.com/aminya/setup-cpp/releases/download/v0.15.0/setup_cpp_linux"
chmod +x setup_cpp_linux
./setup_cpp_linux --compiler $compiler --cmake true --ninja true --ccache true --clangtidy true --clangformat true --cppcheck true
source ~/.profile
.configure: &configure |
git submodule update --remote --recursive
git submodule foreach git pull origin master
./vcpkg/bootstrap-vcpkg.sh
cmake -S . -B ./build -DCMAKE_BUILD_TYPE:STRING=RelWithDebInfo
.build: &build |
cmake --build ./build --config RelWithDebInfo
.test: &test |
cd ./build
ctest --build-config Debug
test_linux_llvm:
stage: test
variables:
compiler: llvm
script:
- *setup_linux
- *setup_cpp
- *configure
- *build
- *test
test_linux_gcc:
stage: test
variables:
compiler: gcc
script:
- *setup_linux
- *setup_cpp
- *configure
- *build
- *test