LLNL / H5Z-ZFP

A registered ZFP compression plugin for HDF5
Other
50 stars 22 forks source link

Handle static-only HDF5 library #140

Open markcmiller86 opened 6 months ago

markcmiller86 commented 6 months ago

Resolves #137

jhendersonHDF commented 6 months ago

I thought a bit more about this PR. Since the 1.14.4 release of HDF5 will remove the "-shared" tools and link to the shared lib by default, I think the current check will be correct, but this also should first check if the "-shared" tool is present. If it is, either run the test with that or skip it (since the other-named tool will be statically linked). If it's not, then go ahead and perform the HDF5_IS_STATIC_ONLY check and skip the test if true. Another thing to take into account is that https://github.com/HDFGroup/hdf5/pull/4046 adds a new HDF5_BUILD_STATIC_TOOLS CMake option to keep the old behavior when both static and shared libs are built. I don't really know how to handle that case here other than either checking if that option is set in HDF5's cmake configuration files, or figuring out how to determine a tool was statically linked with HDF5.