Lightweight HDF5 polymorphic Fortran: h5write() h5read()
Thanks @milancurcic for idea to implement FPM
General cleanup of CMake scripts.
Intel compiler: don't specify xHost flag as some systems shouldn't use them. Let the user decide.
HDF5 1.12.2 is the default version built by the script if the user chooses.
Specify script HDF5 version to build by Git tag for simplicity.
HDF5 string character data is handled more broadly and robustly including:
The common annoyance of a non-existing HDF5 file is handled with a succinct error message now.
fixes #26
Thanks @gekowa
HDF5 no longer autobuilds. This caused confusion in some cases, so we instead emit an error message with how to build HDF5 if necessary.
fix long-standing stability bug that I had used workaround code to get rid of before, but now I fixed the root cause by explicit dimensions for slice parameters
remove ierr optional from %open() as with other methods
FindHDF5: scope FindMPI correctly, fixes false MPI-HDF5 link fail
Add hdf5version() query function
h5fortran can now query data "%class" e.g. integer, float, string as well as the native datatype "%dtype"
Dataset "dname" data class (i.e. integer, float, string, ...)
integer :: class
!! H5T_INTEGER_F, H5T_FLOAT_F, H5T_STRING_F
class = h%class(dname)
character(*), intent(in) :: dname
Dataset "dname" datatype
integer(HID_T) :: dtype
!! H5T_NATIVE_REAL, H5T_NATIVE_DOUBLE, H5T_NATIVE_INTEGER, H5T_NATIVE_CHARACTER, H5T_STD_I64LE
dtype = h%dtype(dname)
character(*), intent(in) :: dname
The optional "ierr" argument was not well tested and in almost every case did nothing. It was a source of user confusion and excess internal untested code, so we removed it from all functions except "%open".
We also used "select type" to eliminate hundreds of lines of code, for better code quality.