1- language : cpp
2- sudo : false
3- addons :
4- apt :
5- sources :
6- - boost-latest
7- - ubuntu-toolchain-r-test
8- packages :
9- - g++-4.8
10- - libexpat1-dev
11- - libpq-dev
12- - libbz2-dev
13- - libproj-dev
14- - lua5.2
15- - liblua5.2-dev
16- - libluajit-5.1-dev
17- - libboost1.55-dev
18- - libboost-system1.55-dev
19- - libboost-filesystem1.55-dev
1+ language : generic
2+ sudo : required
3+
4+ git :
5+ depth : 1
6+
7+ services :
8+ - postgresql
9+
10+ addons_shortcuts :
11+
12+ addons_clang38_pg92 : &clang38_pg92
13+ postgresql : ' 9.2'
14+ apt :
15+ sources : ['ubuntu-toolchain-r-test', 'llvm-toolchain-trusty-3.8']
16+ packages : ['clang-3.8', 'postgresql-9.2-postgis-2.3',
17+ ' python-psycopg2' , 'libexpat1-dev', 'libpq-dev', 'libbz2-dev', 'libproj-dev',
18+ ' lua5.2' , 'liblua5.2-dev', 'libluajit-5.1-dev',
19+ ' libboost1.55-dev' , 'libboost-system1.55-dev', 'libboost-filesystem1.55-dev']
20+
21+ addons_clang7_pg96 : &clang7_pg96
22+ postgresql : ' 9.6'
23+ apt :
24+ update : true
25+ sources :
26+ - sourceline : ' deb http://apt.llvm.org/trusty/ llvm-toolchain-trusty-7 main'
27+ key_url : https://apt.llvm.org/llvm-snapshot.gpg.key
28+ - ubuntu-toolchain-r-test
29+ packages : ['clang-7','postgresql-9.6-postgis-2.3',
30+ ' python-psycopg2' , 'libexpat1-dev', 'libpq-dev', 'libbz2-dev', 'libproj-dev',
31+ ' lua5.2' , 'liblua5.2-dev', 'libluajit-5.1-dev',
32+ ' libboost1.55-dev' , 'libboost-system1.55-dev', 'libboost-filesystem1.55-dev']
33+
34+ addons_gcc48_pg96 : &gcc48_pg96
35+ postgresql : ' 9.6'
36+ apt :
37+ sources : ["ubuntu-toolchain-r-test"]
38+ packages : ['g++-4.8','postgresql-9.6-postgis-2.3',
39+ ' python-psycopg2' , 'libexpat1-dev', 'libpq-dev', 'libbz2-dev', 'libproj-dev',
40+ ' lua5.2' , 'liblua5.2-dev', 'libluajit-5.1-dev',
41+ ' libboost1.55-dev' , 'libboost-system1.55-dev', 'libboost-filesystem1.55-dev']
42+
43+
44+ addons_gcc8_pg96 : &gcc8_pg96
45+ postgresql : ' 9.6'
46+ apt :
47+ sources : ["ubuntu-toolchain-r-test"]
48+ packages : ['g++-8','postgresql-9.6-postgis-2.3',
49+ ' python-psycopg2' , 'libexpat1-dev', 'libpq-dev', 'libbz2-dev', 'libproj-dev',
50+ ' lua5.2' , 'liblua5.2-dev', 'libluajit-5.1-dev',
51+ ' libboost1.55-dev' , 'libboost-system1.55-dev', 'libboost-filesystem1.55-dev']
52+
53+ # env: T="...." // please set an unique test id (T="..")
2054matrix :
2155 include :
56+ # ---- Linux + CLANG ---------------------------
2257 - os : linux
23- compiler : clang
24- env : CXXFLAGS="-pedantic -Werror" LUAJIT_OPTION="OFF"
25- - os : linux
26- compiler : gcc
27- env : RUNTEST="-L NoDB" CXXFLAGS="-pedantic -Werror -fsanitize=address" LUAJIT_OPTION="OFF"
28- - os : linux
29- compiler : clang
30- env : CXXFLAGS="-pedantic -Werror" LUAJIT_OPTION="ON"
58+ compiler : " clang-3.8"
59+ env : T="clang38_pg92_dbtest" RUNTEST="#Dbtest" LUAJIT_OPTION="OFF"
60+ CXXFLAGS="-pedantic -Werror"
61+ CC=clang-3.8 CXX=clang++-3.8
62+ addons : *clang38_pg92
63+
3164 - os : linux
32- compiler : gcc
33- env : RUNTEST="-L NoDB" CXXFLAGS="-pedantic -Werror -fsanitize=address" LUAJIT_OPTION="ON"
65+ compiler : " clang-7"
66+ env : T="clang7_pg96_dbtest_luajit" RUNTEST="#Dbtest" LUAJIT_OPTION="ON"
67+ CXXFLAGS="-pedantic -Werror"
68+ CC=clang-7 CXX=clang++-7
69+ addons : *clang7_pg96
70+
71+ # ---- OSX + CLANG ---------------------------
3472 - os : osx
3573 compiler : clang
36- env : RUNTEST="-L NoDB" CXXFLAGS="-pedantic -Werror -fsanitize=address" LUAJIT_OPTION="OFF"
74+ env : T="osx_clang_NoDB" RUNTEST="-L NoDB" LUAJIT_OPTION="OFF"
75+ CXXFLAGS="-pedantic -Werror"
76+ before_install :
77+ - brew install lua;
78+ before_script :
79+ - xml2-config --version
80+ - proj | head -n1
81+ - lua -v
82+
83+ # ---- Linux + GCC ---------------------------
84+ - os : linux
85+ compiler : " gcc-4.8"
86+ env : T="gcc48_pg96_dbtest" RUNTEST="#Dbtest" LUAJIT_OPTION="OFF"
87+ CXXFLAGS="-pedantic -Werror"
88+ CC=gcc-4.8 CXX=g++-4.8
89+ addons : *gcc48_pg96
90+
91+ - os : linux
92+ compiler : gcc-8
93+ env : T="gcc8_pg96_dbtest_luajit" RUNTEST="#Dbtest" LUAJIT_OPTION="ON"
94+ CXXFLAGS="-pedantic -Werror"
95+ CC=gcc-8 CXX=g++-8
96+ addons : *gcc8_pg96
97+
98+
3799before_install :
38- - if [[ $TRAVIS_OS_NAME == 'osx' ]]; then
39- brew install lua;
40- fi
41- # update versions
42- install :
43- - if [[ $CC == 'gcc' ]]; then
44- export CC=gcc-4.8;
45- fi
46- - if [[ $CXX == 'g++' ]]; then
47- export CXX=g++-4.8;
48- fi
100+ - sudo mkdir -p /extra/pg/tablespacetest # for the database test
101+ - sudo chown postgres:postgres /extra/pg/tablespacetest
102+ - dpkg -l | grep -E 'lua|proj|xml|bz2|postgis|zlib|boost|expat' # checking available versions
49103before_script :
104+ - psql -U postgres -c "SELECT version()"
105+ - psql -U postgres -c "CREATE TABLESPACE tablespacetest LOCATION '/extra/pg/tablespacetest'"
106+ - psql -U postgres -c "CREATE EXTENSION postgis"
107+ - psql -U postgres -c "CREATE EXTENSION hstore"
108+ - psql -U postgres -c "SELECT PostGIS_Full_Version()"
50109 - $CXX --version
51110 - xml2-config --version
52111 - proj | head -n1
@@ -55,8 +114,10 @@ script:
55114 - mkdir build && cd build
56115 - cmake .. -DBUILD_TESTS=ON -DCMAKE_BUILD_TYPE=Debug -DWITH_LUAJIT=$LUAJIT_OPTION
57116 - make -j2
58- - echo "Running tests that does not require PostgreSQL server "
117+ - echo "Running tests ... "
59118 - if [[ $RUNTEST ]]; then ctest -VV $RUNTEST; fi
60119after_failure :
61120 - # rerun make, but verbosely
62121 make VERBOSE=1
122+
123+ # end of .travis
0 commit comments