1language: cpp 2sudo: required 3matrix: 4 include: 5 - os: linux 6 dist: xenial 7 compiler: clang 8 python: "3.6" 9 - os: linux 10 dist: xenial 11 compiler: gcc 12 python: "3.5" 13 - os: osx 14 #compiler: clang 15 16git: 17 depth: 5 18 19addons: 20 apt: 21 sources: 22 # add PPAs with more up-to-date toolchains 23 - ubuntu-toolchain-r-test 24 - llvm-toolchain-xenial-7 25 packages: 26 - gcc-8 27 - g++-8 28 #- clang-7.0 29 #- llvm-7.0-dev 30 #- libclang-7.0-dev 31 - mesa-common-dev 32 - libsdl2-dev 33 - libsdl2-image-dev 34 - libsdl2-ttf-dev 35 - libfreetype6-dev 36 - libopenal-dev 37 - libvorbis-dev 38 - zlib1g-dev 39 - libboost-dev 40 - libboost-system-dev 41 - libboost-filesystem-dev 42 - libboost-test-dev 43 - libtinyxml-dev 44 - libc6 45 - libglew-dev 46 - pylint 47 48before_install: 49 # Linux Build 50 # change gcc to version 8 51 - if [ $TRAVIS_OS_NAME == linux ]; then sudo update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-8 20; sudo update-alternatives --install /usr/bin/g++ g++ /usr/bin/g++-8 20; fi 52 - if [ $TRAVIS_OS_NAME == linux ]; then sudo update-alternatives --config gcc; sudo update-alternatives --config g++; fi 53 # change clang to version 7.0 54 #- if [ $TRAVIS_OS_NAME == linux ]; then sudo update-alternatives --install /usr/bin/clang clang /usr/bin/clang-6.0 20; sudo update-alternatives --install /usr/bin/clang++ clang++ /usr/bin/clang++-6.0 20; fi 55 #- if [ $TRAVIS_OS_NAME == linux ]; then sudo rm -f /usr/local/clang-5.0.0/bin/clang; sudo rm -f /usr/local/clang-5.0.0/bin/clang++; sudo update-alternatives --config clang; sudo update-alternatives --config clang++; fi 56 #- if [ $TRAVIS_OS_NAME == linux ]; then sudo apt-get -qq update && sudo apt-get install -y libgle3-dev libvorbis-dev libalut-dev cppcheck; fi 57 # install newer version of pylint, the one fetched with apt-get is broken 58 #- if [ $TRAVIS_OS_NAME == linux ]; then sudo pip install pylint; fi 59 # Swig 60 - if [ $TRAVIS_OS_NAME == linux ]; then sudo add-apt-repository ppa:timsc/swig-3.0.12 -y; sudo apt-get update -q; sudo apt-get install swig; fi 61 # MacOS Build 62 - if [ $TRAVIS_OS_NAME == osx ]; then HOMEBREW_NO_AUTO_UPDATE=1 brew install boost swig sdl2 sdl2_image sdl2_ttf freetype openal-soft tinyxml glew libvorbis python3 python || brew upgrade boost swig sdl2 sdl2_image sdl2_ttf freetype openal-soft tinyxml glew libvorbis python3 python || brew outdated boost swig sdl2 sdl2_image sdl2_ttf freetype openal-soft tinyxml glew libvorbis python3 python; fi 63 - cmake --version 64 65install: 66 - git clone --quiet --depth 1 git://github.com/fifengine/fifechan.git 67 - if [ $TRAVIS_OS_NAME == linux ]; then mkdir build_fifechan; cd build_fifechan; cmake -DCMAKE_INSTALL_PREFIX:PATH=/usr ../fifechan; fi 68 - if [ $TRAVIS_OS_NAME == osx ]; then mkdir build_fifechan; cd build_fifechan; cmake ../fifechan; fi 69 - make -j3 70 - sudo make install 71 - cd .. 72 73script: 74 - cd .. 75 - if [ $TRAVIS_OS_NAME == linux ]; then mkdir build; cd build; cmake -DPYTHON_EXECUTABLE=/usr/bin/python3 -DCMAKE_INSTALL_PREFIX:PATH=/usr -Dcegui=OFF ../fifengine; fi 76 - if [ $TRAVIS_OS_NAME == osx ]; then mkdir build; cd build; cmake -Dbuild-library=ON -DPYTHON_EXECUTABLE=/usr/local/bin/python3 -Dcegui=OFF ../fifengine; fi 77 - ls -alh . 78 - make -j3 79 - sudo make install 80 81after_script: 82 - cd $TRAVIS_BUILD_DIR 83 - python3 -c 'from fife import fife; print(fife.getVersion())' 84 - if [ $TRAVIS_OS_NAME == linux ]; then cppcheck --verbose --enable=all --std=posix --std=c++11 --quiet -iengine/core/ext engine/core; fi 85 - if [ $TRAVIS_OS_NAME == linux ]; then pylint --rcfile=.pylintrc ./engine/python/fife/; fi 86 87notifications: 88 irc: irc.freenode.org#fife 89 email: false 90 91#deploy: 92# provider: releases 93# api_key: 94# secure: "TiE1MLzq8DE2vJjiTeWnuhjEM/cH4hQ7yL/SSDkIqTijCY1eiCX6KPE7yDNh9F1SkCfxYyDPTuRc+f1EaAbk073aL56kUTM/bV/4TEcHk4TS40Hcd5aA10gR3XOH3lYwagT2edgXgXLA1cvU1tuwj8stKz1hEnkVlCvFdbvy4qg=" 95# file: Fifengine*.tar.gz 96# file_glob: true 97# skip_cleanup: true 98# overwrite: true 99# on: 100# tags: true 101