CMake and autotools builds differences

Hi there,

I’m packaging HDF5 for ArchLinux, and I have discrepancies between autotools and CMake builds, both having issues that the other one does not. For now, let’s assume serial builds with both static and shared libs, cxx, fortran and hl being enabled. BTW, this would be my point number…

  1. There is no way to disable static libs in CMake builds.

  2. Files present in autotools build only:

/usr/bin/h5fc
/usr/bin/h5perf_serial
/usr/bin/h5redeploy
/usr/include/th5_misc_gen.mod
/usr/include/tstds.mod
/usr/include/tstds_tests.mod
/usr/include/tstimage.mod
/usr/include/tstimage_tests.mod
/usr/include/tstlite.mod
/usr/include/tstlite_tests.mod
/usr/include/tsttable.mod
/usr/include/tsttable_tests.mod
  • examples files.
  1. Files present in CMake build only:
/usr/bin/h5copy-shared
/usr/bin/h5diff-shared
/usr/bin/h5dump-shared
/usr/bin/h5ls-shared
/usr/bin/h5repack-shared
/usr/bin/h5stat-shared
/usr/bin/h5hlc++
/usr/bin/h5hlcc
/usr/include/H5ACpkg.h
/usr/include/H5Alltypes.h
/usr/include/H5Apkg.h
/usr/include/H5B2pkg.h
/usr/include/H5B2public.h
/usr/include/H5Bpkg.h
/usr/include/H5Bpublic.h
/usr/include/H5Cpkg.h
/usr/include/H5Dpkg.h
/usr/include/H5EApkg.h
/usr/include/H5Edefin.h
/usr/include/H5Einit.h
/usr/include/H5Epkg.h
/usr/include/H5Eterm.h
/usr/include/H5FApkg.h
/usr/include/H5FDpkg.h
/usr/include/H5FDwindows.h
/usr/include/H5FSpkg.h
/usr/include/H5FSpublic.h
/usr/include/H5Fpkg.h
/usr/include/H5Gpkg.h
/usr/include/H5HFpkg.h
/usr/include/H5HFpublic.h
/usr/include/H5HGpkg.h
/usr/include/H5HGpublic.h
/usr/include/H5HLpkg.h
/usr/include/H5HLpublic.h
/usr/include/H5Ipkg.h
/usr/include/H5LTparse.h
/usr/include/H5Lpkg.h
/usr/include/H5MPpkg.h
/usr/include/H5Opkg.h
/usr/include/H5Oshared.h
/usr/include/H5PBpkg.h
/usr/include/H5PLpkg.h
/usr/include/H5Ppkg.h
/usr/include/H5Rpkg.h
/usr/include/H5SMpkg.h
/usr/include/H5Spkg.h
/usr/include/H5Tpkg.h
/usr/include/H5Zpkg.h
/usr/include/H5f90.h
/usr/include/H5f90proto.h
/usr/include/H5fortran_types.F90
/usr/include/h5diff.h
/usr/include/h5tools.h
/usr/include/h5tools_dump.h
/usr/include/h5tools_ref.h
/usr/include/h5tools_str.h
/usr/include/h5tools_utils.h
/usr/include/h5trav.h
/usr/lib/libhdf5_f90cstub.so
/usr/lib/libhdf5_hl_f90cstub.so
/usr/lib/libhdf5_tools.so

(Note: I’m excluding versioned symlinks, see below)

/usr/lib/pkgconfig/
/usr/lib/pkgconfig/hdf5-1.10.2.pc
/usr/lib/pkgconfig/hdf5_cpp-1.10.2.pc
/usr/lib/pkgconfig/hdf5_hl-1.10.2.pc
/usr/lib/pkgconfig/hdf5_hl_cpp-1.10.2.pc
/usr/share/
/usr/share/cmake/
/usr/share/cmake/hdf5/
/usr/share/cmake/hdf5/hdf5-config-version.cmake
/usr/share/cmake/hdf5/hdf5-config.cmake
/usr/share/cmake/hdf5/hdf5-targets-release.cmake
/usr/share/cmake/hdf5/hdf5-targets.cmake
  1. When I build using CMake, some modules are present in two versions:
