Commit 461fcdf0 authored by peastman's avatar peastman
Browse files

Merge pull request #1300 from rmcgibbo/ccache

[CI] Use ccache
parents 6ed5d684 ed478282
...@@ -9,14 +9,19 @@ addons: ...@@ -9,14 +9,19 @@ addons:
- python-scipy - python-scipy
- libfftw3-dev - libfftw3-dev
env:
global:
- CCACHE=$HOME/ccache/lib/ccache/bin
matrix: matrix:
include: include:
- sudo: required - sudo: required
env: ==CPU_OPENCL== env: ==CPU_OPENCL==
OPENCL=true OPENCL=true
CUDA=false CUDA=false
CC=gcc CC=$CCACHE/gcc
CXX=g++ CXX=$CCACHE/g++
CMAKE_FLAGS=" CMAKE_FLAGS="
-OPENMM_BUILD_OPENCL_LIB=ON -OPENMM_BUILD_OPENCL_LIB=ON
-DOPENMM_BUILD_OPENCL_TESTS=ON -DOPENMM_BUILD_OPENCL_TESTS=ON
...@@ -36,6 +41,8 @@ matrix: ...@@ -36,6 +41,8 @@ matrix:
CUDA=true CUDA=true
OPENCL=false OPENCL=false
CUDA_VERSION="7.0-28" CUDA_VERSION="7.0-28"
CC=$CCACHE/gcc
CXX=$CCACHE/g++
CMAKE_FLAGS=" CMAKE_FLAGS="
-DOPENMM_BUILD_CUDA_TESTS=OFF -DOPENMM_BUILD_CUDA_TESTS=OFF
-DOPENMM_BUILD_OPENCL_TESTS=OFF -DOPENMM_BUILD_OPENCL_TESTS=OFF
...@@ -62,8 +69,8 @@ matrix: ...@@ -62,8 +69,8 @@ matrix:
env: ==STATIC_LIB== env: ==STATIC_LIB==
OPENCL=false OPENCL=false
CUDA=false CUDA=false
CC=clang CC=$CCACHE/clang
CXX=clang++ CXX=$CCACHE/clang++
CMAKE_FLAGS="-DOPENMM_BUILD_STATIC_LIB=ON" CMAKE_FLAGS="-DOPENMM_BUILD_STATIC_LIB=ON"
- sudo: false - sudo: false
...@@ -71,8 +78,8 @@ matrix: ...@@ -71,8 +78,8 @@ matrix:
env: ==PYTNON_2== env: ==PYTNON_2==
OPENCL=false OPENCL=false
CUDA=false CUDA=false
CC=clang CC=$CCACHE/clang
CXX=clang++ CXX=$CCACHE/clang++
DOCS_DEPLOY=true DOCS_DEPLOY=true
CMAKE_FLAGS="" CMAKE_FLAGS=""
...@@ -81,11 +88,13 @@ matrix: ...@@ -81,11 +88,13 @@ matrix:
env: ==PYTHON_3== env: ==PYTHON_3==
OPENCL=false OPENCL=false
CUDA=false CUDA=false
CC=gcc CC=$CCACHE/gcc
CXX=g++ CXX=$CCACHE/g++
CMAKE_FLAGS="" CMAKE_FLAGS=""
before_install: before_install:
- wget https://anaconda.org/omnia/ccache/3.2.4/download/${TRAVIS_OS_NAME}-64/ccache-3.2.4-0.tar.bz2
- mkdir -p $HOME/ccache && tar xf ccache-3.2.4-0.tar.bz2 -C $HOME/ccache
- if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then - if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then
brew install doxygen swig fftw; brew install doxygen swig fftw;
sudo easy_install pytest; sudo easy_install pytest;
...@@ -158,3 +167,7 @@ deploy: ...@@ -158,3 +167,7 @@ deploy:
on: on:
branch: master branch: master
condition: '! -z "${DOCS_DEPLOY}" && "${DOCS_DEPLOY}" = "true"' condition: '! -z "${DOCS_DEPLOY}" && "${DOCS_DEPLOY}" = "true"'
cache:
directories:
- $HOME/.ccache
...@@ -10,6 +10,12 @@ install: ...@@ -10,6 +10,12 @@ install:
- "set PATH=C:\\Program Files (x86)\\Git\\bin;%PATH%" - "set PATH=C:\\Program Files (x86)\\Git\\bin;%PATH%"
- pip install pytest - pip install pytest
# Use cclash for compiler caching (experimental)
- ps: wget https://github.com/inorton/cclash/releases/download/0.3.14/cclash-0.3.14.zip -OutFile cclash-0.3.14.zip
- ps: 7z x cclash-0.3.14.zip
- "set PATH=%APPVEYOR_BUILD_FOLDER%\\cclash-0.3.14;%PATH%"
- "set CCLASH_DIR=C:\\ProgramData\\cclash"
# Download FFTW3 for PME plugin # Download FFTW3 for PME plugin
- C:\MinGW\msys\1.0\bin\wget -q ftp://ftp.fftw.org/pub/fftw/fftw-3.3.4-dll64.zip - C:\MinGW\msys\1.0\bin\wget -q ftp://ftp.fftw.org/pub/fftw/fftw-3.3.4-dll64.zip
- 7z x fftw-3.3.4-dll64.zip -oC:\fftw > null - 7z x fftw-3.3.4-dll64.zip -oC:\fftw > null
...@@ -50,7 +56,7 @@ build_script: ...@@ -50,7 +56,7 @@ build_script:
-LA" -LA"
- mkdir build - mkdir build
- cd build - cd build
- cmake -G "NMake Makefiles" %CMAKE_FLAGS% -LA -DCMAKE_CXX_FLAGS_RELEASE="/MD /Od /Ob0 /D NDEBUG" .. - cmake -G "NMake Makefiles" %CMAKE_FLAGS% -DCMAKE_CXX_FLAGS_RELEASE="/MD /Od /Ob0 /D NDEBUG" ..
- cmake --build . --target install - cmake --build . --target install
- cmake --build . --target PythonInstall - cmake --build . --target PythonInstall
...@@ -58,3 +64,6 @@ test_script: ...@@ -58,3 +64,6 @@ test_script:
- python %APPVEYOR_BUILD_FOLDER%\devtools\run-ctest.py - python %APPVEYOR_BUILD_FOLDER%\devtools\run-ctest.py
- cd python\tests - cd python\tests
- py.test -v - py.test -v
cache:
- C:\ProgramData\cclash -> appveyor.yml
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment