Recently, I want to use QT to read a HDF5 file with C++, but I don not know how to configure the lib. I want to know the method to configure this.
You maybe interested in trying H5CPP a fresh approach to HDFGroup amazing HDF5 CAPI data container architecture for MODERN C++. H5CPP is a compiler assisted templates which supports arbitrary C POD through LLVM based compiler, saving you from the tedious work creating the shim for compound types. As for the rest: pure templates with cool syntactic sugar – parsed at compile time, much similar you see in python but much-much faster.
In order to get started all you need is to download the templates and link against the dependencies of hdf5 library:
-lhdf5 -lz -ldl -lm. See examples for details.
H5CPP has near complete coverage of the CAPI, all
hid_t descriptors are RAII wrapped and binary compatible with CAPI which allows you to pass H5CPP resources to relevant CAPI calls seamless fashion, and most importantly without loss of performance.
H5CPP supports major linear algebra systems, stl::vector, raw memory and many more… You can read on the origins in this HDFGroup feautures blog post has been presented in Chicago C++ usergroup: as general persistence solution for C++.
hope it helps,