/usr/include/shared/
/usr/include/shared/h5_gen.mod
/usr/include/shared/h5a.mod
/usr/include/shared/h5d.mod
/usr/include/shared/h5ds.mod
/usr/include/shared/h5e.mod
/usr/include/shared/h5f.mod
/usr/include/shared/h5fortkit.mod
/usr/include/shared/h5fortran_types.mod
/usr/include/shared/h5g.mod
/usr/include/shared/h5global.mod
/usr/include/shared/h5i.mod
/usr/include/shared/h5im.mod
/usr/include/shared/h5l.mod
/usr/include/shared/h5lib.mod
/usr/include/shared/h5lt.mod
/usr/include/shared/h5lt_const.mod
/usr/include/shared/h5o.mod
/usr/include/shared/h5p.mod
/usr/include/shared/h5r.mod
/usr/include/shared/h5s.mod
/usr/include/shared/h5t.mod
/usr/include/shared/h5tb.mod
/usr/include/shared/h5tb_const.mod
/usr/include/shared/h5z.mod
/usr/include/shared/hdf5.mod
/usr/include/static/
/usr/include/static/h5_gen.mod
/usr/include/static/h5a.mod
/usr/include/static/h5d.mod
/usr/include/static/h5ds.mod
/usr/include/static/h5e.mod
/usr/include/static/h5f.mod
/usr/include/static/h5fortkit.mod
/usr/include/static/h5fortran_types.mod
/usr/include/static/h5g.mod
/usr/include/static/h5global.mod
/usr/include/static/h5i.mod
/usr/include/static/h5im.mod
/usr/include/static/h5l.mod
/usr/include/static/h5lib.mod
/usr/include/static/h5lt.mod
/usr/include/static/h5lt_const.mod
/usr/include/static/h5o.mod
/usr/include/static/h5p.mod
/usr/include/static/h5r.mod
/usr/include/static/h5s.mod
/usr/include/static/h5t.mod
/usr/include/static/h5tb.mod
/usr/include/static/h5tb_const.mod
/usr/include/static/h5z.mod
/usr/include/static/hdf5.mod

While in autotools:

/usr/include/h5_gen.mod
/usr/include/h5a.mod
/usr/include/h5d.mod
/usr/include/h5ds.mod
/usr/include/h5e.mod
/usr/include/h5f.mod
/usr/include/h5fortkit.mod
/usr/include/h5fortran_types.mod
/usr/include/h5g.mod
/usr/include/h5global.mod
/usr/include/h5i.mod
/usr/include/h5im.mod
/usr/include/h5l.mod
/usr/include/h5lib.mod
/usr/include/h5lt.mod
/usr/include/h5lt_const.mod
/usr/include/h5o.mod
/usr/include/h5p.mod
/usr/include/h5r.mod
/usr/include/h5s.mod
/usr/include/h5t.mod
/usr/include/h5tb.mod
/usr/include/h5tb_const.mod
/usr/include/h5z.mod
/usr/include/hdf5.mod
  1. CMake versioned symlinks for .so files are borked:
/usr/lib/libhdf5.so.100.2.0
/usr/lib/libhdf5.so.101
/usr/lib/libhdf5_cpp.so.100.2.0
/usr/lib/libhdf5_cpp.so.101
/usr/lib/libhdf5_f90cstub.so.100.2.0
/usr/lib/libhdf5_f90cstub.so.101
/usr/lib/libhdf5_fortran.so.100.2.0
/usr/lib/libhdf5_fortran.so.101
/usr/lib/libhdf5_hl.so.100.2.0
/usr/lib/libhdf5_hl.so.101
/usr/lib/libhdf5_hl_cpp.so.100.2.0
/usr/lib/libhdf5_hl_cpp.so.101
/usr/lib/libhdf5_hl_f90cstub.so.100.2.0
/usr/lib/libhdf5_hl_f90cstub.so.101
/usr/lib/libhdf5_hl_fortran.so.100.2.0
/usr/lib/libhdf5_hl_fortran.so.101

