forked from wallix/redemption
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.travis.yml.old
54 lines (48 loc) · 1.57 KB
/
.travis.yml.old
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
language: cpp
os: linux
sudo: required
services:
- docker
if: tag IS blank
matrix:
include:
# Clang 7
- compiler: clang
env: DIST=ubuntu:18.04 INSTALL='clang-7 libc++-7-dev libc++abi-7-dev' BJAM_COMPILER=clang
# GCC 7
- compiler: gcc
env: DIST=ubuntu:18.04 INSTALL=g++ BJAM_COMPILER=gcc
before_install:
- |
PATTERN="s/g++/$INSTALL/;s/gcc/$BJAM_COMPILER/g"
echo "$PATTERN"
sed "$PATTERN" Dockerfile > $BJAM_COMPILER.dockerfile
if [ "$BJAM_COMPILER" = clang ]; then
wget -O llvm-snapshot.gpg.key https://apt.llvm.org/llvm-snapshot.gpg.key
sed -i \
-e '4iRUN apt-get -qq update\nRUN apt-get install -y gnupg\nCOPY llvm-snapshot.gpg.key .\nRUN apt-key add llvm-snapshot.gpg.key' \
-e '/mkdir/iRUN sed -i -e "s/__GLIBC__) || defined(//" /usr/include/c++/v1/__locale' \
-e 's/^# clang: //' \
$BJAM_COMPILER.dockerfile
echo -e 'using clang : : clang++-7 : <cxxflags>-fdiagnostics-color=always <cxxflags>-stdlib=libc++ <cxxflags>-Wunused-command-line-argument <linkflags>-stdlib=libc++ ;' > project-config.jam
else
echo -e 'using gcc : : g++-7 : <cxxflags>-fdiagnostics-color=always ;' > project-config.jam
fi
- cat $BJAM_COMPILER.dockerfile
- cat project-config.jam
- docker pull $DIST
script:
- docker build -f $BJAM_COMPILER.dockerfile .
# branches:
# except:
# - /^[0-9]/
notifications:
email:
recipients:
on_success: change
on_failure: always