-
Notifications
You must be signed in to change notification settings - Fork 0
132 lines (109 loc) · 3.17 KB
/
fpm.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
name: fpm
on: [push, pull_request]
jobs:
gcc-build:
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
os: [ubuntu-latest]
gcc_v: [12] # Version of GFortran we want to use.
include:
- os: ubuntu-latest
os-arch: linux-x86_64
env:
FC: gfortran
GCC_V: ${{ matrix.gcc_v }}
steps:
- name: Checkout code
uses: actions/checkout@v1
- name: Install GFortran Linux
if: contains(matrix.os, 'ubuntu')
run: |
sudo update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-${GCC_V} 100 \
--slave /usr/bin/gfortran gfortran /usr/bin/gfortran-${GCC_V} \
--slave /usr/bin/gcov gcov /usr/bin/gcov-${GCC_V}
- name: Install BLAS & LAPACK
if: contains(matrix.os, 'ubuntu')
run: |
sudo apt-get update
sudo apt-get install libopenblas-dev liblapack-dev
- name: Install fpm
uses: fortran-lang/setup-fpm@v5
with:
fpm-version: 'v0.10.1'
- name: Build LINALG
run: |
gfortran --version
fpm build
- name: Run tests
run: |
gfortran --version
fpm test
msys2-build:
runs-on: windows-latest
defaults:
run:
shell: msys2 {0}
steps:
- uses: actions/checkout@v2
- uses: msys2/setup-msys2@v2
with:
msystem: MINGW64
update: true
path-type: inherit
install: |
mingw-w64-x86_64-gcc-fortran
mingw-w64-x86_64-fpm
mingw-w64-x86_64-openblas
mingw-w64-x86_64-lapack
- name: fpm build
run: |
gfortran --version
fpm --version
fpm build
- name: fpm test
run: |
fpm test
# intel-build:
# runs-on: ubuntu-latest
# strategy:
# fail-fast: false
# env:
# FPM_FC: ifx
# FC: ifx
# steps:
# - name: Checkout code
# uses: actions/checkout@v3
# - name: Add Intel repository (Linux)
# run: |
# wget https://apt.repos.intel.com/intel-gpg-keys/GPG-PUB-KEY-INTEL-SW-PRODUCTS-2023.PUB
# sudo apt-key add GPG-PUB-KEY-INTEL-SW-PRODUCTS-2023.PUB
# rm GPG-PUB-KEY-INTEL-SW-PRODUCTS-2023.PUB
# echo "deb https://apt.repos.intel.com/oneapi all main" | sudo tee /etc/apt/sources.list.d/oneAPI.list
# sudo apt-get update
# - name: Install Intel oneAPI compiler (Linux)
# run: |
# sudo apt-get install intel-oneapi-compiler-fortran
# - name: Setup Intel oneAPI environment
# run: |
# source /opt/intel/oneapi/setvars.sh
# printenv >> $GITHUB_ENV
# - name: Install MKL
# run: |
# sudo apt-get update
# sudo apt-get -y install intel-mkl
# sudo apt update
# sudo apt -y install intel-mkl
# - name: Install fpm
# uses: fortran-lang/setup-fpm@v3
# with:
# fpm-version: 'v0.8.2'
# - name: fpm build
# run: |
# ifx --version
# fpm --version
# fpm build --profile debug --flag "-warn nointerfaces"
# - name: fpm test
# run: |
# fpm test --profile debug --flag "-warn nointerfaces"