-
Notifications
You must be signed in to change notification settings - Fork 1
/
.gitlab-ci.yml
78 lines (66 loc) · 1.91 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
before_script:
- sudo apt-get -y install gcc g++ gfortran perl jhead imagemagick liblapacke-dev liblapack-dev libblas-dev
# TODO add ceres solver
stages:
- prepare
- build
- test
- deploy
# download uipf
find-uipf-sfm:
tags:
- nodocker
stage: prepare
script:
# - 'curl -fsSL -H "PRIVATE-TOKEN: ${PRIVATE_TOKEN}" https://gitlab.cebe.cc/global/gitlab-ci-helpers/raw/master/get-last-successful-build-artifact.sh'
# - '. <(curl -fsSL -H "PRIVATE-TOKEN: ${PRIVATE_TOKEN}" https://gitlab.cebe.cc/global/gitlab-ci-helpers/raw/master/get-last-successful-build-artifact.sh)'
# - PROJECT=master/uipf PRIVATE_TOKEN=privtoken STAGE=build-uipf-with-cv download_latest
- rsync -a /tmp/uipf-sfm-prefix/ prefix/
- find prefix/ |sort
artifacts:
paths:
- prefix/
build-uipf-sfm-bundler:
tags:
- nodocker
stage: build
script:
- GIT_SSL_CAINFO=/etc/ssl/certs/ca-certificates.crt git submodule update --init
- if [ -d build/ ]; then rm -rf build/ ; fi
- mkdir build/ && cd build/
- cmake -DCMAKE_INSTALL_PREFIX=`pwd`/../prefix ..
- make -j 4
- make install
dependencies:
- find-uipf-sfm
artifacts:
paths:
- prefix/
variables:
# TODO make this global in salt
# GIT_SUBMODULE_STRATEGY: recursive
# GIT_SSL_CAINFO: /etc/ssl/certs/ca-certificates.crt
test:
tags:
- nodocker
stage: test
script:
# make sure libs can be found
- export LD_LIBRARY_PATH="$LD_LIBRARY_PATH:`pwd`/prefix/lib"
- ./prefix/bin/uipf -l
# TODO grep for expected modules
dependencies:
- build-uipf-sfm-bundler
# TODO test a chain
#deploy:
# stage: deploy
# script:
# # temporary solution for sharing uipf artifacts
# - rm -rf /tmp/uipf-sfm-prefix
# - rsync -a prefix/ /tmp/uipf-sfm-prefix
# - find /tmp/uipf-sfm-prefix |sort
# dependencies:
# - build-uipf-sfm-bundler
variables:
GIT_STRATEGY: clone
# GIT_SUBMODULE_STRATEGY: recursive