代码拉取完成,页面将自动刷新
sudo: false
language: cpp
os:
- linux
- osx
compiler:
- gcc
- clang
cache:
- ccache
env:
- THREADING="serial"
- THREADING="openmp"
- THREADING="pthread"
# Apple GCC does not support OpenMP. GCC with OpenMP requires Homebrew.
# Apple Clang does not support OpenMP. Clang with OpenMP requires Homebrew.
matrix:
exclude:
- os: osx
env: THREADING="openmp"
- os: osx
compiler: gcc
before_script:
- if [[ ${TRAVIS_OS_NAME} == "osx" ]]; then
brew update;
export HOMEBREW_NO_AUTO_UPDATE=1;
brew ls --versions ccache > /dev/null || brew install ccache;
export PATH=/usr/local/opt/ccache/libexec:$PATH;
fi
- ccache -z
script:
- export OMP_NUM_THREADS=2
- export OMP_PLACES=threads
- export OMP_PROC_BIND=spread
# LD_LIBRARY_PATH workaround to find clang's libomp: https://github.com/travis-ci/travis-ci/issues/8613
- if [[ ${CC} = clang ]]; then export LD_LIBRARY_PATH=/usr/local/clang/lib${LD_LIBRARY_PATH:+:}$LD_LIBRARY_PATH; fi
# enable ccache for clang on linux and add CCACHE_CPP2 to avoid 'Argument unused during compilation -I...' warning
- if [[ ${TRAVIS_OS_NAME} = linux && ${CC} = clang ]]; then
ln -s /usr/bin/ccache $HOME/bin/clang++;
export CCACHE_CPP2=yes;
GENERATE_OPTS="--gcc-toolchain=/usr";
fi
- mkdir build
- cd build
- ../generate_makefile.bash --compiler=$CXX --with-$THREADING --with-options=compiler_warnings --cxxflags="-O3 -Werror" ${GENERATE_OPTS}
- make
- make test
after_success:
- ccache -s
此处可能存在不合适展示的内容,页面不予展示。您可通过相关编辑功能自查并修改。
如您确认内容无涉及 不当用语 / 纯广告导流 / 暴力 / 低俗色情 / 侵权 / 盗版 / 虚假 / 无价值内容或违法国家有关法律法规的内容,可点击提交进行申诉,我们将尽快为您处理。