Autotools for reference:

/usr/lib/libhdf5.so.101
/usr/lib/libhdf5.so.101.1.0
/usr/lib/libhdf5_cpp.so.102
/usr/lib/libhdf5_cpp.so.102.0.0
/usr/lib/libhdf5_fortran.so.100
/usr/lib/libhdf5_fortran.so.100.1.1
/usr/lib/libhdf5_hl.so.100
/usr/lib/libhdf5_hl.so.100.1.0
/usr/lib/libhdf5_hl_cpp.so.100
/usr/lib/libhdf5_hl_cpp.so.100.1.1
/usr/lib/libhdf5hl_fortran.so.100
/usr/lib/libhdf5hl_fortran.so.100.0.2

Note that the CMake build outputs this at the beginning:

-- SOVERSION: 101.1.0
-- SOVERSION_TOOLS: 100.1.0
-- SOVERSION_CXX: 102.0.0
-- SOVERSION_F: 100.1.1
-- SOVERSION_HL: 100.1.0
-- SOVERSION_HL_CXX: 100.1.1
-- SOVERSION_HL_F: 100.0.2
-- SOVERSION_JAVA: 100.2.0
  1. The CMake build does not output a summary of the configuration before starting to build. For the record, here is autotools one:
        SUMMARY OF THE HDF5 CONFIGURATION
        =================================

General Information:
-------------------
                   HDF5 Version: 1.10.2
                  Configured on: Mon Apr  9 16:04:07 CEST 2018
                  Configured by: builduser@
                    Host system: x86_64-unknown-linux-gnu
              Uname information: Linux archange 4.15.13-1-ARCH #1 SMP PREEMPT Sun Mar 25 11:27:57 UTC 2018 x86_64 GNU/Linux
                       Byte sex: little-endian
             Installation point: /usr

Compiling Options:
------------------
                     Build Mode: production
              Debugging Symbols: no
                        Asserts: no
                      Profiling: no
             Optimization Level: high

Linking Options:
----------------
                      Libraries: static, shared
  Statically Linked Executables:
                        LDFLAGS: -Wl,-O1,--sort-common,--as-needed,-z,relro,-z,now
                     H5_LDFLAGS:
                     AM_LDFLAGS:
                Extra libraries: -lsz -lz -ldl -lm
                       Archiver: ar
                       AR_FLAGS: cr
                         Ranlib: ranlib

