1- name : ParFlow MacOS CI Test
1+ name : MacOS CI Tests
22
33#
44# Notes
55# Currently using GCC for the build rather than Clang
6- # Python 3.12 used rather than more current available versions since Numba library does not work with later versions
6+ # Python 3.13 used rather than more current available versions since Numba library does not work with later versions
77
88on : [push, pull_request]
99
10+ concurrency :
11+ group : ${{ github.workflow }}-${{ github.ref }}
12+ cancel-in-progress : true
13+
1014jobs :
1115 build :
1216 name : ${{ matrix.config.name }}
2731
2832 steps :
2933 - uses : actions/checkout@v4
34+
3035 - uses : actions/setup-python@v5
3136 with :
32- python-version : ' 3.12 '
37+ python-version : ' 3.13 '
3338 - uses : fortran-lang/setup-fortran@v1
3439 with :
3540 compiler : gcc
4550 run : |
4651 brew link tcl-tk@8
4752
48- # Cache dependencies so don't have to rebuild on each test.
49- # Can flush caches by resetting the CACHE_VERSION secret on GitHub
50- # settings for the project (using date-timestamp for secret).
51-
5253 - name : Cache dependencies
5354 uses : actions/cache@v4
5455 id : cache-parflow-dependencies
5758 cache-parflow-hit : ${{steps.cache-parflow-dependencies.outputs.cache-hit}}
5859 with :
5960 path : " ~/depend"
60- key : cache-${{ matrix.config.os }}-${{ matrix.config.backend }}-${{ secrets.CACHE_VERSION }}
61+ key : cache-${{ matrix.config.os }}-${{ matrix.config.backend }}-${{ hashfiles('**/.github/workflows/macos.yml') }}
6162
6263 - name : Directory Setup
6364 run : |
7172 echo "$HOME/depend/bin" >> $GITHUB_PATH
7273 export LD_LIBRARY_PATH=${PARFLOW_DEP_DIR}/lib64:${PARFLOW_DEP_DIR}/lib:${LD_LIBRARY_PATH}
7374 echo "LD_LIBRARY_PATH=${LD_LIBRARY_PATH}" >> $GITHUB_ENV
74- export PARFLOW_PYTHON3=/opt/homebrew/bin/python3.12
75+ export PARFLOW_PYTHON3=/opt/homebrew/bin/python3.13
7576 echo "PARFLOW_PYTHON3=${PARFLOW_PYTHON3}" >> $GITHUB_ENV
77+ echo "Python version:"
78+ $PARFLOW_PYTHON3 --version
7679
7780 - name : CMake Install
7881 if : matrix.config.os != 'macos-14'
8285 if [[ "$CACHE_HIT" != 'true' ]]; then
8386 echo "Installing"
8487 cd ~/depend
85- echo "cache-${{ matrix.config.os }}-${{ matrix.config.backend }}-${{ secrets.CACHE_VERSION }}" > ~/depend/cache-key
88+ echo "cache-${{ matrix.config.os }}-${{ matrix.config.backend }}-${{ hashfiles('**/.github/workflows/macos.yml') }}" > ~/depend/cache-key
8689 wget -nv --no-check-certificate https://github.com/Kitware/CMake/releases/download/v3.25.1/cmake-3.25.1-linux-x86_64.tar.gz
8790 tar -xf cmake-3.25.1-linux-x86_64.tar.gz
8891 $HOME/depend/cmake-3.25.1-linux-x86_64/bin/cmake --version
@@ -102,7 +105,7 @@ jobs:
102105 cd netcdf-c
103106 curl -L $URL | tar --strip-components=1 -xz
104107 CC=mpicc CPPFLAGS=-I/opt/homebrew/include LDFLAGS=-L/opt/homebrew/lib/ ./configure --prefix=$PARFLOW_DEP_DIR
105- make
108+ make -j 3
106109 make install
107110 cd ..
108111
@@ -111,7 +114,7 @@ jobs:
111114 cd netcdf-fortran
112115 curl -L $URL | tar --strip-components=1 -xz
113116 CC=mpicc FC=mpifort CPPFLAGS=-I${PARFLOW_DEP_DIR}/include LDFLAGS=-L${PARFLOW_DEP_DIR}/lib ./configure --prefix=${PARFLOW_DEP_DIR}
114- make
117+ make -j 3
115118 make install
116119 fi
117120 echo "NETCDF_FLAGS=-DNETCDF_DIR=$PARFLOW_DEP_DIR -DPARFLOW_ENABLE_HDF5=TRUE" >> $GITHUB_ENV
@@ -121,26 +124,26 @@ jobs:
121124 CACHE_HIT : ${{steps.cache-parflow-dependencies.outputs.cache-hit}}
122125 run : |
123126 if [[ "$CACHE_HIT" != 'true' ]]; then
124- URL=https://github.com/LLNL/Silo/archive/refs/tags/4.11 .tar.gz
127+ URL=https://github.com/LLNL/Silo/archive/refs/tags/4.12.0 .tar.gz
125128 mkdir silo
126129 cd silo
127130 curl -L $URL | tar --strip-components=1 -xz
128- ./configure --disable-silex --disable-hzip --disable-fpzip --prefix=$PARFLOW_DEP_DIR --disable-fortran --with-readline=no
129- make -j 2 install
131+ ./configure --disable-silex --disable-hzip --disable-fpzip --enable-shared=yes --disable-fortran --with-readline=no --prefix=$PARFLOW_DEP_DIR
132+ make -j 3 install
130133 fi
131134
132135 - name : HYPRE Install
133136 env :
134137 CACHE_HIT : ${{steps.cache-parflow-dependencies.outputs.cache-hit}}
135138 run : |
136139 if [[ "$CACHE_HIT" != 'true' ]]; then
137- URL=https://github.com/hypre-space/hypre/archive/v2.26 .0.tar.gz
140+ URL=https://github.com/hypre-space/hypre/archive/v2.33 .0.tar.gz
138141 mkdir hypre
139142 cd hypre
140143 curl -L $URL | tar --strip-components=1 -xz
141144 cd src
142145 CC=mpicc CXX=mpic++ FC=mpif77 F77=mpif90 ./configure --prefix=$PARFLOW_DEP_DIR
143- make -j 2 install
146+ make -j 3 install
144147 fi
145148
146149 - name : ParFlow CMake Configure
@@ -152,7 +155,7 @@ jobs:
152155 CC=mpicc CXX=mpicxx F77=mpif77 FC=mpif90 cmake -Bbuild -DCMAKE_BUILD_TYPE=Release -DCMAKE_C_FLAGS="-Wall -Werror -Wno-unused-result -Wno-unused-function" -DPARFLOW_ENABLE_TIMING=TRUE -DPARFLOW_AMPS_LAYER=${{ matrix.config.amps_layer }} -DPARFLOW_ACCELERATOR_BACKEND=${{ matrix.config.backend }} -DPARFLOW_AMPS_SEQUENTIAL_IO=true -DPARFLOW_HAVE_CLM=${HAVE_CLM} -DHYPRE_ROOT=$PARFLOW_DEP_DIR -DOAS3_ROOT=$PARFLOW_DEP_DIR -DSILO_ROOT=$PARFLOW_DEP_DIR -DPARFLOW_ENABLE_PYTHON=${{ matrix.config.python }} $NETCDF_FLAGS $KOKKOS_FLAGS $RMM_FLAGS -DCMAKE_INSTALL_PREFIX=$PARFLOW_DIR -DTCL_INCLUDE_PATH=/opt/homebrew/bin/usr/include -DTCL_LIBRARY=/opt/homebrew/lib/libtcl8.6.dylib -DTCL_TCLSH=/opt/homebrew/bin/tclsh8.6 -DPython3_EXECUTABLE=$PARFLOW_PYTHON3
153156
154157 - name : ParFlow CMake Build
155- run : (cd build; make -j 2 VERBOSE=1 install)
158+ run : (cd build; make -j 3 VERBOSE=1 install)
156159
157160 # Can't test with GPU since have no GPU hardware on testing nodes, GPU test is build only
158161 - name : ParFlow CTest
0 commit comments