Build failure of 1.10.2-snap10 with CMake

With the following CMake command:

eval CC=mpicc CXX= FC=mpif90 cmake \
-DCMAKE_INSTALL_PREFIX=/home/greenc/work/cet-is/test-products/hdf5/v1_10_2_snap10/Linux64bit+3.10-2.17-e17-mpich-prof \
-DHDF5_BUILD_CPP_LIB:BOOL=OFF -DHDF5_BUILD_FORTRAN:BOOL=ON \
-DHDF5_ENABLE_PARLLEL:BOOL=ON -DHDF5_ENABLE_Z_LIB_SUPPORT:BOOL=ON \
-DCMAKE_CXX_STANDARD=17 -DCMAKE_BUILD_TYPE=RelWithDebInfo \
/home/greenc/work/cet-is/test-products/hdf5/v1_10_2_snap10/source/hdf5-1.10.2-snap10

An attempt to build fails with:

/home/greenc/work/cet-is/test-products/hdf5/v1_10_2_snap10/build/Linux64bit+3.10-2.17-e17-mpich-prof/hl/fortran/src/static/H5LTff_gen.F90:32:6:

   USE H5LT_CONST
      1
Fatal Error: Can't open module file ‘h5lt_const.mod’ for reading at (1): No such file or directory
compilation terminated.
make[2]: *** [hl/fortran/src/CMakeFiles/hdf5_hl_fortran-static.dir/static/H5LTff_gen.F90.o] Error 1

This appears at first sight to be due to the fact that the HDF5 CMake-based build system puts module files in ${CMAKE_Fortran_MODULE_DIRECTORY}/(static|shared), but the default -I options configured by CMake look only in ${CMAKE_Fortran_MODULE_DIRECTORY} and not under it.

Is there some quick workaround to get me going here, or am I missing something?

Chris,
I created https://jira.hdfgroup.org/browse/HDFFV-10418 for this build failure. I have seen this happen occasionally, yet always on the same configuration and platform.

Thanks for this, but I appear to be unable to see this issue on your JIRA: is this a closed site, or something for which I might have a limited account to view this and other issues?

Unfortunately, our JIRA is not open to the public. We’re working on that, though.

Fair enough, thanks for the information.