elif [[ "${COMPILER}" == "clang-3.6" ]]; then
export CC=clang-3.6
export CXX=clang++-3.6
- elif [[ "${COMPILER}" == "clang-4.0" ]]; then
- export CC=clang-4.0
- export CXX=clang++-4.0
+ elif [[ "${COMPILER}" == "clang-5.0" ]]; then
+ export CC=clang-5.0
+ export CXX=clang++-5.0
fi
}
# Mac OSX build only
install_macosx_deps() {
brew update
- brew install freetype gettext hiredis irrlicht jpeg leveldb libogg libvorbis luajit
+ brew install freetype gettext hiredis irrlicht leveldb libogg libvorbis luajit
+ if brew ls | grep -q jpeg; then
+ brew upgrade jpeg
+ else
+ brew install jpeg
+ fi
#brew upgrade postgresql
}
TRIGGER_COMPILE_PATHS="src/.*\.(c|cpp|h)|CMakeLists.txt|cmake/Modules/|util/travis/|util/buildbot/"
needs_compile() {
- git diff --name-only $TRAVIS_COMMIT_RANGE | egrep -q "^($TRIGGER_COMPILE_PATHS)"
+ RANGE="$TRAVIS_COMMIT_RANGE"
+ if [[ "$(git diff --name-only $RANGE -- 2>/dev/null)" == "" ]]; then
+ RANGE="$TRAVIS_COMMIT^...$TRAVIS_COMMIT"
+ echo "Fixed range: $RANGE"
+ fi
+ git diff --name-only $RANGE -- | egrep -q "^($TRIGGER_COMPILE_PATHS)"
}