Skip to content

[pre-commit.ci] pre-commit autoupdate #16

[pre-commit.ci] pre-commit autoupdate

[pre-commit.ci] pre-commit autoupdate #16

Workflow file for this run

---
name: Testing on macOS
on:
push:
branches:
- 'develop'
pull_request:
# Workaround issue in Xcode 14.1/2
env:
DEVELOPER_DIR: /Applications/Xcode_14.0.1.app/Contents/Developer
jobs:
build-and-test:
runs-on: macos-latest
strategy:
matrix:
use_mpi: [MPI=ON]
use_openmp: [OPENMP=ON]
use_smm: [SMM=blas]
blas_impl: [accelerate,openblas]
mpi_suffix: [openmpi]
exclude:
- use_mpi: MPI=OFF
mpi_suffix: mpich
steps:
- uses: actions/checkout@v3
with:
fetch-depth: 0
submodules: true
- name: Install common dependencies
run: |
env HOMEBREW_NO_AUTO_UPDATE=1 brew install \
ninja
- name: Install ${{ matrix.mpi_suffix }}
run: |
env HOMEBREW_NO_AUTO_UPDATE=1 brew install ${{ matrix.mpi_suffix }}
- name: Configure
run: |
mkdir -p build
cd build
env \
CC=gcc-11 CXX=g++-11 FC=gfortran-11 \
cmake -G Ninja \
-DCMAKE_BUILD_TYPE=Debug \
-DUSE_${{ matrix.use_mpi }} \
-DUSE_${{ matrix.use_openmp }} \
-DUSE_${{ matrix.use_smm }} \
$([ "${{ matrix.blas_impl }}" = "openblas" ] && echo '-DCMAKE_PREFIX_PATH=/usr/local/opt/openblas') \
-DMPIEXEC_PREFLAGS="$([ "${{ matrix.mpi_suffix }}" = "openmpi" ] && echo "-mca btl ^openib --allow-run-as-root")" \
-DTEST_MPI_RANKS=1 \
..
- name: Build
run: cmake --build build -- --verbose
- name: Test
run: |
cd build
ctest --output-on-failure
# vim: set ts=2 sw=2 tw=0 :