Languages:
----------
                              C: yes
                     C Compiler: /usr/bin/gcc ( gcc (GCC) 7.3.1 20180312)
                       CPPFLAGS: -D_FORTIFY_SOURCE=2
                    H5_CPPFLAGS: -D_GNU_SOURCE -D_POSIX_C_SOURCE=200112L   -DNDEBUG -UH5_DEBUG_API
                    AM_CPPFLAGS:
                        C Flags: -march=x86-64 -mtune=generic -O2 -pipe -fstack-protector-strong -fno-plt
                     H5 C Flags: -std=c99 -pedantic -Wall -Wextra -Wbad-function-cast -Wc++-compat -Wcast-align -Wcast-qual -Wconversion -Wdeclaration-after-statement -Wdisabled-optimization -Wfloat-equal -Wformat=2 -Winit-self -Winvalid-pch -Wmissing-declarations -Wmissing-include-dirs -Wmissing-prototypes -Wnested-externs -Wold-style-definition -Wpacked -Wpointer-arith -Wredundant-decls -Wshadow -Wstrict-prototypes -Wswitch-default -Wswitch-enum -Wundef -Wunused-macros -Wunsafe-loop-optimizations -Wwrite-strings -finline-functions -s -Wno-inline -Wno-aggregate-return -Wno-missing-format-attribute -Wno-missing-noreturn -O
                     AM C Flags:
               Shared C Library: yes
               Static C Library: yes


                        Fortran: yes
               Fortran Compiler: /usr/bin/gfortran ( GNU Fortran (GCC) 7.3.1 20180312)
                  Fortran Flags:
               H5 Fortran Flags: -pedantic -Wall -Wextra -Wunderflow -Wimplicit-interface -Wsurprising -Wno-c-binding-type  -s -O2
               AM Fortran Flags:
         Shared Fortran Library: yes
         Static Fortran Library: yes

                            C++: yes
                   C++ Compiler: /usr/bin/g++ ( g++ (GCC) 7.3.1 20180312)
                      C++ Flags: -march=x86-64 -mtune=generic -O2 -pipe -fstack-protector-strong -fno-plt
                   H5 C++ Flags: -pedantic -Wall -W -Wundef -Wshadow -Wpointer-arith -Wcast-qual -Wcast-align -Wwrite-strings -Wconversion -Wredundant-decls -Winline -Wsign-promo -Woverloaded-virtual -Wold-style-cast -Weffc++ -Wreorder -Wnon-virtual-dtor -Wctor-dtor -privacy -Wabi -finline-functions -s -O
                   AM C++ Flags:
             Shared C++ Library: yes
             Static C++ Library: yes

                           Java: no


Features:
---------
                  Parallel HDF5: no
             High-level library: yes
                   Threadsafety: no
            Default API mapping: v110
 With deprecated public symbols: yes
         I/O filters (external): deflate(zlib),szip(encoder)
                            MPE: no
                     Direct VFD: no
                        dmalloc: no
 Packages w/ extra debug output: none
                    API tracing: no
           Using memory checker: no
Memory allocation sanity checks: no
            Metadata trace file: no
         Function stack tracing: no
      Strict file format checks: no
   Optimization instrumentation: no

There might be other ones, but if everything here is addressed, that would be a good start. :wink:

Yes there are differences between the build systems, because they do target different uses. However,
the libraries and include files are intended to be the same. Most of the differences stem from autotools being unix platform centric and CMake being cross-platform.

The .so numbers are wrong in CMake, thanks for discovering that. We have a HDF Group initiative to make the CMake builds on linux a reliable option (originally CMake was a Windows only implementation). So any help is very much appreciated. Our bug tracker number for this issue is HDFFV-10444 and a fix is already in progress.

Static builds are required for certain link operations, therefore SHARED is the option.

The summary info is just the hdf5.settings file in the lib folder. I guess we could have CMake display it, maybe as a very verbose option.

CMake builds the fortran cstub libraries separately from the fortran library.

CMake builds the fortran mod files in separate folders because of build mechanics - however the packaging will only use one set of *.mod files.

PKG-CONFIG support is new for CMake (we do plan to add it to autotools builds) in order to create equivalent h5xxx scripts for CMake builds. The CMake scripts use the pkgconfig files where the autotools h5xxx scripts implement the link and compile options. Equivalent but not identical.

Allen

OK, so I guess I should be building with autotools then (at least for now).

OK, noted.

Why then does autotools builds allow to disable static build? (–disable-static)

Well it’s nice to have a summary of the configuration that will be used to build to check everything is right (I sometime have surprises with projects silently discarding an option if a dependency is missing rather than aborting, and also they are numerous projects not respecting {C,CPP,CXX,LD}FLAGS).

OK for the differences explanations, however I’m not sure of what you mean in your last sentence: lists of files above are what ended up in my package with make install.

