1
0
mirror of https://github.com/codership/wsrep-lib.git synced 2025-07-28 20:02:00 +03:00
Files
wsrep-lib/.travis.yml
Teemu Ollakka 9b25cebdf1 codership/wsrep-lib#117 Fixed empty vector access.
Access to empty vector by using operator[] may cause stdlib++
assertions to fail. Replaced the vector data access to use data()
method which is valid operation even if the vector is empty.

Added unit test to reproduce assertion with empty mutable_buffer access.

Added -D_GLIBCXX_ASSERTIONS preprocessor option to debug builds
to catch standard library misuse.

Added gcc 8 and gcc9 into travis build matrix.
2019-12-05 14:27:35 +02:00

347 lines
11 KiB
YAML

language: cpp
matrix:
include:
- os: linux
dist: trusty
name: "GCC 4.4 Debug"
addons:
apt:
packages:
- cmake
- gcc-4.4
- g++-4.4
env: MATRIX_EVAL="CC=gcc-4.4 CXX=g++-4.4 TYPE=Debug STRICT=OFF UNIT_TESTS=OFF ASAN=OFF DBSIM=OFF"
- os: linux
dist: trusty
name: "GCC 4.4 RelWithDebInfo"
addons:
apt:
packages:
- cmake
- gcc-4.4
- g++-4.4
env: MATRIX_EVAL="CC=gcc-4.4 CXX=g++-4.4 TYPE=RelWithDebInfo STRICT=OFF UNIT_TESTS=OFF ASAN=OFF DBSIM=OFF"
- os: linux
dist: trusty
name: "GCC 4.7 Debug"
addons:
apt:
packages:
- cmake
- libboost-test-dev
- gcc-4.7
- g++-4.7
env: MATRIX_EVAL="CC=gcc-4.7 CXX=g++-4.7 TYPE=Debug STRICT=OFF UNIT_TESTS=ON DBSIM=OFF"
- os: linux
dist: trusty
name: "GCC 4.7 RelWithDebInfo"
addons:
apt:
packages:
- cmake
- libboost-test-dev
- gcc-4.7
- g++-4.7
env: MATRIX_EVAL="CC=gcc-4.7 CXX=g++-4.7 TYPE=RelWithDebInfo STRICT=OFF UNIT_TESTS=ON DBSIM=OFF"
- os: linux
dist: trusty
name: "GCC 4.8 Debug"
addons:
apt:
packages:
- cmake
- libboost-test-dev
env: MATRIX_EVAL="TYPE=Debug STRICT=OFF UNIT_TESTS=ON ASAN=ON DBSIM=OFF"
- os: linux
dist: trusty
name: "GCC 4.8 RelWithDebInfo"
addons:
apt:
packages:
- cmake
- libboost-test-dev
env: MATRIX_EVAL="TYPE=RelWithDebInfo STRICT=OFF UNIT_TESTS=ON ASAN=ON DBSIM=OFF"
- os: linux
name: "GCC 5 Debug"
addons:
apt:
sources:
- ubuntu-toolchain-r-test
packages:
- g++-5
- cmake
- libboost-test-dev
- libboost-program-options-dev
- libboost-filesystem-dev
- libboost-thread-dev
env: MATRIX_EVAL="CC=gcc-5 CXX=g++-5 TYPE=Debug STRICT=ON UNIT_TESTS=ON ASAN=OFF DBSIM=ON"
- os: linux
name: "GCC 5 RelWithDebInfo"
addons:
apt:
sources:
- ubuntu-toolchain-r-test
packages:
- g++-5
- cmake
- libboost-test-dev
- libboost-program-options-dev
- libboost-filesystem-dev
- libboost-thread-dev
env: MATRIX_EVAL="CC=gcc-5 CXX=g++-5 TYPE=RelWithDebInfo STRICT=ON UNIT_TESTS=ON ASAN=OFF DBSIM=ON"
- os: linux
name: "GCC 6 Debug"
addons:
apt:
sources:
- ubuntu-toolchain-r-test
packages:
- g++-6
- cmake
- libboost-test-dev
- libboost-program-options-dev
- libboost-filesystem-dev
- libboost-thread-dev
env: MATRIX_EVAL="CC=gcc-6 CXX=g++-6 TYPE=Debug STRICT=ON UNIT_TESTS=ON ASAN=OFF DBSIM=ON"
- os: linux
name: "GCC 6 RelWithDebInfo"
addons:
apt:
sources:
- ubuntu-toolchain-r-test
packages:
- g++-6
- cmake
- libboost-test-dev
- libboost-program-options-dev
- libboost-filesystem-dev
- libboost-thread-dev
env: MATRIX_EVAL="CC=gcc-6 CXX=g++-6 TYPE=RelWithDebInfo STRICT=ON UNIT_TESTS=ON ASAN=OFF DBSIM=ON"
- os: linux
name: "GCC 7 Debug"
addons:
apt:
sources:
- ubuntu-toolchain-r-test
packages:
- g++-7
- cmake
- libboost-test-dev
- libboost-program-options-dev
- libboost-filesystem-dev
- libboost-thread-dev
env: MATRIX_EVAL="CC=gcc-7 CXX=g++-7 TYPE=Debug STRICT=ON UNIT_TESTS=ON ASAN=OFF DBSIM=ON"
- os: linux
name: "GCC 7 RelWithDebInfo"
addons:
apt:
sources:
- ubuntu-toolchain-r-test
packages:
- g++-7
- cmake
- libboost-test-dev
- libboost-program-options-dev
- libboost-filesystem-dev
- libboost-thread-dev
env: MATRIX_EVAL="CC=gcc-7 CXX=g++-7 TYPE=RelWithDebInfo STRICT=ON UNIT_TESTS=ON ASAN=OFF DBSIM=ON"
- os: linux
name: "GCC 8 Debug"
addons:
apt:
sources:
- ubuntu-toolchain-r-test
packages:
- g++-8
- cmake
- libboost-test-dev
- libboost-program-options-dev
- libboost-filesystem-dev
- libboost-thread-dev
env: MATRIX_EVAL="CC=gcc-8 CXX=g++-8 TYPE=Debug STRICT=ON UNIT_TESTS=ON ASAN=OFF DBSIM=ON"
- os: linux
name: "GCC 8 RelWithDebInfo"
addons:
apt:
sources:
- ubuntu-toolchain-r-test
packages:
- g++-8
- cmake
- libboost-test-dev
- libboost-program-options-dev
- libboost-filesystem-dev
- libboost-thread-dev
env: MATRIX_EVAL="CC=gcc-8 CXX=g++-8 TYPE=RelWithDebInfo STRICT=ON UNIT_TESTS=ON ASAN=OFF DBSIM=ON"
- os: linux
name: "GCC 9 Debug"
addons:
apt:
sources:
- ubuntu-toolchain-r-test
packages:
- g++-9
- cmake
- libboost-test-dev
- libboost-program-options-dev
- libboost-filesystem-dev
- libboost-thread-dev
env: MATRIX_EVAL="CC=gcc-9 CXX=g++-9 TYPE=Debug STRICT=ON UNIT_TESTS=ON ASAN=OFF DBSIM=ON"
- os: linux
name: "GCC 9 RelWithDebInfo"
addons:
apt:
sources:
- ubuntu-toolchain-r-test
packages:
- g++-9
- cmake
- libboost-test-dev
- libboost-program-options-dev
- libboost-filesystem-dev
- libboost-thread-dev
env: MATRIX_EVAL="CC=gcc-9 CXX=g++-9 TYPE=RelWithDebInfo STRICT=ON UNIT_TESTS=ON ASAN=OFF DBSIM=ON"
- os: linux
dist: trusty
name: "Clang 3.6 Debug"
addons:
apt:
sources:
- ubuntu-toolchain-r-test
- llvm-toolchain-precise-3.6
packages:
- clang-3.6
- cmake
- libboost-test-dev
- libboost-program-options-dev
- libboost-filesystem-dev
- libboost-thread-dev
env: MATRIX_EVAL="CC=clang-3.6 CXX=clang++-3.6 TYPE=Debug STRICT=ON UNIT_TESTS=ON ASAN=OFF DBSIM=ON"
- os: linux
dist: trusty
name: "Clang 3.6 RelWithDebInfo"
addons:
apt:
sources:
- ubuntu-toolchain-r-test
- llvm-toolchain-precise-3.6
packages:
- clang-3.6
- cmake
- libboost-test-dev
- libboost-program-options-dev
- libboost-filesystem-dev
- libboost-thread-dev
env: MATRIX_EVAL="CC=clang-3.6 CXX=clang++-3.6 TYPE=RelWithDebInfo STRICT=ON UNIT_TESTS=ON ASAN=OFF DBSIM=ON"
- os: linux
name: "Clang 4.0 Debug"
addons:
apt:
sources:
- ubuntu-toolchain-r-test
packages:
- clang-4.0
- cmake
- libboost-test-dev
- libboost-program-options-dev
- libboost-filesystem-dev
- libboost-thread-dev
env: MATRIX_EVAL="CC=clang-4.0 CXX=clang++-4.0 TYPE=Debug STRICT=ON UNIT_TESTS=ON ASAN=OFF DBSIM=OFF"
- os: linux
name: "Clang 4.0 RelWithDebInfo"
addons:
apt:
sources:
- ubuntu-toolchain-r-test
packages:
- clang-4.0
- cmake
- libboost-test-dev
- libboost-program-options-dev
- libboost-filesystem-dev
- libboost-thread-dev
env: MATRIX_EVAL="CC=clang-4.0 CXX=clang++-4.0 TYPE=RelWithDebInfo STRICT=ON UNIT_TESTS=ON ASAN=OFF DBSIM=OFF"
- os: linux
name: "Clang 5.0 Debug"
addons:
apt:
sources:
- ubuntu-toolchain-r-test
packages:
- clang-5.0
- cmake
- libboost-test-dev
- libboost-program-options-dev
- libboost-filesystem-dev
- libboost-thread-dev
env: MATRIX_EVAL="CC=clang-5.0 CXX=clang++-5.0 TYPE=Debug STRICT=ON UNIT_TESTS=ON ASAN=OFF DBSIM=OFF"
- os: linux
name: "Clang 5.0 RelWithDebInfo"
addons:
apt:
sources:
- ubuntu-toolchain-r-test
packages:
- clang-5.0
- cmake
- libboost-test-dev
- libboost-program-options-dev
- libboost-filesystem-dev
- libboost-thread-dev
env: MATRIX_EVAL="CC=clang-5.0 CXX=clang++-5.0 TYPE=RelWithDebInfo STRICT=ON ASAN=OFF DBSIM=OFF"
- os: linux
name: "Clang 7.0 Debug"
addons:
apt:
sources:
- ubuntu-toolchain-r-test
- llvm-toolchain-xenial-7.0
packages:
- clang
- cmake
- libboost-test-dev
- libboost-program-options-dev
- libboost-filesystem-dev
- libboost-thread-dev
env: MATRIX_EVAL="CC=clang CXX=clang++ TYPE=Debug STRICT=ON UNIT_TESTS=ON ASAN=OFF DBSIM=OFF"
- os: linux
name: "Clang 7.0 RelWithDebInfo"
addons:
apt:
sources:
- ubuntu-toolchain-r-test
- llvm-toolchain-xenial-7.0
packages:
- clang
- cmake
- libboost-test-dev
- libboost-program-options-dev
- libboost-filesystem-dev
- libboost-thread-dev
env: MATRIX_EVAL="CC=clang CXX=clang++ TYPE=RelWithDebInfo STRICT=ON UNIT_TESTS=ON ASAN=OFF DBSIM=OFF"
- os: osx
osx_image: xcode10.1
name: "Xcode 10.1 Debug"
env: MATRIX_EVAL="CC=clang CXX=clang++ TYPE=Debug STRICT=ON UNIT_TESTS=ON ASAN=OFF DBSIM=OFF"
- os: osx
osx_image: xcode10.1
name: "Xcode 10.1 RelWithDebInfo"
env: MATRIX_EVAL="CC=clang CXX=clang++ TYPE=RelWithDebInfo STRICT=ON UNIT_TESTS=ON ASAN=OFF DBSIM=OFF"
before_install:
- eval ${MATRIX_EVAL}
script:
- echo CC=${CC} CXX=${CXX} TYPE=${TYPE} STRICT=${STRICT} ${UNIT_TESTS} ASAN=${ASAN} DBSIM=${DBSIM}
- cmake . -DCMAKE_BUILD_TYPE=${TYPE}
-DWSREP_LIB_MAINTAINER_MODE:BOOL=ON
-DWSREP_LIB_STRICT_BUILD_FLAGS:BOOL=${STRICT}
-DWSREP_LIB_WITH_UNIT_TESTS:BOOL=${UNIT_TESTS}
-DWSREP_LIB_WITH_DBSIM:BOOL=${DBSIM}
-DWSREP_LIB_WITH_ASAN:BOOL=${ASAN}
- make VERBOSE=1 -j 4
- make test ARGS=--verbose