-
Notifications
You must be signed in to change notification settings - Fork 9
49 lines (43 loc) · 1.31 KB
/
MacOS.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
# This is a CI workflow for the NCEPLIBS-ip project.
#
# This workflow builds on MacOS with different options.
#
# Ed Hartnett, 1/8/23
name: MacOS
on:
push:
branches:
- develop
pull_request:
branches:
- develop
jobs:
MacOS:
runs-on: macos-latest
env:
FC: gfortran-12
CC: gcc-12
strategy:
matrix:
openmp: [ ON, OFF ]
sharedlibs: [ON, OFF]
steps:
- name: checkout
uses: actions/checkout@v4
with:
path: ip
- name: Cache test files
uses: actions/cache@v4
with:
path: testfiles.tgz
key: NCEPLIBS-ip-test-files-1
- name: build
run: |
if [ ! -f testfiles.tgz ]; then wget https://ftp.emc.ncep.noaa.gov/static_files/public/NCEPLIBS-ip/ip-test-data-20241230.tgz -O testfiles.tgz ; fi
cmake -S ip -B ip/build -DOPENMP=${{ matrix.openmp }} -DBUILD_SHARED_LIBS=${{ matrix.sharedlibs }} -DCMAKE_INSTALL_PREFIX=~/install -DBUILD_8=ON -DCMAKE_BUILD_TYPE=Debug -DFTP_TEST_FILES=ON -DTEST_FILES_CACHE=$GITHUB_WORKSPACE/testfiles.tgz
cmake --build ip/build --parallel 2 --verbose
cmake --install ip/build
ls -l ~/install
ls -l ~/install/lib
- name: test
run: ctest --test-dir ip/build --parallel 2 --verbose --output-on-failure --rerun-failed