summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDaniel Black <daniel.black@au.ibm.com>2017-03-17 12:50:21 +1100
committerSergey Vojtovich <svoj@mariadb.org>2017-04-06 11:26:34 -0400
commiteb04ee5c9d2416aa45acd1353dff19f569e96317 (patch)
tree9eab1723f14447e4d364dcbfa49d3a2c942730ec
parentd235782fca0e3ffd70cf84d466b0c8059ceecdbb (diff)
downloadmariadb-git-eb04ee5c9d2416aa45acd1353dff19f569e96317.tar.gz
Travis: llvm, additional packages and container
Additionally use clang as a compiler, versions 3.8, 3.9 and 4.0 Additionally use gcc/g++-7 Add additional packages used by build now that they are whitelisted. - libsnappy-dev - innodb compression - liblzma-dev - innodb compression - libzmq-dev - used my Mgoonga - libdistro-info-perl - used by autobake-debian Change to a container build as they tend to have more ram Signed-off-by: Daniel Black <daniel.black@au.ibm.com>
-rwxr-xr-x.travis.compiler.sh12
-rw-r--r--.travis.yml35
2 files changed, 35 insertions, 12 deletions
diff --git a/.travis.compiler.sh b/.travis.compiler.sh
new file mode 100755
index 00000000000..155b3af2424
--- /dev/null
+++ b/.travis.compiler.sh
@@ -0,0 +1,12 @@
+#!/bin/sh
+if [[ "${TRAVIS_OS_NAME}" == 'linux' && "${CXX}" == 'clang++' ]]; then
+ case ${GCC_VERSION} in
+ 4.8) MYSQL_BUILD_CXX=clang++-3.8;;
+ 5) MYSQL_BUILD_CXX=clang++-3.9;;
+ 6) MYSQL_BUILD_CXX=clang++-4.0;;
+ esac
+ export MYSQL_BUILD_CXX MYSQL_BUILD_CC=${MYSQL_BUILD_CXX/++/}
+elif [[ "${TRAVIS_OS_NAME}" == 'linux' && "${CXX}" == 'g++' ]]; then
+ export MYSQL_BUILD_CXX=g++-${GCC_VERSION};
+ export MYSQL_BUILD_CC=gcc-${GCC_VERSION}
+fi
diff --git a/.travis.yml b/.travis.yml
index c2fa7283e9a..89c702cc340 100644
--- a/.travis.yml
+++ b/.travis.yml
@@ -1,13 +1,15 @@
# vim ft=yaml
# travis-ci.org definition
-# non-container builds don't have enough RAM to reliably compile
-sudo: required
+sudo: false
dist: trusty
language: cpp
+os:
+ - linux
compiler:
- gcc
+ - clang
cache:
- apt
- ccache
@@ -17,21 +19,25 @@ env:
- GCC_VERSION=4.8
- GCC_VERSION=5
- GCC_VERSION=6
+
addons:
apt:
sources:
- ubuntu-toolchain-r-test
-# below requires https://github.com/travis-ci/apt-source-whitelist/pull/309
-# - llvm-toolchain-trusty-3.8
-# - llvm-toolchain-trusty-3.9
-# llvm urls awaiting fix
-# https://github.com/travis-ci/apt-source-whitelist/pull/288
-# https://github.com/travis-ci/apt-source-whitelist/pull/309
+ - llvm-toolchain-trusty
+ - llvm-toolchain-trusty-3.9
+ - llvm-toolchain-trusty-4.0
packages: # make sure these match debian/control contents
- gcc-5
- g++-5
- gcc-6
- g++-6
+ - clang-3.8
+ - llvm-3.8-dev
+ - clang-3.9
+ - llvm-3.9-dev
+ - clang-4.0
+ - llvm-4.0-dev
- bison
- chrpath
- cmake
@@ -57,18 +63,23 @@ addons:
- zlib1g-dev
- libcrack2-dev
- libjemalloc-dev
+ - libsnappy-dev
+ - liblzma-dev
+ - libzmq-dev
+ - libdistro-info-perl
- devscripts # implicit for any build on Ubuntu
-# libsnappy-dev # https://github.com/travis-ci/apt-package-whitelist/issues/3880
-# liblzma-dev # https://github.com/travis-ci/apt-package-whitelist/issues/3879
-# libzmq-dev # https://github.com/travis-ci/apt-package-whitelist/issues/3881
# libsystemd-daemon-dev # https://github.com/travis-ci/apt-package-whitelist/issues/3882
script:
- - export MYSQL_BUILD_CC=/usr/bin/gcc-${GCC_VERSION} MYSQL_BUILD_CXX=/usr/bin/g++-${GCC_VERSION}
+ - source .travis.compiler.sh
- ${MYSQL_BUILD_CC} --version ; ${MYSQL_BUILD_CXX} --version
- cd "${TRAVIS_BUILD_DIR}"
+# https://github.com/travis-ci/travis-ci/issues/7062 - /run/shm isn't writable or executable
+# in trusty containers
+ - export MTR_MEM=/tmp
- env DEB_BUILD_OPTIONS="parallel=3" debian/autobake-deb.sh;
+ - ccache --show-stats
notifications:
irc: