@@ -4,8 +4,9 @@ on: [push, pull_request]
4
4
5
5
jobs :
6
6
build-mingw :
7
- name : ${{matrix.sys}}-${{matrix.env}}-${{matrix.build_type}}-${{matrix.lib}}-${{matrix.components}}-${{matrix.metis}}
8
- runs-on : windows-latest
7
+ if : false
8
+ name : mingw64-${{matrix.env}}-${{matrix.build_type}}-${{matrix.lib}}-${{matrix.components}}-${{matrix.metis}}
9
+ runs-on : ${{matrix.os}}
9
10
defaults :
10
11
run :
11
12
shell : msys2 {0}
@@ -15,23 +16,32 @@ jobs:
15
16
fail-fast : true
16
17
matrix :
17
18
build_type : [Release, Debug]
18
- sys : [mingw64]
19
19
lib : [shared, static]
20
+ arch :
21
+ - arm64
22
+ - x64
20
23
components : [minimal, lgpl, gpl]
21
24
metis : [no-metis, metis]
22
25
exclude :
23
26
# METIS is only usable if CHOLMOD is compiled
24
27
- components : minimal
25
28
metis : metis
26
29
include :
27
- - sys : mingw64
30
+ - arch : x64
31
+ os : windows-2022
28
32
env : x86_64
33
+ sys : mingw64
34
+ - arch : arm64
35
+ os : windows-11-arm
36
+ env : clang-aarch64
37
+ sys : clangarm64
29
38
30
39
steps :
31
40
- uses : actions/checkout@v4
32
41
33
- - name : Setup Dependencies
42
+ - name : Setup Dependencies (x86_64)
34
43
uses : msys2/setup-msys2@v2
44
+ if : ${{matrix.sys == 'mingw64'}}
35
45
with :
36
46
msystem : ${{matrix.sys}}
37
47
install : >-
47
57
unzip
48
58
wget
49
59
60
+ - name : Setup Dependencies (clang-aarch64)
61
+ uses : msys2/setup-msys2@v2
62
+ if : ${{matrix.sys == 'clangarm64'}}
63
+ with :
64
+ msystem : ${{matrix.sys}}
65
+ install : >-
66
+ mingw-w64-${{matrix.env}}-ccache
67
+ mingw-w64-${{matrix.env}}-clang
68
+ mingw-w64-${{matrix.env}}-cmake
69
+ mingw-w64-${{matrix.env}}-flang
70
+ mingw-w64-${{matrix.env}}-intel-tbb
71
+ mingw-w64-${{matrix.env}}-lapack
72
+ mingw-w64-${{matrix.env}}-ninja
73
+ mingw-w64-${{matrix.env}}-openblas
74
+ mingw-w64-${{matrix.env}}-openmp
75
+ unzip
76
+ wget
77
+
78
+
50
79
- name : Setup METIS Dependencies
51
80
if : ${{matrix.metis == 'metis'}}
52
81
run : >-
94
123
--target install
95
124
96
125
build-msvc :
97
- name : ${{matrix.msvc}}-${{matrix.build_type}}-${{matrix.lib}}-${{matrix.components}}-${{matrix.metis}}
126
+ name : ${{matrix.msvc}}-${{matrix.arch}}-${{matrix. build_type}}-${{matrix.lib}}-${{matrix.components}}-${{matrix.metis}}
98
127
runs-on : ${{matrix.os}}
99
128
env :
100
129
CCACHE_DIR : ${{github.workspace}}/ccache
@@ -106,8 +135,10 @@ jobs:
106
135
fail-fast : true
107
136
matrix :
108
137
build_type : [Release, Debug]
109
- msvc : [VS-16-2019, VS-17-2022]
110
- sys : [mingw64]
138
+ msvc : [VS-17-2022]
139
+ arch :
140
+ - arm64
141
+ - x64
111
142
lib : [shared, static]
112
143
components : [minimal, lgpl, gpl]
113
144
metis : [no-metis, metis]
@@ -116,17 +147,19 @@ jobs:
116
147
- components : minimal
117
148
metis : metis
118
149
include :
119
- - sys : mingw64
120
- env : x86_64
121
- system : Win64
122
- - msvc : VS-16-2019
123
- generator : " Visual Studio 16 2019"
124
- os : windows-2019
125
- marker : vc16
126
150
- msvc : VS-17-2022
127
151
generator : " Visual Studio 17 2022"
128
- os : windows-2022
129
152
marker : vc17
153
+ - arch : x64
154
+ env : x86_64
155
+ os : windows-2022
156
+ sys : mingw64
157
+ system : Win64
158
+ - arch : arm64
159
+ env : clang-aarch64
160
+ os : windows-11-arm
161
+ sys : clangarm64
162
+ system : arm64
130
163
131
164
steps :
132
165
- uses : actions/checkout@v4
@@ -137,7 +170,7 @@ jobs:
137
170
uses : actions/cache@v4
138
171
with :
139
172
path : metis/
140
- key : ${{matrix.msvc}}-metis-5.1.0-${{matrix.build_type}}-shared
173
+ key : ${{matrix.msvc}}-${{matrix.arch}}- metis-5.1.0-${{matrix.build_type}}-shared
141
174
142
175
- name : Download METIS
143
176
if : matrix.metis == 'metis' && steps.cache-metis.outputs.cache-hit != 'true'
@@ -160,7 +193,7 @@ jobs:
160
193
Pop-Location
161
194
162
195
cmake -S metis-5.1.0 -B build-metis `
163
- -A x64 `
196
+ -A ${{matrix.arch}} `
164
197
-DCMAKE_INSTALL_PREFIX=${{github.workspace}}/metis `
165
198
-DCMAKE_WINDOWS_EXPORT_ALL_SYMBOLS=ON `
166
199
-DMETIS_INSTALL:BOOL=ON `
@@ -170,9 +203,9 @@ jobs:
170
203
--config ${{matrix.build_type}} `
171
204
--target install
172
205
173
-
174
- - name : Setup MSYS2
206
+ - name : Setup MSYS2 (x86_64)
175
207
uses : msys2/setup-msys2@v2
208
+ if : ${{matrix.sys == 'mingw64'}}
176
209
with :
177
210
msystem : ${{matrix.sys}}
178
211
path-type : inherit
@@ -182,14 +215,26 @@ jobs:
182
215
mingw-w64-${{matrix.env}}-gcc-fortran
183
216
mingw-w64-${{matrix.env}}-ninja
184
217
218
+ - name : Setup MSYS2 (aarch64)
219
+ uses : msys2/setup-msys2@v2
220
+ if : ${{matrix.sys == 'clangarm64'}}
221
+ with :
222
+ msystem : ${{matrix.sys}}
223
+ path-type : inherit
224
+ install : >-
225
+ wget
226
+ mingw-w64-${{matrix.env}}-ccache
227
+ mingw-w64-${{matrix.env}}-flang
228
+ mingw-w64-${{matrix.env}}-ninja
229
+
185
230
- name : Cache LAPACK
186
231
id : cache-lapack
187
232
uses : actions/cache@v4
188
233
with :
189
234
path : |
190
235
${{env.CCACHE_DIR}}
191
236
${{github.workspace}}/install
192
- key : ${{matrix.msvc}}-lapack-3.12.0-${{matrix.build_type}}
237
+ key : ${{matrix.msvc}}-${{matrix.arch}}- lapack-3.12.0-${{matrix.build_type}}
193
238
194
239
- name : Download LAPACK
195
240
if : steps.cache-lapack.outputs.cache-hit != 'true'
@@ -198,10 +243,28 @@ jobs:
198
243
wget https://github.com/Reference-LAPACK/lapack/archive/refs/tags/v3.12.0.tar.gz
199
244
tar xvf v3.12.0.tar.gz
200
245
201
- - name : Build LAPACK
202
- if : steps.cache-lapack.outputs.cache-hit != 'true'
246
+ - name : Build LAPACK (x86_64)
247
+ if : matrix.arch == 'x64' && steps.cache-lapack.outputs.cache-hit != 'true'
248
+ shell : msys2 {0}
249
+ run : |
250
+ cmake -S lapack-3.12.0 -B build_lapack_${{matrix.build_type}}/ \
251
+ -DBUILD_SHARED_LIBS=ON \
252
+ -DCMAKE_BUILD_TYPE=${{matrix.build_type}} \
253
+ -DCMAKE_C_COMPILER_LAUNCHER:FILEPATH=$(which ccache) \
254
+ -DCMAKE_Fortran_COMPILER_LAUNCHER:FILEPATH=$(which ccache) \
255
+ -DCMAKE_GNUtoMS=ON \
256
+ -DCMAKE_INSTALL_PREFIX=./install \
257
+ -G Ninja
258
+
259
+ cmake --build build_lapack_${{matrix.build_type}}/ \
260
+ --config ${{matrix.build_type}} \
261
+ --target install
262
+
263
+ - name : Build LAPACK (aarch64)
264
+ if : matrix.arch == 'arm64' && steps.cache-lapack.outputs.cache-hit != 'true'
203
265
shell : msys2 {0}
204
266
run : |
267
+ cat ./cmake/Flang.cmake >> lapack-3.12.0/CMakeLists.txt
205
268
cmake -S lapack-3.12.0 -B build_lapack_${{matrix.build_type}}/ \
206
269
-DBUILD_SHARED_LIBS=ON \
207
270
-DCMAKE_BUILD_TYPE=${{matrix.build_type}} \
@@ -229,7 +292,7 @@ jobs:
229
292
- name : Configure
230
293
run : |
231
294
cmake -S . -B build_${{matrix.build_type}}/ `
232
- -A x64 `
295
+ -A ${{matrix.arch}} `
233
296
-DBLAS_blas_LIBRARY=${{github.workspace}}/install/lib/libblas.lib `
234
297
-DBUILD_SHARED_LIBS=${{matrix.lib == 'shared'}} `
235
298
-DCMAKE_Fortran_COMPILER= `
0 commit comments