Remove Linux stuff from Travis CI
This commit is contained in:
parent
6de350c931
commit
dc9cdc0143
15
.travis.yml
15
.travis.yml
@ -1,22 +1,9 @@
|
||||
language: cpp
|
||||
sudo: required
|
||||
dist: trusty
|
||||
compiler:
|
||||
# - gcc
|
||||
- clang
|
||||
os:
|
||||
#- linux
|
||||
- osx
|
||||
addons:
|
||||
apt:
|
||||
sources:
|
||||
# Both needed for clang 3.7
|
||||
- llvm-toolchain-precise-3.7
|
||||
- ubuntu-toolchain-r-test
|
||||
packages:
|
||||
- clang-3.7
|
||||
- libcrypto++-dev
|
||||
- libfuse-dev
|
||||
os: osx
|
||||
install:
|
||||
- .travisci/install.sh
|
||||
script:
|
||||
|
@ -2,21 +2,13 @@
|
||||
|
||||
set -ev
|
||||
|
||||
# Use new clang on linux
|
||||
if [ "${TRAVIS_OS_NAME}" == "linux" ] && [ "$CXX" == "clang++" ]; then
|
||||
echo Switch to Clang 3.7
|
||||
export CXX="clang++-3.7" CC="clang-3.7"
|
||||
else
|
||||
echo Do not switch to Clang 3.7 because we are either not Linux or not Clang.
|
||||
fi
|
||||
|
||||
# If using gcc on mac, actually use it ("gcc" just links to clang, but "gcc-4.8" is gcc, https://github.com/travis-ci/travis-ci/issues/2423)
|
||||
# Note: This must be here and not in install.sh, because environment variables can't be passed between scripts.
|
||||
if [ "${TRAVIS_OS_NAME}" == "osx" ] && [ "${CXX}" == "g++" ]; then
|
||||
if [ "${CXX}" == "g++" ]; then
|
||||
echo Switch to actual g++ and not just the AppleClang symlink
|
||||
export CXX="g++-7" CC="gcc-7"
|
||||
else
|
||||
echo Do not switch to actual g++ because we are either not osx or not g++
|
||||
echo Do not switch to actual g++ because we are not g++
|
||||
fi
|
||||
|
||||
# Setup ccache
|
||||
@ -28,10 +20,7 @@ ccache --max-size=512M
|
||||
ccache --show-stats
|
||||
|
||||
# Detect number of CPU cores
|
||||
export NUMCORES=`grep -c ^processor /proc/cpuinfo`
|
||||
if [ ! -n "$NUMCORES" ]; then
|
||||
export NUMCORES=`sysctl -n hw.ncpu`
|
||||
fi
|
||||
export NUMCORES=`sysctl -n hw.ncpu`
|
||||
echo Using $NUMCORES cores
|
||||
|
||||
echo Using CXX compiler $CXX and C compiler $CC
|
||||
@ -55,8 +44,6 @@ ccache --show-stats
|
||||
./test/blobstore/blobstore-test
|
||||
./test/cryfs/cryfs-test
|
||||
|
||||
# TODO Also run on osx once fixed
|
||||
if [ "${TRAVIS_OS_NAME}" == "linux" ]; then
|
||||
./test/fspp/fspp-test
|
||||
./test/cryfs-cli/cryfs-cli-test
|
||||
fi
|
||||
# TODO Also run once fixed
|
||||
# ./test/fspp/fspp-test
|
||||
# ./test/cryfs-cli/cryfs-cli-test
|
||||
|
@ -2,31 +2,19 @@
|
||||
|
||||
set -e
|
||||
|
||||
# Install dependencies
|
||||
if [ "${TRAVIS_OS_NAME}" == "linux" ]; then
|
||||
./.travisci/install_boost.sh
|
||||
fi
|
||||
|
||||
# Install newer GCC if we're running on GCC osx
|
||||
if [ "${TRAVIS_OS_NAME}" == "osx" ] && [ "${CXX}" == "g++" ]; then
|
||||
# Install newer GCC if we're running on GCC
|
||||
if [ "${CXX}" == "g++" ]; then
|
||||
# We need to uninstall oclint because it creates a /usr/local/include/c++ symlink that clashes with the gcc5 package
|
||||
# see https://github.com/Homebrew/homebrew-core/issues/21172
|
||||
brew cask uninstall oclint
|
||||
brew install gcc@7
|
||||
fi
|
||||
|
||||
if [ "${TRAVIS_OS_NAME}" == "osx" ]; then
|
||||
brew cask install osxfuse
|
||||
brew install libomp
|
||||
fi
|
||||
brew cask install osxfuse
|
||||
brew install libomp
|
||||
|
||||
# By default, travis only fetches the newest 50 commits. We need more in case we're further from the last version tag, so the build doesn't fail because it can't generate the version number.
|
||||
git fetch --unshallow
|
||||
|
||||
# Use /dev/urandom when /dev/random is accessed, because travis doesn't have enough entropy
|
||||
if [ "${TRAVIS_OS_NAME}" == "linux" ]; then
|
||||
sudo cp -a /dev/urandom /dev/random
|
||||
fi
|
||||
|
||||
# Setup ccache
|
||||
brew install ccache
|
||||
|
@ -1,12 +0,0 @@
|
||||
#!/bin/bash
|
||||
|
||||
set -e
|
||||
|
||||
wget -O boost.tar.bz2 https://sourceforge.net/projects/boost/files/boost/1.56.0/boost_1_56_0.tar.bz2/download
|
||||
tar -xf boost.tar.bz2
|
||||
cd boost_1_56_0
|
||||
# TODO We should use clang as toolchain for building boost when clang is used for building our code
|
||||
./bootstrap.sh --with-libraries=filesystem,thread,chrono,program_options
|
||||
sudo ./b2 -d0 -j$NUMCORES install
|
||||
cd ..
|
||||
sudo rm -rf boost.tar.bz2 boost_1_56_0
|
Loading…
x
Reference in New Issue
Block a user