Skip to content

1501 Add CMake option to allow building without HDF5#1502

Merged
reneSchm merged 5 commits intomainfrom
1501-Add-CMake-option-to-allow-building-without-HDF5
Mar 5, 2026
Merged

1501 Add CMake option to allow building without HDF5#1502
reneSchm merged 5 commits intomainfrom
1501-Add-CMake-option-to-allow-building-without-HDF5

Conversation

@HenrZu
Copy link
Copy Markdown
Contributor

@HenrZu HenrZu commented Mar 4, 2026

Changes and Information

Please briefly list the changes (main added features, changed items, or corrected bugs) made:

  • add MEMILIO_ENABLE_HDF5option to build without hdf5
  • Update Doc and new CI run

If need be, add additional information and what the reviewer should look out for in particular:

Merge Request - Guideline Checklist

Please check our git workflow. Use the draft feature if the Pull Request is not yet ready to review.

Checks by code author

  • Every addressed issue is linked (use the "Closes #ISSUE" keyword below)
  • New code adheres to coding guidelines
  • No large data files have been added (files should in sum not exceed 100 KB, avoid PDFs, Word docs, etc.)
  • Tests are added for new functionality and a local test run was successful (with and without OpenMP)
  • Appropriate documentation within the code (Doxygen) for new functionality has been added in the code
  • Appropriate external documentation (ReadTheDocs) for new functionality has been added to the online documentation
  • Proper attention to licenses, especially no new third-party software with conflicting license has been added
  • (For ABM development) Checked benchmark results and ran and posted a local test above from before and after development to ensure performance is monitored.

Checks by code reviewer(s)

  • Corresponding issue(s) is/are linked and addressed
  • Code is clean of development artifacts (no deactivated or commented code lines, no debugging printouts, etc.)
  • Appropriate unit tests have been added, CI passes, code coverage and performance is acceptable (did not decrease)
  • No large data files added in the whole history of commits(files should in sum not exceed 100 KB, avoid PDFs, Word docs, etc.)
  • On merge, add 2-5 lines with the changes (main added features, changed items, or corrected bugs) to the merge-commit-message. This can be taken from the briefly-list-the-changes above (best case) or the separate commit messages (worst case).

@HenrZu HenrZu linked an issue Mar 4, 2026 that may be closed by this pull request
2 tasks
@HenrZu HenrZu requested a review from reneSchm March 4, 2026 09:41
@codecov
Copy link
Copy Markdown

codecov bot commented Mar 4, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 97.36%. Comparing base (12db98b) to head (fa68e3d).
⚠️ Report is 2 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #1502      +/-   ##
==========================================
- Coverage   97.40%   97.36%   -0.04%     
==========================================
  Files         189      188       -1     
  Lines       16600    16539      -61     
==========================================
- Hits        16170    16104      -66     
- Misses        430      435       +5     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

Copy link
Copy Markdown
Member

@reneSchm reneSchm left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I am honestly surprised that we are using the HAS_HDF5 macro that consistently, I expected more changes in the cpp directory.

Do we need an extra build option, or should we just group hdf into the "optional-deps" category? I think the latter would suffice, as we only need to check that nothing uses hdf without the corresponding macro.

Comment thread cpp/README.md Outdated
Comment thread .github/actions/linux-build/action.yml Outdated
Comment thread cpp/thirdparty/CMakeLists.txt Outdated
@HenrZu
Copy link
Copy Markdown
Contributor Author

HenrZu commented Mar 4, 2026

In the current main, find_package(HDF5.. is always called, regardless of optional-deps. The flag only disables the installation in thee CI and sets MEMILIO_USE_BUNDLED_JSONCPP=OFF.
In my opinin, a separate MEMILIO_USE_HDF5 option would be cleaner, as we can specifically deactivate HDF5 without deactivating JsonCpp.

Comment thread .github/actions/linux-build/action.yml Outdated
Comment thread .github/actions/linux-test/action.yml Outdated
Comment thread cpp/README.md Outdated
Comment thread docs/source/cpp/installation.rst Outdated
Copy link
Copy Markdown
Member

@reneSchm reneSchm left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Very useful addition, thanks!

@reneSchm reneSchm merged commit 9877cb2 into main Mar 5, 2026
69 checks passed
@reneSchm reneSchm deleted the 1501-Add-CMake-option-to-allow-building-without-HDF5 branch March 5, 2026 11:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Add CMake option to allow building without HDF5

2 participants