Skip to content

Commit e55e042

Browse files
committed
Add windows testing in CI
1 parent ba417f5 commit e55e042

File tree

1 file changed

+67
-0
lines changed

1 file changed

+67
-0
lines changed

.github/workflows/win-ci.yml

Lines changed: 67 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,67 @@
1+
name: CI
2+
3+
on: [push, pull_request]
4+
5+
jobs:
6+
Build:
7+
runs-on: windows-latest
8+
strategy:
9+
fail-fast: true
10+
defaults:
11+
run:
12+
shell: msys2 {0}
13+
14+
env:
15+
FC: gfortran
16+
CC: gcc
17+
18+
steps:
19+
- name: Checkout code
20+
uses: actions/checkout@v2
21+
22+
- name: Install Dependencies
23+
uses: msys2/setup-msys2@v2
24+
with:
25+
update: true
26+
path-type: inherit
27+
install: >-
28+
mingw-w64-x86_64-gcc-fortran mingw-w64-x86_64-gcc mingw-w64-x86_64-wget
29+
30+
- name: setup-mpi
31+
id: setup-mpi
32+
uses: mpi4py/setup-mpi@v1
33+
with:
34+
mpi: intelmpi
35+
36+
- name: MPI info
37+
run: |
38+
echo "${{ steps.setup-mpi.outputs.mpi }}"
39+
mpiexec -help
40+
type mpiexec
41+
ls "${I_MPI_ROOT}/bin"
42+
ls "${I_MPI_ROOT}"
43+
ls "${I_MPI_ROOT}/lib"
44+
mpifc.bat -show
45+
mpicc.bat -show
46+
mpifc.bat -version || echo "ifort not installed"
47+
mpicc.bat -version || echo "icc not installed"
48+
49+
- name: Build and Test
50+
run: |
51+
mkdir build
52+
cmake -Wdev -G "Unix Makefiles" -S . -B build -DCMAKE_INSTALL_PREFIX="${HOME}/apps/OpenCoarrays" -DCMAKE_BUILD_TYPE:STRING="Debug"
53+
cmake --build build -j
54+
cmake --build -t install -j || echo "installation failed"
55+
cd build
56+
ctest --output-on-failure --schedule-random --repeat-until-fail 1 --timeout 200
57+
cd ..
58+
echo "${HOME}/apps/OpenCoarrays/bin" >> $GITHUB_PATH
59+
export PATH="${HOME}/apps/OpenCoarrays/bin:${PATH}"
60+
which caf || true
61+
which cafrun || true
62+
cafrun --show || true
63+
caf --show || true
64+
cafrun --version || true
65+
caf --version || true
66+
cd build
67+
make uninstall

0 commit comments

Comments
 (0)