I’m trying to compile HDF5 1.14.0 on a RedHat Linux Enterprise box with intel compilers, and I get the following error at the ‘make’ stage:
dsets.cpp(1100): error: class "H5::DataSet" has no member "getNativeObjinfo"
dataset.getNativeObjinfo(ninfo, H5O_NATIVE_INFO_HDR);
^
dsets.cpp(1108): error: class "H5::DataSet" has no member "getNativeObjinfo"
dataset.getNativeObjinfo(ninfo, H5O_NATIVE_INFO_ALL);
Yes, that’s the only error it is giving me. I just tried it again, and it barfed again on the same error. I’m uploading config.log here in case that helps.
I downloaded the CMake-hdf5 package following instructions here, but that only provides HDF5 1.10. I am hoping to use a more recent version. The HDF5 I tried building, which failed, was 1.14.0.
I don’t in fact need the C++ API, so I left it out as you suggested. Now I get a different set of errors
In file included from test_lite.c(15):
/home/sbasu1/packages/include/H5LTpublic.h(26): error: invalid redefinition of enum "H5LT_lang_t" (declared at line 25 of "../../hl/src/H5LTpublic.h")
typedef enum H5LT_lang_t {
^
In file included from test_lite.c(15):
/home/sbasu1/packages/include/H5LTpublic.h(27): error: "H5LT_LANG_ERR" has already been declared in the current scope
H5LT_LANG_ERR = -1, /*this is the first*/
^
In file included from test_lite.c(15):
/home/sbasu1/packages/include/H5LTpublic.h(28): error: "H5LT_DDL" has already been declared in the current scope
H5LT_DDL = 0, /*for DDL*/
^
In file included from test_lite.c(15):
/home/sbasu1/packages/include/H5LTpublic.h(29): error: "H5LT_C" has already been declared in the current scope
H5LT_C = 1, /*for C*/
^
In file included from test_lite.c(15):
/home/sbasu1/packages/include/H5LTpublic.h(30): error: "H5LT_FORTRAN" has already been declared in the current scope
H5LT_FORTRAN = 2, /*for Fortran*/
^
In file included from test_lite.c(15):
/home/sbasu1/packages/include/H5LTpublic.h(31): error: "H5LT_NO_LANG" has already been declared in the current scope
H5LT_NO_LANG = 3 /*this is the last*/
^
In file included from test_lite.c(15):
/home/sbasu1/packages/include/H5LTpublic.h(32): error: invalid redeclaration of type name "H5LT_lang_t" (declared at line 31 of "../../hl/src/H5LTpublic.h")
} H5LT_lang_t;
^
compilation aborted for test_lite.c (code 2)
make[2]: *** [Makefile:1038: test_lite.o] Error 2
I’ve snipped out a few warning messages that also came up, to just show the errors.
I think I’ve successfully built HDF5 using cmake with build-unix.sh, but I’m not entirely sure what all has been done. I can see that the binaries and shared libraries have not been copied into INSTALLDIR. So what’s the analogous step to ‘make install’ here?
The process breakdown is:
the build-unix runs one command “ctest -S HDF5config.cmake,BUILD_GENERATOR=Unix -C Release -V -O hdf5.log”
The ctest script that is run, HDF5config.cmake has arguments separated by a comma in the form OPTION=VALUE. See the HDF5config.cmake file. INSTALLDIR is one of the options.
More options can be set/unset in the HDF5options.cmake file which can set any HDF5 cmake or ctest script (CTestScript.cmake) options.
The ctest script will do a configure, build, test, package sequence. The result will be, for linux, a *.sh and *.tar.gz file. The *.sh file is a compressed installer with a script. The *.tar.gz file is just a folder snapshot of the installation. both expect to be uncompressed in your intended INSTALLDIR location.
The build folder is just all the build files to produce those two “binaries”.