-
Notifications
You must be signed in to change notification settings - Fork 7
135 lines (130 loc) · 3.5 KB
/
test-build.yml
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
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
name: Test Build
on:
push:
branches: [ master ]
pull_request:
branches: [ master ]
jobs:
build-linux:
name: Test Linux
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: conda-incubator/setup-miniconda@v2
with:
miniforge-version: latest
miniforge-variant: Mambaforge
- name: Install Dependencies
shell: bash -l {0}
run: |
conda install cmake awkward cxx-compiler hdf5 python numpy libgdal pybind11
- name: Cmake
shell: bash -l {0}
run: |
mkdir build
cd build
cmake -D CMAKE_INSTALL_PREFIX=$CONDA_PREFIX -D CMAKE_PREFIX_PATH=$CONDA_PREFIX -D LIBKEA_WITH_GDAL=ON ..
- name: make
shell: bash -l {0}
run: |
cd build
make
- name: make install
shell: bash -l {0}
run: |
cd build
make install
- name: make test
shell: bash -l {0}
run: |
cd build
make test
# slightly redundant since conda packages KEA, but I guess this checks we haven't broken anything
- name: check gdal
shell: bash -l {0}
run: gdal_translate --formats | grep KEA
- name: Cmake_Python
shell: bash -l {0}
run: |
cd python
mkdir build
cd build
cmake -D CMAKE_BUILD_TYPE=Release -D CMAKE_INSTALL_PREFIX=$CONDA_PREFIX -D CMAKE_PREFIX_PATH=$CONDA_PREFIX ..
- name: Make_Python
shell: bash -l {0}
run: |
cd python/build
make
- name: Install_Python
shell: bash -l {0}
run: |
cd python/build
make install
- name: Test_Python
shell: bash -l {0}
run: |
cd python/build
ctest --output-on-failure
build-windows:
name: Test Windows
runs-on: windows-latest
steps:
- uses: actions/checkout@v2
- uses: conda-incubator/setup-miniconda@v2
with:
miniforge-version: latest
miniforge-variant: Mambaforge
- uses: egor-tensin/vs-shell@v2
with:
arch: x64
- name: Install Dependencies
shell: bash -el {0}
run: |
conda install cmake "awkward>=2.5.0" hdf5 python numpy libgdal pybind11
- name: Cmake
shell: bash -el {0}
run: |
mkdir build
cd build
cmake -G "NMake Makefiles" -D CMAKE_BUILD_TYPE=Release -D CMAKE_INSTALL_PREFIX=$CONDA_PREFIX/Library -D CMAKE_PREFIX_PATH=$CONDA_PREFIX/Library -D LIBKEA_WITH_GDAL=ON ..
- name: nmake
shell: bash -el {0}
run: |
cd build
nmake
- name: nmake install
shell: bash -el {0}
run: |
cd build
nmake install
- name: nmake test
shell: bash -el {0}
run: |
cd build
nmake test
# slightly redundant since conda packages KEA, but I guess this checks we haven't broken anything
- name: check gdal
shell: bash -el {0}
run: gdal_translate --formats | grep KEA
- name: Cmake_Python
shell: bash -el {0}
run: |
cd python
mkdir build
cd build
cmake -G "NMake Makefiles" -D CMAKE_BUILD_TYPE=Release -D CMAKE_INSTALL_PREFIX=$CONDA_PREFIX/Library -D CMAKE_PREFIX_PATH=$CONDA_PREFIX/Library ..
- name: Make_Python
shell: bash -el {0}
run: |
cd python/build
nmake
- name: Install_Python
shell: bash -el {0}
run: |
cd python/build
nmake install
- name: Test_Python
shell: bash -el {0}
run: |
cd python/build
ctest --output-on-failure