Skip to content

Commit

Permalink
Fix clang
Browse files Browse the repository at this point in the history
  • Loading branch information
lipnitsk committed Dec 13, 2015
1 parent 917f941 commit b23ced8
Showing 1 changed file with 12 additions and 3 deletions.
15 changes: 12 additions & 3 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,8 @@ dist: trusty
matrix:
include:
# Test default clang
- os: linux
- env: CLANG_VERSION=3.5
os: linux
compiler: clang
addons:
apt:
Expand All @@ -25,12 +26,14 @@ matrix:
- valgrind
- util-linux
- clang-3.8
- libclang-common-3.8-dev
sources:
- ubuntu-toolchain-r-test
- llvm-toolchain-precise

# Test default gcc
- os: linux
- env: GCC_VERSION=4.8
os: linux
compiler: gcc
addons:
apt:
Expand All @@ -57,6 +60,11 @@ env:
before_install:
- if [ -n "$GCC_VERSION" ]; then export CXX="g++-${GCC_VERSION}" CC="gcc-${GCC_VERSION}"; fi
- if [ -n "$CLANG_VERSION" ]; then export CXX="clang++-${CLANG_VERSION}" CC="clang-${CLANG_VERSION}"; fi
- if [ "$CLANG_VERSION" == "3.5" ]; then export CXX="clang++" CC="clang"; fi
- if [ "$GCC_VERSION" == "4.8" ]; then export CXX="g++" CC="gcc"; fi
- which $CXX
- which $CC
- which valgrind

install:
- pip install --user cpp-coveralls
Expand All @@ -67,7 +75,8 @@ install:
script:
- ./autogen.sh
- ./configure && make -j2 distcheck VERBOSE=1 && make clean
- ./configure --enable-valgrind-tests CFLAGS="-fsanitize=undefined -fno-sanitize-recover" CXXFLAGS="-fsanitize=undefined -fno-sanitize-recover" && make -j2 distcheck DISTCHECK_CONFIGURE_FLAGS="--enable-valgrind-tests CFLAGS=\"-fsanitize=undefined -fno-sanitize-recover\" CXXFLAGS=\"-fsanitize=undefined -fno-sanitize-recover\"" VERBOSE=1 && make clean
# TODO: clang 3.8 debian/ubuntu package does not support sanitizers yet
- if [ "$GCC_VERSION" == "5" || "$CLANG_VERSION" == "3.5"]; then ./configure --enable-valgrind-tests CFLAGS="-fsanitize=undefined -fno-sanitize-recover" CXXFLAGS="-fsanitize=undefined -fno-sanitize-recover" && make -j2 distcheck DISTCHECK_CONFIGURE_FLAGS="--enable-valgrind-tests CFLAGS=\"-fsanitize=undefined -fno-sanitize-recover\" CXXFLAGS=\"-fsanitize=undefined -fno-sanitize-recover\"" VERBOSE=1 && make clean; fi
- if [ "$CC" = "gcc" ]; then ./configure --enable-code-coverage && make -j2 && make check; fi

after_success:
Expand Down

0 comments on commit b23ced8

Please sign in to comment.