Skip to content

Commit 53f9083

Browse files
main.yml: add GCC 14 testing
1 parent fb27154 commit 53f9083

File tree

1 file changed

+13
-5
lines changed

1 file changed

+13
-5
lines changed

.github/workflows/main.yml

Lines changed: 13 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -3,13 +3,21 @@ on: [push, pull_request]
33

44
jobs:
55
build:
6-
runs-on: ubuntu-latest
7-
env:
8-
FC: gfortran-11
9-
CC: gcc-11
6+
runs-on: ubuntu-24.04
7+
strategy:
8+
matrix:
9+
gcc-version: [12,14]
1010

1111
steps:
1212

13+
- name: get-gcc
14+
run: |
15+
if [ -z $(type -P ${{ matrix.gcc-version }}) ]; then
16+
sudo apt-get install gcc-${{ matrix.gcc-version }} gfortran-${{ matrix.gcc-version }}
17+
fi
18+
echo "CC=gcc-${{ matrix.gcc-version }}" >> $GITHUB_ENV
19+
echo "FC=gfortran-${{ matrix.gcc-version }}" >> $GITHUB_ENV
20+
1321
- name: checkout-pfunit
1422
uses: actions/checkout@v4
1523
with:
@@ -21,7 +29,7 @@ jobs:
2129
uses: actions/cache@v4
2230
with:
2331
path: ~/pfunit
24-
key: pfunit-${{ runner.os }}-${{ hashFiles('pfunit/VERSION') }}
32+
key: pfunit-${{ runner.os }}-${{ hashFiles('pfunit/VERSION') }}-gcc${{ matrix.gcc-version }}
2533

2634
- name: build-pfunit
2735
if: steps.cache-pfunit.outputs.cache-hit != 'true'

0 commit comments

Comments
 (0)