travis: install clang from apt

(cherry picked from commit f432f5f1cc)
This commit is contained in:
Mickey Rose 2018-08-25 22:56:31 +02:00
parent 19ad1f1156
commit fe96110e1d
2 changed files with 21 additions and 17 deletions

View file

@ -31,20 +31,32 @@ matrix:
packages: [ 'libstdc++-6-dev', 'g++-6', 'xutils-dev', 'postgresql-9.4-postgis-2.3' ]
- os: linux
name: Linux clang-3.9
env: JOBS=8 CXX="ccache clang++-3.9 -Qunused-arguments" CC="clang-3.9" ENABLE_GLIBC_WORKAROUND=true TRIGGER=true
env: >-
JOBS=8
CXX="ccache clang++-3.9 -Qunused-arguments"
CC="clang-3.9"
LINKFLAGS="-fuse-ld=gold-2.26"
ENABLE_GLIBC_WORKAROUND=true
TRIGGER=true
addons:
postgresql: "9.4"
apt:
sources: [ 'ubuntu-toolchain-r-test' ]
packages: [ 'libstdc++-4.9-dev', 'xutils-dev', 'postgresql-9.4-postgis-2.3' ]
packages: [ 'clang-3.9', 'libstdc++-4.9-dev', 'xutils-dev', 'postgresql-9.4-postgis-2.3' ]
- os: linux
name: Linux clang-3.9 + coverage
env: JOBS=8 COVERAGE=true CXX="ccache clang++-3.9 -Qunused-arguments" CC="clang-3.9"
env: >-
JOBS=8
COVERAGE=true
LLVM_COV="llvm-cov-3.9"
CXX="ccache clang++-3.9 -Qunused-arguments"
CC="clang-3.9"
LINKFLAGS="-fuse-ld=gold-2.26"
addons:
postgresql: "9.4"
apt:
sources: [ 'ubuntu-toolchain-r-test' ]
packages: ['libstdc++-4.9-dev', 'xutils-dev', 'postgresql-9.4-postgis-2.3' ]
packages: [ 'clang-3.9', 'llvm-3.9', 'libstdc++-4.9-dev', 'xutils-dev', 'postgresql-9.4-postgis-2.3' ]
- os: osx
name: OSX clang
# https://docs.travis-ci.com/user/languages/objective-c/#Supported-OS-X-iOS-SDK-versions
@ -75,15 +87,6 @@ install:
before_script:
- source bootstrap.sh
- |
if [[ $(uname -s) == 'Linux' ]]; then
mason install clang++ 3.9.1
export PATH=$(mason prefix clang++ 3.9.1)/bin:${PATH}
mason install llvm-cov 3.9.1
export PATH=$(mason prefix llvm-cov 3.9.1)/bin:${PATH}
which llvm-cov
export LLVM_COV="$(mason prefix llvm-cov 3.9.1)/bin/llvm-cov"
fi
- ccache --version
- ccache -p || true
- ccache --show-stats || true

View file

@ -77,10 +77,11 @@ config_override () {
configure () {
if enabled ${COVERAGE}; then
./configure "$@" PREFIX=${PREFIX} PGSQL2SQLITE=False SVG2PNG=False SVG_RENDERER=False \
COVERAGE=True DEBUG=True
./configure "PREFIX=$PREFIX" "CUSTOM_LDFLAGS=$LINKFLAGS" "$@" \
COVERAGE=True DEBUG=True \
PGSQL2SQLITE=False SVG2PNG=False SVG_RENDERER=False
else
./configure "$@" PREFIX=${PREFIX}
./configure "PREFIX=$PREFIX" "CUSTOM_LDFLAGS=$LINKFLAGS" "$@"
fi
# print final config values, sorted and indented
sort -sk1,1 ./config.py | sed -e 's/^/ /'
@ -97,7 +98,7 @@ coverage () {
-g "./.sconf_temp/**" \
-g "./scons/**" \
-g "./test/**" \
-x "llvm-cov gcov >/dev/null 2>&1"
-x "${LLVM_COV:-llvm-cov} gcov >/dev/null 2>&1"
}
trigger_downstream() {