appveyor.yml 2.75 KB
Newer Older
1
os: Visual Studio 2015
peastman's avatar
peastman committed
2
3
platform: x64
configuration: Release
Robert McGibbon's avatar
Robert McGibbon committed
4
5
6
shallow_clone: true
install:

peastman's avatar
peastman committed
7
8
# Setup shell for VS2015, x64
  - call "c:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\vcvarsall.bat" amd64
Robert McGibbon's avatar
Robert McGibbon committed
9
# Set path to python, git-bash tools.
peastman's avatar
peastman committed
10
  - "set PATH=C:\\Python35-x64;C:\\Python35-x64\\Scripts;%PATH%"
Robert McGibbon's avatar
Robert McGibbon committed
11
  - "set PATH=C:\\Program Files (x86)\\Git\\bin;%PATH%"
12
  - pip install pytest
peastman's avatar
peastman committed
13
  - pip install numpy
peastman's avatar
peastman committed
14
  - pip install cython
Robert McGibbon's avatar
Robert McGibbon committed
15

Robert McGibbon's avatar
Robert McGibbon committed
16
17
18
19
20
21
# 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"

Robert McGibbon's avatar
Robert McGibbon committed
22
23
24
25
26
27
28
29
30
# 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
  - 7z x fftw-3.3.4-dll64.zip -oC:\fftw > null
  - cd C:\fftw
  - lib /def:libfftw3f-3.def
  - cd %APPVEYOR_BUILD_FOLDER%
  - "set PATH=C:\\fftw;%PATH%"

# Download and install some OpenMM build dependencies (doxygen, swig)
Robert T. McGibbon's avatar
Robert T. McGibbon committed
31
  - choco install -y doxygen.portable swig > null
Robert McGibbon's avatar
Robert McGibbon committed
32

33
# Download OpenCL Headers and build the ICD loader
peastman's avatar
peastman committed
34
  - ps: "[System.Net.ServicePointManager]::SecurityProtocol = [System.Net.SecurityProtocolType]::Tls12;"
peastman's avatar
peastman committed
35
36
  - ps: $opencl_registry = "https://www.khronos.org/registry/cl"
  - ps: $opencl_github = "KhronosGroup/OpenCL-Headers"
37
38
39
40
41
42
43
  - ps: mkdir C:/opencl > $null
  - ps: cd C:/opencl
  - ps: wget $opencl_registry/specs/opencl-icd-1.2.11.0.tgz -OutFile opencl-icd-1.2.11.0.tgz
  - ps: 7z x opencl-icd-1.2.11.0.tgz > $null
  - ps: 7z x opencl-icd-1.2.11.0.tar > $null
  - ps: mv .\icd\* .
  - ps: mkdir inc/CL > $null
peastman's avatar
peastman committed
44
  - ps: wget https://github.com/$opencl_github/tree/master/CL -UseBasicParsing | select -ExpandProperty links | where {$_.href -like "*.h*"} | select -ExpandProperty title | foreach{ wget https://raw.githubusercontent.com/$opencl_github/master/CL/$_ -OutFile inc/CL/$_ -UseBasicParsing}
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
  - ps: mkdir lib > $null
  - ps: cd lib
  - cmake -G "NMake Makefiles" ..
  - nmake
  - cd %APPVEYOR_BUILD_FOLDER%

build_script:
  - ps: $env:CMAKE_FLAGS =
      "-DOPENMM_BUILD_PME_PLUGIN=ON
       -DOPENCL_INCLUDE_DIR=C:/opencl/inc
       -DOPENCL_LIBRARY=C:/opencl/lib/OpenCL.lib
       -DFFTW_LIBRARY=C:/fftw/libfftw3f-3.lib
       -DFFTW_INCLUDES=C:/fftw
       -DOPENMM_BUILD_EXAMPLES=OFF
       -DOPENMM_BUILD_OPENCL_TESTS=OFF
       -DCMAKE_BUILD_TYPE=Release
       -LA"
Robert McGibbon's avatar
Robert McGibbon committed
62
63
  - mkdir build
  - cd build
Robert McGibbon's avatar
Robert McGibbon committed
64
  - cmake -G "NMake Makefiles" %CMAKE_FLAGS% -DCMAKE_CXX_FLAGS_RELEASE="/MD /Od /Ob0 /D NDEBUG" ..
Robert McGibbon's avatar
No jom  
Robert McGibbon committed
65
66
67
  - cmake --build . --target install
  - cmake --build . --target PythonInstall

Robert McGibbon's avatar
Robert McGibbon committed
68
test_script:
Robert T. McGibbon's avatar
Robert T. McGibbon committed
69
  - python %APPVEYOR_BUILD_FOLDER%\devtools\run-ctest.py
Robert McGibbon's avatar
Robert McGibbon committed
70
  - cd python\tests
71
  - py.test -v
Robert McGibbon's avatar
Robert McGibbon committed
72
73
74

cache:
- C:\ProgramData\cclash -> appveyor.yml