summaryrefslogtreecommitdiff
path: root/.appveyor.yml
blob: 9d5ce74b38da50687ca6547b1c8eb0cc6f0755ac (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
environment:
  global:
    CLBLAST_ROOT: "%APPVEYOR_BUILD_FOLDER%\\bin\\clblast"
    OPENCL_REGISTRY: "https://www.khronos.org/registry/cl"
    OPENCL_ROOT: "%APPVEYOR_BUILD_FOLDER%\\bin\\opencl"

platform:
  - x64

# Creates an OpenCL library to link against. Taken from clMathLibraries/clBLAS
install:
  - ps: mkdir $env:OPENCL_ROOT
  - ps: pushd $env:OPENCL_ROOT
  - ps: $opencl_registry = $env:OPENCL_REGISTRY
  # This downloads the source to the example/demo icd library
  - 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
  - ps: 7z x opencl-icd-1.2.11.0.tar
  - ps: mv .\icd\* .
  # This downloads all the opencl header files
  # The cmake build files expect a directory called inc
  - ps: mkdir inc/CL
  - ps: wget $opencl_registry/api/1.2/ | select -ExpandProperty links | where {$_.href -like "*.h*"} | select -ExpandProperty outerText | foreach{ wget $opencl_registry/api/1.2/$_ -OutFile inc/CL/$_ }
  # - ps: dir; if( $lastexitcode -eq 0 ){ dir include/CL } else { Write-Output boom }
  # Create the static import lib in a directory called lib, so findopencl() will find it
  - ps: mkdir lib
  - ps: pushd lib
  - cmake -G "NMake Makefiles" ..
  - nmake
  - ps: popd
  # Rename the inc directory to include, so FindOpencl() will find it
  - ps: ren inc include
  - ps: popd
  - ps: popd

before_build:
  - ps: mkdir $env:CLBLAST_ROOT
  - ps: pushd $env:CLBLAST_ROOT
  - cmake -G"Visual Studio 14 Win64" -DTESTS=ON -DCLIENTS=ON %APPVEYOR_BUILD_FOLDER%

build_script:
  - cmake --build .