Skip to content

temp patched hdf5 v2.1.0 #832

temp patched hdf5 v2.1.0

temp patched hdf5 v2.1.0 #832

Workflow file for this run

name: ci
env:
HOMEBREW_NO_INSTALL_CLEANUP: 1
CTEST_NO_TESTS_ACTION: error
CTEST_PARALLEL_LEVEL: 0
CMAKE_INSTALL_PREFIX: ~/libs
CMAKE_PREFIX_PATH: ~/libs
CMAKE_GENERATOR: Ninja
on:
push:
paths:
- "**.c"
- "**.cpp"
- "**.f90"
- "**.F90"
- "**/CMakeLists.txt"
- "**.cmake"
- ".github/workflows/**"
- "!memcheck.cmake"
- "!coverage.cmake"
workflow_dispatch:
# avoid wasted runs
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
jobs:
build-unix:
timeout-minutes: 15
strategy:
matrix:
os: [ubuntu-24.04, macos-latest]
runs-on: ${{ matrix.os }}
steps:
- &checkout
uses: actions/checkout@v6
- name: GCC (macOS)
if: runner.os == 'macos'
run: |
echo "CC=gcc-15" >> $GITHUB_ENV
echo "FC=gfortran-15" >> $GITHUB_ENV
- name: Build HDF5, h5fortran and test h5fortran
run: cmake --workflow default
- name: install package
run: cmake --install build
- name: example workflow
working-directory: example
run: cmake --workflow default
gcc-new:
timeout-minutes: 15
strategy:
matrix:
os: [ubuntu-24.04]
gcc: [12, 13, 14]
include:
- os: macos-latest
gcc: 15
runs-on: ${{ matrix.os }}
env:
FC: gfortran-${{ matrix.gcc }}
steps:
- &checkout
uses: actions/checkout@v6
- name: GCC (Linux)
if: runner.os == 'Linux'
run: echo "CC=gcc-${{ matrix.gcc }}" >> $GITHUB_ENV
- &pkg
uses: ./.github/workflows/composite-pkg
- &unix
uses: ./.github/workflows/composite-unix
shared:
runs-on: ${{ matrix.os }}
timeout-minutes: 15
strategy:
matrix:
os: [ubuntu-latest, macos-latest]
env:
CC: gcc-14
FC: gfortran-14
steps:
- *checkout
- name: Build shared library
run: cmake --workflow shared
- name: install package
run: cmake --install build-shared
- name: example workflow
working-directory: example
run: cmake --workflow default
gcc-old:
timeout-minutes: 15
strategy:
matrix:
gcc: [9, 10, 11]
runs-on: ubuntu-22.04
env:
CC: gcc-${{ matrix.gcc }}
FC: gfortran-${{ matrix.gcc }}
steps:
- *checkout
- name: GCC APT
if: matrix.gcc < 11
run: |
sudo apt update -y
sudo apt install -y --no-install-recommends gcc-${{ matrix.gcc }} g++-${{ matrix.gcc }} gfortran-${{ matrix.gcc }}
- *pkg
- *unix
linux-flang:
runs-on: ubuntu-latest
timeout-minutes: 15
strategy:
matrix:
llvm-version: [21]
env:
CC: clang-${{ matrix.llvm-version }}
CXX: clang++-${{ matrix.llvm-version }}
FC: flang-${{ matrix.llvm-version }}
steps:
- name: Apt LLVM
run: |
wget https://apt.llvm.org/llvm.sh
chmod +x llvm.sh
sudo ./llvm.sh ${{ matrix.llvm-version }}
sudo apt-get update
- name: install Flang
run: sudo apt install --no-install-recommends clang-${{ matrix.llvm-version }} flang-${{ matrix.llvm-version }}
- *checkout
- name: CMake build & test
run: cmake --workflow nofind
# not a meaningful need for this in a pure fortran program
valgrind-memory:
if: false
runs-on: ubuntu-latest
needs: gcc-new
timeout-minutes: 10
steps:
- name: install valgrind
run: |
sudo apt update
sudo apt install --no-install-recommends valgrind libhdf5-dev
- *checkout
- run: ctest -Dexclude_label="deflate|python" -S memcheck.cmake -VV
# issue with python loading writer.inc
linux-coverage:
if: false
needs: gcc-new
runs-on: ubuntu-latest
timeout-minutes: 10
steps:
- *checkout
- uses: actions/setup-python@v6
with:
python-version: '3.x'
- name: install hdf5
run: |
sudo apt update
sudo apt install --no-install-recommends libhdf5-dev
- name: install Gcovr
run: pip install gcovr
- run: cmake --preset coverage
- run: cmake --build --parallel --preset coverage
- name: Code coverage
run: cmake --build --parallel --preset run-coverage
- uses: actions/upload-artifact@v6
with:
name: coverage-report-html
path: build-coverage/coverage/
cmake-older:
timeout-minutes: 30
runs-on: ubuntu-latest
strategy:
matrix:
cmake_version: ["3.21.7"]
steps:
- *checkout
- name: prereqs
run: |
sudo apt-get update
sudo apt install --no-install-recommends libhdf5-dev
- uses: ./.github/workflows/composite-cmake
- name: configure
run: $CMAKE -Bbuild -DCMAKE_INSTALL_PREFIX:PATH=${{ github.workspace }}/build/local
- name: build
run: $CMAKE --build build
- name: test
run: $CTEST --test-dir build
- name: install package
run: $CMAKE --install build
- name: example workflow
run: cmake -S example -B example/build -DCMAKE_PREFIX_PATH=${{ github.workspace }}/build/local
- name: Build examples
run: cmake --build example/build
- name: Test examples
run: ctest --test-dir example/build -V