Skip to content

Add cmake workaround for hdf5 version detection when using hdf5 with subversion #26

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Jul 29, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 2 additions & 4 deletions c++/h5/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -30,10 +30,8 @@ find_package(HDF5 REQUIRED C HL)

# Link against interface target and export
target_link_libraries(h5_c PRIVATE hdf5::hdf5 hdf5::hdf5_hl)
if(HDF5_VERSION VERSION_GREATER 1.10)
target_compile_definitions(h5_c PRIVATE H5_USE_110_API)
endif()
if(HDF5_VERSION VERSION_GREATER_EQUAL 1.13)
target_compile_definitions(h5_c PRIVATE H5_USE_110_API)
if(HDF5_VERSION VERSION_GREATER_EQUAL 1.13 OR NOT HDF5_VERSION)
target_compile_definitions(h5_c PRIVATE H5_VER_GE_113)
endif()

Expand Down
Loading