I know it’s new, it has been requested some time ago on our side (https://bugs.archlinux.org/task/56370), and it’s availability only in CMake builds is what made me try those instead of autotools. :wink:

pkg-config is required in any case, because some projects depend on this to detect HDF5 correctly… :wink:

One more issue, tests run fine with ctest . -C Release for CMake builds but make check fails in autotools builds:

make  testhdf5 cache cache_api cache_image cache_tagging lheap ohdr stab gheap evict_on_close farray earray btree2 fheap pool accum hyperslab istore bittests dt_arith page_buffer dtypes dsets cmpd_dset filter_fail extend external efc objcopy links unlink twriteorder big mtime fillval mount flush1 flush2 app_ref enum set_extent ttsafe enc_dec_plist enc_dec_plist_cross_platform getname vfd ntypes dangle dtransform reserved cross_read freespace mf vds file_image unregister cache_logging cork swmr error_test err_compat tcheck_version testmeta accum_swmr_reader atomic_writer atomic_reader links_env filenotclosed flushrefresh use_append_chunk use_append_mchunks use_disable_mdc_flushes swmr_generator swmr_start_write swmr_reader swmr_writer swmr_remove_reader swmr_remove_writer swmr_addrem_writer swmr_sparse_reader swmr_sparse_writer swmr_check_compat_vfd vds_swmr_gen vds_swmr_reader vds_swmr_writer filter_plugin testerror.sh testlibinfo.sh testcheck_version.sh testlinks_env.sh test_filenotclosed.sh testswmr.sh testvdsswmr.sh testflushrefresh.sh test_usecases.sh test_filter_plugin.sh
make[1]: Entering directory '/build/hdf5/src/hdf5-1.10.2/test'
make[1]: 'testhdf5' is up to date.
make[1]: 'cache' is up to date.
make[1]: 'cache_api' is up to date.
make[1]: 'cache_image' is up to date.
make[1]: 'cache_tagging' is up to date.
make[1]: 'lheap' is up to date.
make[1]: 'ohdr' is up to date.
make[1]: 'stab' is up to date.
make[1]: 'gheap' is up to date.
make[1]: 'evict_on_close' is up to date.
make[1]: 'farray' is up to date.
make[1]: 'earray' is up to date.
make[1]: 'btree2' is up to date.
make[1]: 'fheap' is up to date.
make[1]: 'pool' is up to date.
make[1]: 'accum' is up to date.
make[1]: 'hyperslab' is up to date.
make[1]: 'istore' is up to date.
make[1]: 'bittests' is up to date.
make[1]: 'dt_arith' is up to date.
make[1]: 'page_buffer' is up to date.
make[1]: 'dtypes' is up to date.
make[1]: 'dsets' is up to date.
make[1]: 'cmpd_dset' is up to date.
make[1]: 'filter_fail' is up to date.
make[1]: 'extend' is up to date.
make[1]: 'external' is up to date.
make[1]: 'efc' is up to date.
make[1]: 'objcopy' is up to date.
make[1]: 'links' is up to date.
make[1]: 'unlink' is up to date.
make[1]: 'twriteorder' is up to date.
make[1]: 'big' is up to date.
make[1]: 'mtime' is up to date.
make[1]: 'fillval' is up to date.
make[1]: 'mount' is up to date.
make[1]: 'flush1' is up to date.
make[1]: 'flush2' is up to date.
make[1]: 'app_ref' is up to date.
make[1]: 'enum' is up to date.
make[1]: 'set_extent' is up to date.
make[1]: 'ttsafe' is up to date.
make[1]: 'enc_dec_plist' is up to date.
make[1]: 'enc_dec_plist_cross_platform' is up to date.
make[1]: 'getname' is up to date.
make[1]: 'vfd' is up to date.
make[1]: 'ntypes' is up to date.
make[1]: 'dangle' is up to date.
make[1]: 'dtransform' is up to date.
make[1]: 'reserved' is up to date.
make[1]: 'cross_read' is up to date.
make[1]: 'freespace' is up to date.
make[1]: 'mf' is up to date.
make[1]: 'vds' is up to date.
make[1]: 'file_image' is up to date.
make[1]: 'unregister' is up to date.
make[1]: 'cache_logging' is up to date.
make[1]: 'cork' is up to date.
make[1]: 'swmr' is up to date.
make[1]: 'error_test' is up to date.
make[1]: 'err_compat' is up to date.
make[1]: 'tcheck_version' is up to date.
make[1]: 'testmeta' is up to date.
make[1]: 'accum_swmr_reader' is up to date.
make[1]: 'atomic_writer' is up to date.
make[1]: 'atomic_reader' is up to date.
make[1]: 'links_env' is up to date.
make[1]: 'filenotclosed' is up to date.
make[1]: 'flushrefresh' is up to date.
make[1]: 'use_append_chunk' is up to date.
make[1]: 'use_append_mchunks' is up to date.
make[1]: 'use_disable_mdc_flushes' is up to date.
make[1]: 'swmr_generator' is up to date.
make[1]: 'swmr_start_write' is up to date.
make[1]: 'swmr_reader' is up to date.
make[1]: 'swmr_writer' is up to date.
make[1]: 'swmr_remove_reader' is up to date.
make[1]: 'swmr_remove_writer' is up to date.
make[1]: 'swmr_addrem_writer' is up to date.
make[1]: 'swmr_sparse_reader' is up to date.
make[1]: 'swmr_sparse_writer' is up to date.
make[1]: 'swmr_check_compat_vfd' is up to date.
make[1]: 'vds_swmr_gen' is up to date.
make[1]: 'vds_swmr_reader' is up to date.
make[1]: 'vds_swmr_writer' is up to date.
make[1]: 'filter_plugin' is up to date.
make[1]: 'testerror.sh' is up to date.
make[1]: 'testlibinfo.sh' is up to date.
make[1]: 'testcheck_version.sh' is up to date.
make[1]: 'testlinks_env.sh' is up to date.
make[1]: 'test_filenotclosed.sh' is up to date.
make[1]: 'testswmr.sh' is up to date.
make[1]: 'testvdsswmr.sh' is up to date.
make[1]: 'testflushrefresh.sh' is up to date.
make[1]: 'test_usecases.sh' is up to date.
make[1]: 'test_filter_plugin.sh' is up to date.
make[1]: Leaving directory '/build/hdf5/src/hdf5-1.10.2/test'
make  check-TESTS
make[1]: Entering directory '/build/hdf5/src/hdf5-1.10.2/test'
make[2]: Entering directory '/build/hdf5/src/hdf5-1.10.2/test'
===Serial tests in test begin Tue Apr 10 17:50:00 CEST 2018===
make[3]: Entering directory '/build/hdf5/src/hdf5-1.10.2/test'
============================
============================
============================
============================
============================
============================
============================
Testing  cache_tagging 
Testing  testhdf5 
============================
Testing  cache 
Testing  cache_api 
Testing  cache_image 
Testing  lheap 
Testing  ohdr 
Testing  stab 
============================
 cache_api  Test Log
============================
/build/hdf5/src/hdf5-1.10.2/test/.libs/lt-cache_api: error while loading shared libraries: libhdf5.so.101: cannot open shared object file: No such file or directory
Command exited with non-zero status 127
0.08user 0.02system 0:00.11elapsed 96%CPU (0avgtext+0avgdata 9416maxresident)k
0inputs+0outputs (0major+4419minor)pagefaults 0swaps
============================
 cache_tagging  Test Log
============================
/build/hdf5/src/hdf5-1.10.2/test/.libs/lt-cache_tagging: error while loading shared libraries: libhdf5.so.101: cannot open shared object file: No such file or directory
Command exited with non-zero status 127
0.07user 0.02system 0:00.11elapsed 91%CPU (0avgtext+0avgdata 9400maxresident)k
0inputs+0outputs (0major+4391minor)pagefaults 0swaps
============================
 lheap  Test Log
============================
/build/hdf5/src/hdf5-1.10.2/test/.libs/lt-lheap: error while loading shared libraries: libhdf5.so.101: cannot open shared object file: No such file or directory
Command exited with non-zero status 127
0.07user 0.03system 0:00.11elapsed 92%CPU (0avgtext+0avgdata 9224maxresident)k
0inputs+0outputs (0major+4397minor)pagefaults 0swaps
make[3]: *** [Makefile:3092: cache_api.chkexe_] Error 1
make[3]: *** Waiting for unfinished jobs....
make[3]: *** [Makefile:3092: cache_tagging.chkexe_] Error 1
make[3]: *** [Makefile:3092: lheap.chkexe_] Error 1
============================
 ohdr  Test Log
============================
/build/hdf5/src/hdf5-1.10.2/test/.libs/lt-ohdr: error while loading shared libraries: libhdf5.so.101: cannot open shared object file: No such file or directory
Command exited with non-zero status 127
0.07user 0.02system 0:00.11elapsed 91%CPU (0avgtext+0avgdata 9292maxresident)k
0inputs+0outputs (0major+4375minor)pagefaults 0swaps
============================
 cache_image  Test Log
============================
/build/hdf5/src/hdf5-1.10.2/test/.libs/lt-cache_image: error while loading shared libraries: libhdf5.so.101: cannot open shared object file: No such file or directory
Command exited with non-zero status 127
0.07user 0.03system 0:00.11elapsed 93%CPU (0avgtext+0avgdata 9704maxresident)k
0inputs+0outputs (0major+4457minor)pagefaults 0swaps
make[3]: *** [Makefile:3092: ohdr.chkexe_] Error 1
make[3]: *** [Makefile:3092: cache_image.chkexe_] Error 1
============================
 stab  Test Log
============================
/build/hdf5/src/hdf5-1.10.2/test/.libs/lt-stab: error while loading shared libraries: libhdf5.so.101: cannot open shared object file: No such file or directory
Command exited with non-zero status 127
0.07user 0.03system 0:00.11elapsed 94%CPU (0avgtext+0avgdata 9384maxresident)k
0inputs+0outputs (0major+4389minor)pagefaults 0swaps
make[3]: *** [Makefile:3092: stab.chkexe_] Error 1
============================
 cache  Test Log
============================
/build/hdf5/src/hdf5-1.10.2/test/.libs/lt-cache: error while loading shared libraries: libhdf5.so.101: cannot open shared object file: No such file or directory
Command exited with non-zero status 127
0.08user 0.02system 0:00.11elapsed 93%CPU (0avgtext+0avgdata 10296maxresident)k
0inputs+0outputs (0major+4570minor)pagefaults 0swaps
make[3]: *** [Makefile:3092: cache.chkexe_] Error 1
============================
 testhdf5  Test Log
============================
/build/hdf5/src/hdf5-1.10.2/test/.libs/lt-testhdf5: error while loading shared libraries: libhdf5.so.101: cannot open shared object file: No such file or directory
Command exited with non-zero status 127
0.10user 0.03system 0:00.15elapsed 93%CPU (0avgtext+0avgdata 16668maxresident)k
0inputs+0outputs (0major+6240minor)pagefaults 0swaps
make[3]: *** [Makefile:3092: testhdf5.chkexe_] Error 1
make[3]: Leaving directory '/build/hdf5/src/hdf5-1.10.2/test'
make[2]: *** [Makefile:3078: build-check-s] Error 2
make[2]: Leaving directory '/build/hdf5/src/hdf5-1.10.2/test'
make[1]: *** [Makefile:3072: test] Error 2
make[1]: Leaving directory '/build/hdf5/src/hdf5-1.10.2/test'
make: *** [Makefile:2855: check-am] Error 2

They are still a bunch of questions left unanswered here, especially regarding static vs. shared builds.

The next release of HDF software will add the ability to only build shared libs with CMake.

We will continue to package (CMake) fortran mod files for static and shared (if both are enabled) because we have found there are some platforms that fail using the wrong version.

We have added CMake toolchain support for some use cases.

Allen