Update Travis CI configuration.

* Stop updating brew.
* Shadow clone of dependencies.
* Fix `nproc` on macOS.
This commit is contained in:
Lei Zhang 2017-01-12 14:15:36 -05:00
Родитель 545a6c1dc3
Коммит d5e4f06eec
1 изменённых файлов: 12 добавлений и 7 удалений

Просмотреть файл

@ -7,8 +7,8 @@ os:
- osx
# Use Ubuntu 14.04 LTS (Trusty) as the Linux testing environment.
sudo: required
dist: trusty
sudo: required
# Use the default Xcode environment for Xcode.
@ -28,7 +28,7 @@ matrix:
# Additional build using Android NDK
- env: BUILD_NDK=ON
exclude:
# Skip GCC builds on Mac OS X.
# Skip GCC builds on macOS.
- os: osx
compiler: gcc
@ -45,8 +45,8 @@ addons:
- ninja-build
before_install:
# Install cmake & ninja on Mac OS X.
- if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then brew update && brew install ninja; fi
# Install cmake & ninja on macOS.
- if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then brew install ninja; fi
- if [[ "$BUILD_NDK" == "ON" ]]; then
git clone --depth=1 https://github.com/urho3d/android-ndk.git $HOME/android-ndk;
export ANDROID_NDK=$HOME/android-ndk;
@ -55,8 +55,8 @@ before_install:
fi
before_script:
- git clone https://github.com/KhronosGroup/SPIRV-Headers.git external/spirv-headers
- git clone https://github.com/google/googletest.git external/googletest
- git clone --depth=1 https://github.com/KhronosGroup/SPIRV-Headers external/spirv-headers
- git clone --depth=1 https://github.com/google/googletest external/googletest
script:
- mkdir build && cd build
@ -71,7 +71,12 @@ script:
cmake -GNinja -DCMAKE_BUILD_TYPE=${BUILD_TYPE} ..;
fi
- ninja
- if [[ "$BUILD_NDK" != "ON" ]]; then ctest -j`nproc` --output_on_failure; fi
- if [[ "$TRAVIS_OS_NAME" == "linux" ]]; then
export NPROC=`nproc`;
else
export NPROC=`sysctl -n hw.ncpu`;
fi
- if [[ "$BUILD_NDK" != "ON" ]]; then ctest -j${NPROC} --output_on_failure; fi
notifications: