-
Notifications
You must be signed in to change notification settings - Fork 173
90 lines (78 loc) · 2.37 KB
/
ci_windows.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
name: CI_windows
on: [push, pull_request]
env:
CTEST_TIME_TIMEOUT: "5" # some failures hang forever
CMAKE_GENERATOR: Ninja
jobs:
msys2-build:
runs-on: windows-latest
strategy:
fail-fast: false
matrix:
include: [
{ msystem: MSYS, arch: x86_64 },
{ msystem: MINGW64, arch: x86_64 },
{ msystem: MINGW32, arch: i686 }
]
defaults:
run:
shell: msys2 {0}
steps:
- uses: actions/checkout@v2
- name: Setup MinGW native environment
uses: msys2/setup-msys2@v2
if: contains(matrix.msystem, 'MINGW')
with:
msystem: ${{ matrix.msystem }}
update: false
install: >-
git
mingw-w64-${{ matrix.arch }}-gcc
mingw-w64-${{ matrix.arch }}-gcc-fortran
mingw-w64-${{ matrix.arch }}-python
mingw-w64-${{ matrix.arch }}-python-pip
mingw-w64-${{ matrix.arch }}-python-setuptools
mingw-w64-${{ matrix.arch }}-cmake
mingw-w64-${{ matrix.arch }}-ninja
- name: Setup msys POSIX environment
uses: msys2/setup-msys2@v2
if: contains(matrix.msystem, 'MSYS')
with:
msystem: MSYS
update: false
install: >-
git
mingw-w64-x86_64-gcc
mingw-w64-x86_64-gcc-fortran
python
python-pip
cmake
ninja
- name: Install fypp
run: pip install fypp
- run: >-
PATH=$PATH:/mingw64/bin/ cmake
-Wdev
-B build
-DCMAKE_BUILD_TYPE=Debug
-DCMAKE_Fortran_FLAGS_DEBUG="-Wall -Wextra -Wimplicit-interface -fPIC -g -fcheck=all -fbacktrace"
-DCMAKE_MAXIMUM_RANK:String=4
-DCMAKE_INSTALL_PREFIX=$PWD/_dist
env:
FC: gfortran
CC: gcc
CXX: g++
- name: CMake build
run: PATH=$PATH:/mingw64/bin/ cmake --build build --parallel
- name: catch build fail
run: PATH=$PATH:/mingw64/bin/ cmake --build build --verbose --parallel 1
if: failure()
- name: CTest
run: PATH=$PATH:/mingw64/bin/ ctest --test-dir build --output-on-failure --parallel -V -LE quadruple_precision
- uses: actions/upload-artifact@v1
if: failure()
with:
name: WindowsCMakeTestlog
path: build/Testing/Temporary/LastTest.log
- name: Install project
run: PATH=$PATH:/mingw64/bin/ cmake --install build