-
-
Notifications
You must be signed in to change notification settings - Fork 90
/
.travis.yml
90 lines (79 loc) · 3.47 KB
/
.travis.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
89
90
sudo: required
dist: bionic
language: cpp
services:
- postgresql
matrix:
include:
- os: osx
osx_image: xcode12u
compiler: clang
env:
- PLATFORM=APPLE
- COMPILER=clang++
- CMAKE_ARGS="-DCMAKE_PREFIX_PATH='/usr/local/opt/openssl;/usr/local/opt/curl;/usr/local/opt/postgresql'"
addons:
homebrew:
packages:
- boost
- sqlite
- mariadb
- cmake
- postgresql
- curl
- openssl
- compiler: g++
env:
- LOCAL_CC=gcc-9
- LOCAL_CXX=g++-9
- JOBNAME=gcc
before_install:
- wget -O - https://apt.kitware.com/keys/kitware-archive-latest.asc 2>/dev/null | sudo apt-key add -
- sudo apt-add-repository -y 'deb https://apt.kitware.com/ubuntu/ bionic main'
- sudo add-apt-repository -y ppa:ubuntu-toolchain-r/test;
- sudo apt-get install -qq gcc-9 g++-9;
- sudo apt-get install -qq libboost-all-dev libpq-dev postgresql-server-dev-all libssl-dev lcov libsqlite3-dev cmake libcurl4-openssl-dev
- sudo apt-get install software-properties-common
- sudo apt-key adv --recv-keys --keyserver hkp://keyserver.ubuntu.com:80 0xF1656F24C74CD1D8
- sudo add-apt-repository 'deb [arch=amd64,arm64,ppc64el] http://mirror.netcologne.de/mariadb/repo/10.4/ubuntu bionic main'
- sudo apt-get update -qq;
- sudo apt-get remove libmysqlclient-dev mysql-server;
- sudo apt-get install -qq libmariadb-dev mariadb-server;
- compiler: clang++
env:
- LOCAL_CC=clang-9
- LOCAL_CXX=clang++-9
- JOBNAME=clang
- CXXFLAGS=--stdlib=libc++
before_install:
- wget -O - https://apt.kitware.com/keys/kitware-archive-latest.asc 2>/dev/null | sudo apt-key add -
- sudo apt-add-repository -y 'deb https://apt.kitware.com/ubuntu/ bionic main'
- wget -O - https://apt.llvm.org/llvm-snapshot.gpg.key|sudo apt-key add -;
- sudo echo deb http://apt.llvm.org/bionic/ llvm-toolchain-bionic-9 main >> /etc/apt/sources.list;
- sudo apt-get update -qq;
- sudo apt-get install -qq clang-9 libc++-9-dev libpq-dev postgresql-server-dev-all libc++abi-9-dev libclang-9-dev;
- sudo apt-get install -qq libboost-all-dev libssl-dev lcov libsqlite3-dev cmake libcurl4-openssl-dev
- sudo apt-get install software-properties-common
- sudo apt-key adv --recv-keys --keyserver hkp://keyserver.ubuntu.com:80 0xF1656F24C74CD1D8
- sudo add-apt-repository 'deb [arch=amd64,arm64,ppc64el] http://mirror.netcologne.de/mariadb/repo/10.4/ubuntu bionic main'
- sudo apt-get update -qq;
- sudo apt-get remove libmysqlclient-dev mysql-server;
- sudo apt-get install -qq libmariadb-dev mariadb-server;
before_script:
- if [ "$PLATFORM" == "APPLE" ]; then
rm -rf /usr/local/var/postgres;
initdb /usr/local/var/postgres;
pg_ctl -D /usr/local/var/postgres -o "-p 32768" start;
psql -p 32768 -c "CREATE ROLE postgres LOGIN ENCRYPTED PASSWORD 'lithium_test';" postgres;
fi
- cd $HOME/build/$TRAVIS_REPO_SLUG
- mkdir -p build
- cd build
- cmake .. -DCMAKE_BUILD_TYPE=Debug -DCMAKE_CXX_COMPILER=${LOCAL_CXX} -DCMAKE_INSTALL_PREFIX=$HOME/local $CMAKE_ARGS
script:
- bash ../libraries/sql/tests/sql_test_servers.sh start
- cd $HOME/build/$TRAVIS_REPO_SLUG/build
- make all
- ctest --verbose
after_script:
echo after_script