-
Notifications
You must be signed in to change notification settings - Fork 7
52 lines (45 loc) · 1.32 KB
/
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
name: Build WEPP
on:
push:
branches: [ main ]
pull_request:
branches: [ main ]
jobs:
build:
name: Build
runs-on: ubuntu-latest
strategy:
matrix:
FC: ["ifx", "gfortran"]
steps:
- uses: actions/checkout@v4
- name: Install gfortran Compiler
if: ${{ matrix.FC == 'gfortran' }}
run: |
sudo apt-get update
sudo apt install gfortran-11
- name: Build WEPP with gfortran
if: ${{ matrix.FC == 'gfortran' }}
run: |
cd src/wepp20240930
make FC=gfortran
- name: Install Intel Compiler
if: ${{ matrix.FC == 'ifx' }}
run: |
wget https://apt.repos.intel.com/intel-gpg-keys/GPG-PUB-KEY-INTEL-SW-PRODUCTS.PUB
sudo apt-key add GPG-PUB-KEY-INTEL-SW-PRODUCTS.PUB
rm GPG-PUB-KEY-INTEL-SW-PRODUCTS.PUB
sudo echo "deb https://apt.repos.intel.com/oneapi all main" | sudo tee /etc/apt/sources.list.d/oneAPI.list
sudo apt-get update
sudo apt-get install -y intel-oneapi-compiler-fortran
- name: Build WEPP with Intel
if: ${{ matrix.FC == 'ifx' }}
run: |
source /opt/intel/oneapi/setvars.sh
cd src/wepp20240930
make
- name: Run Regression Tests
run: |
python -m pip install .
cd src/regression_tests
python run_regressions.py