Switch to trusty travis build

This commit is contained in:
Dmitry Marakasov 2015-11-05 18:43:10 +03:00
parent 39e2249a76
commit 86cdcdf588

View File

@ -1,4 +1,6 @@
language: cpp language: cpp
sudo: required
dist: trusty
compiler: compiler:
- gcc - gcc
- clang - clang
@ -6,16 +8,12 @@ env:
- CXXSTD=c++11 - CXXSTD=c++11
- CXXSTD=c++1y - CXXSTD=c++1y
before_install: before_install:
- sudo add-apt-repository --yes ppa:zoogie/sdl2-snapshots
- sudo add-apt-repository --yes ppa:ubuntu-toolchain-r/test
- sudo add-apt-repository --yes ppa:libreoffice/libreoffice-4-2
- sudo apt-get update -qq - sudo apt-get update -qq
- sudo apt-get install -qq cmake libsdl2-dev libsdl2-image-dev libsdl2-ttf-dev libsdl2-mixer-dev g++-4.8 cppcheck doxygen - sudo apt-get install -qq cmake libsdl2-dev libsdl2-image-dev libsdl2-ttf-dev libsdl2-mixer-dev cppcheck doxygen
- sudo sed -i -e 's|friend class hash|friend struct hash|' /usr/include/c++/4.8/bits/stl_bvector.h - sudo sed -i -e '/using ::gets/ d' /usr/include/c++/4.8/cstdio # build failure with clang/c++1y
- if [ "$CXX" = "g++" ]; then export CXX="g++-4.8" CC="gcc-4.8"; fi
script: script:
- cmake . -DSDL2PP_ENABLE_LIVE_TESTS=OFF -DCMAKE_INSTALL_PREFIX=`pwd`.prefix -DSDL2PP_WITH_WERROR=YES -DSDL2PP_CXXSTD=$CXXSTD - cmake . -DSDL2PP_ENABLE_LIVE_TESTS=OFF -DCMAKE_INSTALL_PREFIX=`pwd`.prefix -DSDL2PP_WITH_WERROR=YES -DSDL2PP_CXXSTD=$CXXSTD
- VERBOSE=1 make && make test && make install - VERBOSE=1 make && make test && make install
- cppcheck -I . --enable=style,performance,portability,information,missingInclude --error-exitcode=2 SDL2pp - cppcheck -I . --enable=performance,portability,information,missingInclude --error-exitcode=2 SDL2pp # `style' gives false positive in cppcheck 1.61 which comes with trusty
- "if make doxygen 2>&1 | grep 'warning:'; then echo 'FATAL: doxygen warnings!'; false; fi" - "if make doxygen 2>&1 | grep 'warning:'; then echo 'FATAL: doxygen warnings!'; false; fi"
- "if git ls-files --others --exclude-standard | grep ''; then echo 'FATAL: incomplete .gitignore'; false; fi" - "if git ls-files --others --exclude-standard | grep ''; then echo 'FATAL: incomplete .gitignore'; false; fi"