forked from paperManu/splash
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.gitlab-ci.yml
89 lines (80 loc) · 2.21 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
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
image: ubuntu:16.04
variables:
DOCKER_DRIVER: overlay
stages:
- test
- package
before_script:
- apt update -qq
- apt install -y curl wget build-essential git-core zip cmake automake libtool libxcb-shm0-dev libxrandr-dev libxi-dev libgsl0-dev libatlas3-base libgphoto2-dev libxinerama-dev libxcursor-dev python3-dev portaudio19-dev yasm libgl1-mesa-dev python
- git submodule update --init
- ./make_deps.sh
- rm -rf build && mkdir build && cd build
- cmake -DCMAKE_INSTALL_PREFIX=/usr ..
#
# Tests
#
test:16.04:
stage: test
image: ubuntu:16.04
script:
- make -j$(nproc)
- make test
test:18.04:
stage: test
image: ubuntu:18.04
script:
- make -j$(nproc)
- make test
test:archlinux:
stage: test
image: base/archlinux
only:
- archlinux
before_script:
- pacman -Syyu --noconfirm
- pacman -Sy --noconfirm git cmake make gcc yasm pkgconfig libxi libxinerama libxrandr libxcursor mesa glm gsl libgphoto2 python3 portaudio zip zlib
- git submodule update --init
- ./make_deps.sh
- rm -rf build && mkdir build && cd build
- cmake -DCMAKE_INSTALL_PREFIX=/usr ..
script:
- make -j$(nproc)
- make test
#
# Package
#
package:
stage: package
script:
- make -j$(nproc)
- make package
- mv *.deb ../
- mv addons/blender/*.tar.bz2 ../
only:
- tags
artifacts:
name: "splash_${CI_BUILD_REF_NAME}"
paths:
- "*.deb"
- "*.tar.bz2"
#
# Static analysis
#
static_analysis:
stage: test
script:
- wget https://scan.coverity.com/download/linux64 --post-data "token=zkRfEWYxyAeJDlYYg9Hkkg&project=paperManu%2Fsplash" -O coverity_tool.tgz
- tar xvzf coverity_tool.tgz
- $(ls | grep cov-analysis)/bin/cov-build --dir cov-int make -j$(nproc)
- tar caf splash-cov.bz2 cov-int
- curl --form token=zkRfEWYxyAeJDlYYg9Hkkg --form email=emmanueldurand@gmail.com --form file=@splash-cov.bz2 --form description="Splash" https://scan.coverity.com/builds?project=paperManu%2Fsplash
- apt install -y libpcre3-dev
- make static_analysis
- mv tests/static_analysis_result.txt ../
only:
- static_analysis
artifacts:
name: "splash_static_analysis_${CI_BUILD_REF_NAME}"
paths:
- "static_analysis_result.txt"