mirror of https://github.com/google/snappy.git
Fix Travis CI build.
* Fix bash conditionals: [ a == b ] should be [ a = b ]. * Upgrade to LLVM 9 on Travis. * Upgrade fuzzer build arguments for LLVM 9. PiperOrigin-RevId: 271898655
This commit is contained in:
parent
9dabbca006
commit
e9e11b84e6
19
.travis.yml
19
.travis.yml
|
@ -3,8 +3,8 @@
|
||||||
# This file can be validated on: http://lint.travis-ci.org/
|
# This file can be validated on: http://lint.travis-ci.org/
|
||||||
|
|
||||||
language: cpp
|
language: cpp
|
||||||
dist: xenial
|
dist: bionic
|
||||||
osx_image: xcode10.2
|
osx_image: xcode10.3
|
||||||
|
|
||||||
compiler:
|
compiler:
|
||||||
- gcc
|
- gcc
|
||||||
|
@ -31,10 +31,11 @@ matrix:
|
||||||
addons:
|
addons:
|
||||||
apt:
|
apt:
|
||||||
sources:
|
sources:
|
||||||
- llvm-toolchain-xenial-8
|
- sourceline: 'deb http://apt.llvm.org/bionic/ llvm-toolchain-bionic-9 main'
|
||||||
- ubuntu-toolchain-r-test
|
key_url: 'https://apt.llvm.org/llvm-snapshot.gpg.key'
|
||||||
|
- sourceline: 'ppa:ubuntu-toolchain-r/test'
|
||||||
packages:
|
packages:
|
||||||
- clang-8
|
- clang-9
|
||||||
- cmake
|
- cmake
|
||||||
- gcc-9
|
- gcc-9
|
||||||
- g++-9
|
- g++-9
|
||||||
|
@ -43,14 +44,14 @@ addons:
|
||||||
packages:
|
packages:
|
||||||
- cmake
|
- cmake
|
||||||
- gcc@9
|
- gcc@9
|
||||||
- llvm@8
|
- llvm@9
|
||||||
- ninja
|
- ninja
|
||||||
update: true
|
update: true
|
||||||
|
|
||||||
install:
|
install:
|
||||||
# The following Homebrew packages aren't linked by default, and need to be
|
# The following Homebrew packages aren't linked by default, and need to be
|
||||||
# prepended to the path explicitly.
|
# prepended to the path explicitly.
|
||||||
- if [ "$TRAVIS_OS_NAME" == "osx" ]; then
|
- if [ "$TRAVIS_OS_NAME" = "osx" ]; then
|
||||||
export PATH="$(brew --prefix llvm)/bin:$PATH";
|
export PATH="$(brew --prefix llvm)/bin:$PATH";
|
||||||
fi
|
fi
|
||||||
# Fuzzing is only supported on Clang. Perform fuzzing on Debug builds.
|
# Fuzzing is only supported on Clang. Perform fuzzing on Debug builds.
|
||||||
|
@ -66,8 +67,8 @@ install:
|
||||||
# Homebrew's llvm package doesn't ship a versioned clang++ binary, so the values
|
# Homebrew's llvm package doesn't ship a versioned clang++ binary, so the values
|
||||||
# below don't work on macOS. Fortunately, the path change above makes the
|
# below don't work on macOS. Fortunately, the path change above makes the
|
||||||
# default values (clang and clang++) resolve to the correct compiler on macOS.
|
# default values (clang and clang++) resolve to the correct compiler on macOS.
|
||||||
- if [ "$TRAVIS_OS_NAME" == "linux" ]; then
|
- if [ "$TRAVIS_OS_NAME" = "linux" ]; then
|
||||||
if [ "$CXX" = "clang++" ]; then export CXX="clang++-8" CC="clang-8"; fi;
|
if [ "$CXX" = "clang++" ]; then export CXX="clang++-9" CC="clang-9"; fi;
|
||||||
fi
|
fi
|
||||||
- echo ${CC}
|
- echo ${CC}
|
||||||
- echo ${CXX}
|
- echo ${CXX}
|
||||||
|
|
|
@ -124,9 +124,9 @@ if (SNAPPY_FUZZING_BUILD)
|
||||||
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -fsanitize=address")
|
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -fsanitize=address")
|
||||||
endif(NOT CMAKE_CXX_FLAGS MATCHES "-fsanitize=address")
|
endif(NOT CMAKE_CXX_FLAGS MATCHES "-fsanitize=address")
|
||||||
|
|
||||||
if(NOT CMAKE_CXX_FLAGS MATCHES "-fsanitize-coverage=trace-pc-guard")
|
if(NOT CMAKE_CXX_FLAGS MATCHES "-fsanitize=fuzzer-no-link")
|
||||||
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -fsanitize-coverage=trace-pc-guard")
|
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -fsanitize=fuzzer-no-link")
|
||||||
endif(NOT CMAKE_CXX_FLAGS MATCHES "-fsanitize-coverage=trace-pc-guard")
|
endif(NOT CMAKE_CXX_FLAGS MATCHES "-fsanitize=fuzzer-no-link")
|
||||||
endif (SNAPPY_FUZZING_BUILD)
|
endif (SNAPPY_FUZZING_BUILD)
|
||||||
|
|
||||||
configure_file(
|
configure_file(
|
||||||
|
|
Loading…
Reference in New Issue