geospace-code / h5fortran

Lightweight HDF5 polymorphic Fortran: h5write() h5read()
https://geospace-code.github.io/h5fortran
BSD 3-Clause "New" or "Revised" License
99 stars 24 forks source link

undefined reference to `__h5d_MOD_h5dopen_f' #7

Closed nyckmaia closed 4 years ago

nyckmaia commented 4 years ago

I downloaded this library and I'm trying to use in my Linux environment.

So, I built it using CMake and I got a build folder with include folder and the static library file.

After that, I wrote a simple file f_test.f90 and I'm trying to compile it:

module mod
    use h5fortran, only: hdf5_file

    contains
    subroutine xxx() bind(C, name = 'xxx')

        type(hdf5_file) :: h5f
        call h5f%initialize('test.h5', status='new',action='w')

            call h5f%write('/myScalar', 10)

            call h5f%finalize()

        end subroutine xxx
    end module mod

gfortran -Wall -Wextra f_test.f90 -I ./h5fortran/build/include/ -L ./h5fortran/build/ -lh5fortran

But I got this compile time error below:

/usr/bin/ld: /usr/lib/gcc/x86_64-linux-gnu/9/../../../x86_64-linux-gnu/Scrt1.o: in function `_start':
(.text+0x24): undefined reference to `main'
/usr/bin/ld: ./h5fortran/build//libh5fortran.a(interface.f90.o): in function `__h5fortran_MOD_hdf_get_slice':
interface.f90:(.text+0x783): undefined reference to `__h5d_MOD_h5dopen_f'
/usr/bin/ld: interface.f90:(.text+0xbf3): undefined reference to `__h5d_MOD_h5dget_space_f'
/usr/bin/ld: interface.f90:(.text+0xc8b): undefined reference to `__h5global_MOD_h5s_select_set_f'
/usr/bin/ld: interface.f90:(.text+0xc99): undefined reference to `__h5s_MOD_h5sselect_hyperslab_f'
/usr/bin/ld: interface.f90:(.text+0xcc5): undefined reference to `__h5s_MOD_h5screate_simple_f'
/usr/bin/ld: ./h5fortran/build//libh5fortran.a(interface.f90.o): in function `__h5fortran_MOD_hdf_shape_check':
interface.f90:(.text+0x1645): undefined reference to `__h5lt_const_MOD_h5ltget_dataset_ndims_f'
/usr/bin/ld: interface.f90:(.text+0x1a20): undefined reference to `__h5lt_const_MOD_h5ltget_dataset_info_f'
/usr/bin/ld: ./h5fortran/build//libh5fortran.a(interface.f90.o): in function `__h5fortran_MOD_hdf_wrapup':
interface.f90:(.text+0x1dba): undefined reference to `__h5s_MOD_h5sclose_f'
/usr/bin/ld: interface.f90:(.text+0x1de2): undefined reference to `__h5d_MOD_h5dclose_f'
/usr/bin/ld: ./h5fortran/build//libh5fortran.a(interface.f90.o): in function `__h5fortran_MOD_write_group':
interface.f90:(.text+0x1eca): undefined reference to `__h5l_MOD_h5lexists_f'
/usr/bin/ld: interface.f90:(.text+0x1f2e): undefined reference to `__h5g_MOD_h5gcreate_f'
/usr/bin/ld: interface.f90:(.text+0x1f73): undefined reference to `__h5g_MOD_h5gclose_f'
/usr/bin/ld: ./h5fortran/build//libh5fortran.a(interface.f90.o): in function `__h5fortran_MOD_hdf_flush':
interface.f90:(.text+0x1fed): undefined reference to `__h5global_MOD_h5f_scope_global_f'
/usr/bin/ld: interface.f90:(.text+0x2006): undefined reference to `__h5f_MOD_h5fflush_f'
/usr/bin/ld: ./h5fortran/build//libh5fortran.a(interface.f90.o): in function `__h5fortran_MOD_hdf_finalize':
interface.f90:(.text+0x2137): undefined reference to `__h5f_MOD_h5fclose_f'
/usr/bin/ld: interface.f90:(.text+0x233c): undefined reference to `__h5lib_MOD_h5close_f'
/usr/bin/ld: ./h5fortran/build//libh5fortran.a(interface.f90.o): in function `__h5fortran_MOD_hdf_initialize':
interface.f90:(.text+0x24f7): undefined reference to `__h5lib_MOD_h5open_f'
/usr/bin/ld: interface.f90:(.text+0x25e4): undefined reference to `__h5lib_MOD_h5get_libversion_f'
/usr/bin/ld: interface.f90:(.text+0x2646): undefined reference to `__h5e_MOD_h5eset_auto_f'
/usr/bin/ld: interface.f90:(.text+0x2a58): undefined reference to `__h5e_MOD_h5eset_auto_f'
/usr/bin/ld: interface.f90:(.text+0x2a74): undefined reference to `__h5global_MOD_h5f_acc_trunc_f'
/usr/bin/ld: interface.f90:(.text+0x2a89): undefined reference to `__h5f_MOD_h5fcreate_f'
/usr/bin/ld: interface.f90:(.text+0x2b3d): undefined reference to `__h5global_MOD_h5f_acc_trunc_f'
/usr/bin/ld: interface.f90:(.text+0x2b45): undefined reference to `__h5f_MOD_h5fcreate_f'
/usr/bin/ld: interface.f90:(.text+0x2d61): undefined reference to `__h5f_MOD_h5fis_hdf5_f'
/usr/bin/ld: interface.f90:(.text+0x2d97): undefined reference to `__h5global_MOD_h5f_acc_rdwr_f'
/usr/bin/ld: interface.f90:(.text+0x2d9f): undefined reference to `__h5f_MOD_h5fopen_f'
/usr/bin/ld: interface.f90:(.text+0x2dbb): undefined reference to `__h5global_MOD_h5f_acc_rdonly_f'
/usr/bin/ld: interface.f90:(.text+0x2dc3): undefined reference to `__h5f_MOD_h5fopen_f'
/usr/bin/ld: ./h5fortran/build//libh5fortran.a(interface.f90.o): in function `__h5fortran_MOD_is_hdf5':
interface.f90:(.text+0x308d): undefined reference to `__h5f_MOD_h5fis_hdf5_f'
/usr/bin/ld: ./h5fortran/build//libh5fortran.a(interface.f90.o): in function `__h5fortran_MOD_hdf5_close':
interface.f90:(.text+0x30c2): undefined reference to `__h5lib_MOD_h5close_f'
/usr/bin/ld: ./h5fortran/build//libh5fortran.a(read.f90.o): in function `__h5fortran_MOD_hdf_check_exist':
read.f90:(.text+0x52): undefined reference to `__h5lt_const_MOD_h5ltpath_valid_f'
/usr/bin/ld: ./h5fortran/build//libh5fortran.a(read.f90.o): in function `__h5fortran_MOD_hdf_is_chunked':
read.f90:(.text+0x290): undefined reference to `__h5global_MOD_h5d_chunked_f'
/usr/bin/ld: ./h5fortran/build//libh5fortran.a(read.f90.o): in function `__h5fortran_MOD_hdf_is_contig':
read.f90:(.text+0x2b0): undefined reference to `__h5global_MOD_h5d_contiguous_f'
/usr/bin/ld: ./h5fortran/build//libh5fortran.a(read.f90.o): in function `__h5fortran_MOD_hdf_get_layout':
read.f90:(.text+0x321): undefined reference to `__h5d_MOD_h5dopen_f'
/usr/bin/ld: read.f90:(.text+0x44f): undefined reference to `__h5d_MOD_h5dget_create_plist_f'
/usr/bin/ld: read.f90:(.text+0x566): undefined reference to `__h5p_MOD_h5pget_layout_f'
/usr/bin/ld: read.f90:(.text+0x69c): undefined reference to `__h5d_MOD_h5dclose_f'
/usr/bin/ld: ./h5fortran/build//libh5fortran.a(read.f90.o): in function `__h5fortran_MOD_hdf_get_chunk':
read.f90:(.text+0x9be): undefined reference to `__h5lt_const_MOD_h5ltget_dataset_ndims_f'
/usr/bin/ld: read.f90:(.text+0xb07): undefined reference to `__h5d_MOD_h5dopen_f'
/usr/bin/ld: read.f90:(.text+0xc3e): undefined reference to `__h5d_MOD_h5dget_create_plist_f'
/usr/bin/ld: read.f90:(.text+0xdd8): undefined reference to `__h5p_MOD_h5pget_chunk_f'
/usr/bin/ld: read.f90:(.text+0x1068): undefined reference to `__h5d_MOD_h5dclose_f'
/usr/bin/ld: ./h5fortran/build//libh5fortran.a(read.f90.o): in function `__h5fortran_MOD_hdf_get_shape':
read.f90:(.text+0x11d6): undefined reference to `__h5lt_const_MOD_h5ltget_dataset_ndims_f'
/usr/bin/ld: read.f90:(.text+0x1281): undefined reference to `__h5lt_const_MOD_h5ltget_dataset_info_f'
/usr/bin/ld: ./h5fortran/build//libh5fortran.a(read.f90.o): in function `__h5fortran_MOD_hdf_get_ndims':
read.f90:(.text+0x159d): undefined reference to `__h5lt_const_MOD_h5ltget_dataset_ndims_f'
/usr/bin/ld: ./h5fortran/build//libh5fortran.a(reader.f90.o): in function `__h5fortran_MOD_hdf_read_7d':
reader.f90:(.text+0x76a): undefined reference to `__h5global_MOD_h5s_all_f'
/usr/bin/ld: reader.f90:(.text+0xd98): undefined reference to `__h5d_MOD_h5dopen_f'
/usr/bin/ld: reader.f90:(.text+0x11e9): undefined reference to `__h5global_MOD_h5t_native_integer'
/usr/bin/ld: reader.f90:(.text+0x120e): undefined reference to `__h5_gen_MOD_h5dread_ikind_4_rank_7'
/usr/bin/ld: reader.f90:(.text+0x149d): undefined reference to `__h5global_MOD_h5t_native_real'
/usr/bin/ld: reader.f90:(.text+0x14b2): undefined reference to `__h5_gen_MOD_h5dread_rkind_4_rank_7'
/usr/bin/ld: reader.f90:(.text+0x1743): undefined reference to `__h5global_MOD_h5t_native_double'
/usr/bin/ld: reader.f90:(.text+0x1758): undefined reference to `__h5_gen_MOD_h5dread_rkind_8_rank_7'
/usr/bin/ld: ./h5fortran/build//libh5fortran.a(reader.f90.o): in function `__h5fortran_MOD_hdf_read_6d':
reader.f90:(.text+0x1de3): undefined reference to `__h5global_MOD_h5s_all_f'
/usr/bin/ld: reader.f90:(.text+0x23a0): undefined reference to `__h5d_MOD_h5dopen_f'
/usr/bin/ld: reader.f90:(.text+0x27a7): undefined reference to `__h5global_MOD_h5t_native_integer'
/usr/bin/ld: reader.f90:(.text+0x27cc): undefined reference to `__h5_gen_MOD_h5dread_ikind_4_rank_6'
/usr/bin/ld: reader.f90:(.text+0x2a11): undefined reference to `__h5global_MOD_h5t_native_real'
/usr/bin/ld: reader.f90:(.text+0x2a26): undefined reference to `__h5_gen_MOD_h5dread_rkind_4_rank_6'
/usr/bin/ld: reader.f90:(.text+0x2c6d): undefined reference to `__h5global_MOD_h5t_native_double'
/usr/bin/ld: reader.f90:(.text+0x2c82): undefined reference to `__h5_gen_MOD_h5dread_rkind_8_rank_6'
/usr/bin/ld: ./h5fortran/build//libh5fortran.a(reader.f90.o): in function `__h5fortran_MOD_hdf_read_5d':
reader.f90:(.text+0x3248): undefined reference to `__h5global_MOD_h5s_all_f'
/usr/bin/ld: reader.f90:(.text+0x37d0): undefined reference to `__h5d_MOD_h5dopen_f'
/usr/bin/ld: reader.f90:(.text+0x3b96): undefined reference to `__h5global_MOD_h5t_native_integer'
/usr/bin/ld: reader.f90:(.text+0x3bbb): undefined reference to `__h5_gen_MOD_h5dread_ikind_4_rank_5'
/usr/bin/ld: reader.f90:(.text+0x3dbf): undefined reference to `__h5global_MOD_h5t_native_real'
/usr/bin/ld: reader.f90:(.text+0x3dd4): undefined reference to `__h5_gen_MOD_h5dread_rkind_4_rank_5'
/usr/bin/ld: reader.f90:(.text+0x3fda): undefined reference to `__h5global_MOD_h5t_native_double'
/usr/bin/ld: reader.f90:(.text+0x3fef): undefined reference to `__h5_gen_MOD_h5dread_rkind_8_rank_5'
/usr/bin/ld: ./h5fortran/build//libh5fortran.a(reader.f90.o): in function `__h5fortran_MOD_hdf_read_4d':
reader.f90:(.text+0x44f0): undefined reference to `__h5global_MOD_h5s_all_f'
/usr/bin/ld: reader.f90:(.text+0x49e2): undefined reference to `__h5d_MOD_h5dopen_f'
/usr/bin/ld: reader.f90:(.text+0x4bc9): undefined reference to `__h5global_MOD_h5t_native_double'
/usr/bin/ld: reader.f90:(.text+0x4bdc): undefined reference to `__h5_gen_MOD_h5dread_rkind_8_rank_4'
/usr/bin/ld: reader.f90:(.text+0x4e8b): undefined reference to `__h5global_MOD_h5t_native_integer'
/usr/bin/ld: reader.f90:(.text+0x4e9e): undefined reference to `__h5_gen_MOD_h5dread_ikind_4_rank_4'
/usr/bin/ld: reader.f90:(.text+0x4fc4): undefined reference to `__h5global_MOD_h5t_native_real'
/usr/bin/ld: reader.f90:(.text+0x4fd4): undefined reference to `__h5_gen_MOD_h5dread_rkind_4_rank_4'
/usr/bin/ld: ./h5fortran/build//libh5fortran.a(reader.f90.o): in function `__h5fortran_MOD_hdf_read_3d':
reader.f90:(.text+0x53d5): undefined reference to `__h5global_MOD_h5s_all_f'
/usr/bin/ld: reader.f90:(.text+0x58a1): undefined reference to `__h5d_MOD_h5dopen_f'
/usr/bin/ld: reader.f90:(.text+0x5bb8): undefined reference to `__h5global_MOD_h5t_native_double'
/usr/bin/ld: reader.f90:(.text+0x5bcb): undefined reference to `__h5_gen_MOD_h5dread_rkind_8_rank_3'
/usr/bin/ld: reader.f90:(.text+0x5cf6): undefined reference to `__h5global_MOD_h5t_native_integer'
/usr/bin/ld: reader.f90:(.text+0x5d09): undefined reference to `__h5_gen_MOD_h5dread_ikind_4_rank_3'
/usr/bin/ld: reader.f90:(.text+0x5e07): undefined reference to `__h5global_MOD_h5t_native_real'
/usr/bin/ld: reader.f90:(.text+0x5e17): undefined reference to `__h5_gen_MOD_h5dread_rkind_4_rank_3'
/usr/bin/ld: ./h5fortran/build//libh5fortran.a(reader.f90.o): in function `__h5fortran_MOD_hdf_read_2d':
reader.f90:(.text+0x6171): undefined reference to `__h5global_MOD_h5s_all_f'
/usr/bin/ld: reader.f90:(.text+0x65ed): undefined reference to `__h5d_MOD_h5dopen_f'
/usr/bin/ld: reader.f90:(.text+0x68d3): undefined reference to `__h5global_MOD_h5t_native_double'
/usr/bin/ld: reader.f90:(.text+0x68e6): undefined reference to `__h5_gen_MOD_h5dread_rkind_8_rank_2'
/usr/bin/ld: reader.f90:(.text+0x69eb): undefined reference to `__h5global_MOD_h5t_native_real'
/usr/bin/ld: reader.f90:(.text+0x69fb): undefined reference to `__h5_gen_MOD_h5dread_rkind_4_rank_2'
/usr/bin/ld: reader.f90:(.text+0x6ace): undefined reference to `__h5global_MOD_h5t_native_integer'
/usr/bin/ld: reader.f90:(.text+0x6ae1): undefined reference to `__h5_gen_MOD_h5dread_ikind_4_rank_2'
/usr/bin/ld: ./h5fortran/build//libh5fortran.a(reader.f90.o): in function `__h5fortran_MOD_hdf_read_1d':
reader.f90:(.text+0x6d65): undefined reference to `__h5global_MOD_h5s_all_f'
/usr/bin/ld: reader.f90:(.text+0x71ab): undefined reference to `__h5d_MOD_h5dopen_f'
/usr/bin/ld: reader.f90:(.text+0x7474): undefined reference to `__h5global_MOD_h5t_native_double'
/usr/bin/ld: reader.f90:(.text+0x7487): undefined reference to `__h5_gen_MOD_h5dread_rkind_8_rank_1'
/usr/bin/ld: reader.f90:(.text+0x7565): undefined reference to `__h5global_MOD_h5t_native_real'
/usr/bin/ld: reader.f90:(.text+0x7575): undefined reference to `__h5_gen_MOD_h5dread_rkind_4_rank_1'
/usr/bin/ld: reader.f90:(.text+0x7622): undefined reference to `__h5global_MOD_h5t_native_integer'
/usr/bin/ld: reader.f90:(.text+0x7635): undefined reference to `__h5_gen_MOD_h5dread_ikind_4_rank_1'
/usr/bin/ld: ./h5fortran/build//libh5fortran.a(reader.f90.o): in function `__h5fortran_MOD_hdf_read_scalar':
reader.f90:(.text+0x7720): undefined reference to `__h5d_MOD_h5dopen_f'
/usr/bin/ld: reader.f90:(.text+0x796a): undefined reference to `__h5global_MOD_h5t_native_double'
/usr/bin/ld: reader.f90:(.text+0x797d): undefined reference to `__h5_gen_MOD_h5dread_rkind_8_rank_0'
/usr/bin/ld: reader.f90:(.text+0x79e0): undefined reference to `__h5global_MOD_h5t_native_real'
/usr/bin/ld: reader.f90:(.text+0x79fd): undefined reference to `__h5_gen_MOD_h5dread_rkind_4_rank_0'
/usr/bin/ld: reader.f90:(.text+0x7a74): undefined reference to `__h5lt_const_MOD_h5ltread_dataset_string_f'
/usr/bin/ld: reader.f90:(.text+0x7ad2): undefined reference to `__h5global_MOD_h5t_native_integer'
/usr/bin/ld: reader.f90:(.text+0x7ae5): undefined reference to `__h5_gen_MOD_h5dread_ikind_4_rank_0'
/usr/bin/ld: ./h5fortran/build//libh5fortran.a(write.f90.o): in function `__h5fortran_MOD_hdf_close_group':
write.f90:(.text+0x29): undefined reference to `__h5g_MOD_h5gclose_f'
/usr/bin/ld: ./h5fortran/build//libh5fortran.a(write.f90.o): in function `__h5fortran_MOD_hdf_open_group':
write.f90:(.text+0xed): undefined reference to `__h5g_MOD_h5gopen_f'
/usr/bin/ld: ./h5fortran/build//libh5fortran.a(write.f90.o): in function `__h5fortran.write_MOD_hdf_set_deflate':
write.f90:(.text+0xa01): undefined reference to `__h5global_MOD_h5p_dataset_create_f'
/usr/bin/ld: write.f90:(.text+0xa06): undefined reference to `__h5p_MOD_h5pcreate_f'
/usr/bin/ld: write.f90:(.text+0xa49): undefined reference to `__h5p_MOD_h5pset_chunk_f'
/usr/bin/ld: write.f90:(.text+0xa73): undefined reference to `__h5p_MOD_h5pset_shuffle_f'
/usr/bin/ld: write.f90:(.text+0xa9d): undefined reference to `__h5p_MOD_h5pset_fletcher32_f'
/usr/bin/ld: write.f90:(.text+0xace): undefined reference to `__h5p_MOD_h5pset_deflate_f'
/usr/bin/ld: ./h5fortran/build//libh5fortran.a(write.f90.o): in function `__h5fortran.write_MOD_hdf_setup_write':
write.f90:(.text+0x1049): undefined reference to `__h5lt_const_MOD_h5ltpath_valid_f'
/usr/bin/ld: write.f90:(.text+0x12ad): undefined reference to `__h5s_MOD_h5screate_simple_f'
/usr/bin/ld: write.f90:(.text+0x1317): undefined reference to `__h5d_MOD_h5dcreate_f'
/usr/bin/ld: write.f90:(.text+0x1342): undefined reference to `__h5p_MOD_h5pclose_f'
/usr/bin/ld: write.f90:(.text+0x1440): undefined reference to `__h5d_MOD_h5dopen_f'
/usr/bin/ld: write.f90:(.text+0x14a2): undefined reference to `__h5global_MOD_h5s_scalar_f'
/usr/bin/ld: write.f90:(.text+0x14a7): undefined reference to `__h5s_MOD_h5screate_f'
/usr/bin/ld: write.f90:(.text+0x14ce): undefined reference to `__h5d_MOD_h5dcreate_f'
/usr/bin/ld: ./h5fortran/build//libh5fortran.a(writer.f90.o): in function `__h5fortran_MOD_hdf_write_7d':
writer.f90:(.text+0x776): undefined reference to `__h5global_MOD_h5t_native_real'
/usr/bin/ld: writer.f90:(.text+0x7ce): undefined reference to `__h5global_MOD_h5t_native_real'
/usr/bin/ld: writer.f90:(.text+0x7d9): undefined reference to `__h5_gen_MOD_h5dwrite_rkind_4_rank_7'
/usr/bin/ld: writer.f90:(.text+0xb13): undefined reference to `__h5global_MOD_h5t_native_double'
/usr/bin/ld: writer.f90:(.text+0xb6b): undefined reference to `__h5global_MOD_h5t_native_double'
/usr/bin/ld: writer.f90:(.text+0xb76): undefined reference to `__h5_gen_MOD_h5dwrite_rkind_8_rank_7'
/usr/bin/ld: writer.f90:(.text+0xeee): undefined reference to `__h5global_MOD_h5t_native_integer'
/usr/bin/ld: writer.f90:(.text+0xf4e): undefined reference to `__h5global_MOD_h5t_native_integer'
/usr/bin/ld: writer.f90:(.text+0xf59): undefined reference to `__h5_gen_MOD_h5dwrite_ikind_4_rank_7'
/usr/bin/ld: ./h5fortran/build//libh5fortran.a(writer.f90.o): in function `__h5fortran_MOD_hdf_write_6d':
writer.f90:(.text+0x15cb): undefined reference to `__h5global_MOD_h5t_native_real'
/usr/bin/ld: writer.f90:(.text+0x161d): undefined reference to `__h5global_MOD_h5t_native_real'
/usr/bin/ld: writer.f90:(.text+0x1628): undefined reference to `__h5_gen_MOD_h5dwrite_rkind_4_rank_6'
/usr/bin/ld: writer.f90:(.text+0x191d): undefined reference to `__h5global_MOD_h5t_native_double'
/usr/bin/ld: writer.f90:(.text+0x1972): undefined reference to `__h5global_MOD_h5t_native_double'
/usr/bin/ld: writer.f90:(.text+0x197d): undefined reference to `__h5_gen_MOD_h5dwrite_rkind_8_rank_6'
/usr/bin/ld: writer.f90:(.text+0x1cb3): undefined reference to `__h5global_MOD_h5t_native_integer'
/usr/bin/ld: writer.f90:(.text+0x1d10): undefined reference to `__h5global_MOD_h5t_native_integer'
/usr/bin/ld: writer.f90:(.text+0x1d1b): undefined reference to `__h5_gen_MOD_h5dwrite_ikind_4_rank_6'
/usr/bin/ld: ./h5fortran/build//libh5fortran.a(writer.f90.o): in function `__h5fortran_MOD_hdf_write_5d':
writer.f90:(.text+0x22fa): undefined reference to `__h5global_MOD_h5t_native_real'
/usr/bin/ld: writer.f90:(.text+0x234b): undefined reference to `__h5global_MOD_h5t_native_real'
/usr/bin/ld: writer.f90:(.text+0x2356): undefined reference to `__h5_gen_MOD_h5dwrite_rkind_4_rank_5'
/usr/bin/ld: writer.f90:(.text+0x2624): undefined reference to `__h5global_MOD_h5t_native_double'
/usr/bin/ld: writer.f90:(.text+0x2671): undefined reference to `__h5global_MOD_h5t_native_double'
/usr/bin/ld: writer.f90:(.text+0x267c): undefined reference to `__h5_gen_MOD_h5dwrite_rkind_8_rank_5'
/usr/bin/ld: writer.f90:(.text+0x2987): undefined reference to `__h5global_MOD_h5t_native_integer'
/usr/bin/ld: writer.f90:(.text+0x29d9): undefined reference to `__h5global_MOD_h5t_native_integer'
/usr/bin/ld: writer.f90:(.text+0x29e4): undefined reference to `__h5_gen_MOD_h5dwrite_ikind_4_rank_5'
/usr/bin/ld: ./h5fortran/build//libh5fortran.a(writer.f90.o): in function `__h5fortran_MOD_hdf_write_4d':
writer.f90:(.text+0x2ea1): undefined reference to `__h5global_MOD_h5t_native_real'
/usr/bin/ld: writer.f90:(.text+0x2eee): undefined reference to `__h5global_MOD_h5t_native_real'
/usr/bin/ld: writer.f90:(.text+0x2efe): undefined reference to `__h5_gen_MOD_h5dwrite_rkind_4_rank_4'
/usr/bin/ld: writer.f90:(.text+0x30e5): undefined reference to `__h5global_MOD_h5t_native_double'
/usr/bin/ld: writer.f90:(.text+0x3136): undefined reference to `__h5global_MOD_h5t_native_double'
/usr/bin/ld: writer.f90:(.text+0x3146): undefined reference to `__h5_gen_MOD_h5dwrite_rkind_8_rank_4'
/usr/bin/ld: writer.f90:(.text+0x3384): undefined reference to `__h5global_MOD_h5t_native_integer'
/usr/bin/ld: writer.f90:(.text+0x33cd): undefined reference to `__h5global_MOD_h5t_native_integer'
/usr/bin/ld: writer.f90:(.text+0x33dd): undefined reference to `__h5_gen_MOD_h5dwrite_ikind_4_rank_4'
/usr/bin/ld: ./h5fortran/build//libh5fortran.a(writer.f90.o): in function `__h5fortran_MOD_hdf_write_3d':
writer.f90:(.text+0x382e): undefined reference to `__h5global_MOD_h5t_native_real'
/usr/bin/ld: writer.f90:(.text+0x3879): undefined reference to `__h5global_MOD_h5t_native_real'
/usr/bin/ld: writer.f90:(.text+0x3889): undefined reference to `__h5_gen_MOD_h5dwrite_rkind_4_rank_3'
/usr/bin/ld: writer.f90:(.text+0x3a4a): undefined reference to `__h5global_MOD_h5t_native_double'
/usr/bin/ld: writer.f90:(.text+0x3a99): undefined reference to `__h5global_MOD_h5t_native_double'
/usr/bin/ld: writer.f90:(.text+0x3aa9): undefined reference to `__h5_gen_MOD_h5dwrite_rkind_8_rank_3'
/usr/bin/ld: writer.f90:(.text+0x3cb9): undefined reference to `__h5global_MOD_h5t_native_integer'
/usr/bin/ld: writer.f90:(.text+0x3d03): undefined reference to `__h5global_MOD_h5t_native_integer'
/usr/bin/ld: writer.f90:(.text+0x3d13): undefined reference to `__h5_gen_MOD_h5dwrite_ikind_4_rank_3'
/usr/bin/ld: ./h5fortran/build//libh5fortran.a(writer.f90.o): in function `__h5fortran_MOD_hdf_write_2d':
writer.f90:(.text+0x4105): undefined reference to `__h5global_MOD_h5t_native_real'
/usr/bin/ld: writer.f90:(.text+0x4152): undefined reference to `__h5global_MOD_h5t_native_real'
/usr/bin/ld: writer.f90:(.text+0x4162): undefined reference to `__h5_gen_MOD_h5dwrite_rkind_4_rank_2'
/usr/bin/ld: writer.f90:(.text+0x42fe): undefined reference to `__h5global_MOD_h5t_native_double'
/usr/bin/ld: writer.f90:(.text+0x4348): undefined reference to `__h5global_MOD_h5t_native_double'
/usr/bin/ld: writer.f90:(.text+0x4358): undefined reference to `__h5_gen_MOD_h5dwrite_rkind_8_rank_2'
/usr/bin/ld: writer.f90:(.text+0x4543): undefined reference to `__h5global_MOD_h5t_native_integer'
/usr/bin/ld: writer.f90:(.text+0x458a): undefined reference to `__h5global_MOD_h5t_native_integer'
/usr/bin/ld: writer.f90:(.text+0x459a): undefined reference to `__h5_gen_MOD_h5dwrite_ikind_4_rank_2'
/usr/bin/ld: ./h5fortran/build//libh5fortran.a(writer.f90.o): in function `__h5fortran_MOD_hdf_write_1d':
writer.f90:(.text+0x4919): undefined reference to `__h5global_MOD_h5t_native_real'
/usr/bin/ld: writer.f90:(.text+0x4981): undefined reference to `__h5global_MOD_h5t_native_real'
/usr/bin/ld: writer.f90:(.text+0x499b): undefined reference to `__h5_gen_MOD_h5dwrite_rkind_4_rank_1'
/usr/bin/ld: writer.f90:(.text+0x4b19): undefined reference to `__h5global_MOD_h5t_native_double'
/usr/bin/ld: writer.f90:(.text+0x4b7c): undefined reference to `__h5global_MOD_h5t_native_double'
/usr/bin/ld: writer.f90:(.text+0x4b96): undefined reference to `__h5_gen_MOD_h5dwrite_rkind_8_rank_1'
/usr/bin/ld: writer.f90:(.text+0x4d6a): undefined reference to `__h5global_MOD_h5t_native_integer'
/usr/bin/ld: writer.f90:(.text+0x4dcf): undefined reference to `__h5global_MOD_h5t_native_integer'
/usr/bin/ld: writer.f90:(.text+0x4de9): undefined reference to `__h5_gen_MOD_h5dwrite_ikind_4_rank_1'
/usr/bin/ld: ./h5fortran/build//libh5fortran.a(writer.f90.o): in function `__h5fortran_MOD_hdf_write_scalar':
writer.f90:(.text+0x4f6f): undefined reference to `__h5lt_const_MOD_h5ltmake_dataset_string_f'
/usr/bin/ld: writer.f90:(.text+0x4fdb): undefined reference to `__h5global_MOD_h5t_native_integer'
/usr/bin/ld: writer.f90:(.text+0x5070): undefined reference to `__h5global_MOD_h5t_native_double'
/usr/bin/ld: writer.f90:(.text+0x50c7): undefined reference to `__h5global_MOD_h5t_native_double'
/usr/bin/ld: writer.f90:(.text+0x50d1): undefined reference to `__h5_gen_MOD_h5dwrite_rkind_8_rank_0'
/usr/bin/ld: writer.f90:(.text+0x5130): undefined reference to `__h5global_MOD_h5t_native_real'
/usr/bin/ld: writer.f90:(.text+0x5189): undefined reference to `__h5global_MOD_h5t_native_real'
/usr/bin/ld: writer.f90:(.text+0x5193): undefined reference to `__h5_gen_MOD_h5dwrite_rkind_4_rank_0'
/usr/bin/ld: writer.f90:(.text+0x51cd): undefined reference to `__h5global_MOD_h5t_native_integer'
/usr/bin/ld: writer.f90:(.text+0x51d7): undefined reference to `__h5_gen_MOD_h5dwrite_ikind_4_rank_0'
/usr/bin/ld: ./h5fortran/build//libh5fortran.a(attributes.f90.o): in function `__h5fortran.attributes_MOD_attr_shape_check':
attributes.f90:(.text+0x9d): undefined reference to `__h5lt_const_MOD_h5ltget_attribute_ndims_f'
/usr/bin/ld: attributes.f90:(.text+0x54b): undefined reference to `__h5lt_const_MOD_h5ltget_attribute_info_f'
/usr/bin/ld: ./h5fortran/build//libh5fortran.a(attributes.f90.o): in function `__h5fortran_MOD_writeattr_num':
attributes.f90:(.text+0x9f6): undefined reference to `__h5lt_const_MOD_h5ltset_attribute_float_f'
/usr/bin/ld: attributes.f90:(.text+0xaae): undefined reference to `__h5lt_const_MOD_h5ltset_attribute_double_f'
/usr/bin/ld: attributes.f90:(.text+0xb48): undefined reference to `__h5lt_const_MOD_h5ltset_attribute_int_f'
/usr/bin/ld: ./h5fortran/build//libh5fortran.a(attributes.f90.o): in function `__h5fortran_MOD_writeattr_char':
attributes.f90:(.text+0xbc4): undefined reference to `__h5lt_const_MOD_h5ltset_attribute_string_f'
/usr/bin/ld: ./h5fortran/build//libh5fortran.a(attributes.f90.o): in function `__h5fortran_MOD_readattr_num':
attributes.f90:(.text+0xf24): undefined reference to `__h5lt_const_MOD_h5ltget_attribute_float_f'
/usr/bin/ld: attributes.f90:(.text+0xfea): undefined reference to `__h5lt_const_MOD_h5ltget_attribute_double_f'
/usr/bin/ld: attributes.f90:(.text+0x109a): undefined reference to `__h5lt_const_MOD_h5ltget_attribute_int_f'
/usr/bin/ld: ./h5fortran/build//libh5fortran.a(attributes.f90.o): in function `__h5fortran_MOD_readattr_char':
attributes.f90:(.text+0x1137): undefined reference to `__h5lt_const_MOD_h5ltget_attribute_string_f'
collect2: error: ld returned 1 exit status

What I'm missing? How can I fix it?

My system:

scivision commented 4 years ago

You need the HDF5 libraries as well. Look at the example CMake project as this will work across operating systems and compilers. Otherwise you'll have quite a long command line each time.

scivision commented 4 years ago

another choice would be using the HDF5 compiler wrapper if available. On Ubuntu 20.04 it's like

$ h5fc -show

gfortran -I/usr/include/hdf5/serial -L/usr/lib/x86_64-linux-gnu/hdf5/serial /usr/lib/x86_64-linux-gnu/hdf5/serial/libhdf5hl_fortran.a /usr/lib/x86_64-linux-gnu/hdf5/serial/libhdf5_hl.a /usr/lib/x86_64-linux-gnu/hdf5/serial/libhdf5_fortran.a /usr/lib/x86_64-linux-gnu/hdf5/serial/libhdf5.a -lpthread -lsz -lz -ldl -lm -Wl,-rpath -Wl,/usr/lib/x86_64-linux-gnu/hdf5/serial
scivision commented 4 years ago

I added documented example https://github.com/geospace-code/h5fortran/tree/master/Examples/#Readme for this as this issue is general to any HDF5 program

nyckmaia commented 4 years ago

Thank you @scivision for your quick response!

Could you help me a little bit more?

I know that you recommend to use CMake, but first I would like to try build using the Ubuntu console. So, what I did: 1- Compile the fortran file using -c flag to generate a *.o file. Done ok! 2- Compile de main C++ program using -c flag as well. Done ok! 3- Copied the full command line showed when I ran h5fc -show 4- Added the include and library directory of the h5fortran build folder

-I ./h5fortran/build/include/ -L ./h5fortran/build/ 

5- Added the -lh5fortran in the final of the linker line 6- Try to link using g++

So, the final command line is:

g++ app2.o f_test.o -o app2 -I ./h5fortran/build/include/ -L ./h5fortran/build/  -I/home/nyck/anaconda3/include -L/home/nyck/anaconda3/lib /home/nyck/anaconda3/lib/libhdf5hl_fortran.a /home/nyck/anaconda3/lib/libhdf5_hl.a /home/nyck/anaconda3/lib/libhdf5_fortran.a /home/nyck/anaconda3/lib/libhdf5.a -L/home/nyck/anaconda3/lib -Wl,-O2 -Wl,--sort-common -Wl,--as-needed -Wl,-z,relro -Wl,-z,now -Wl,--disable-new-dtags -Wl,-rpath,/home/nyck/anaconda3/lib -L/home/nyck/anaconda3/lib -lrt -lpthread -lz -ldl -lm -Wl,-rpath -Wl,/home/nyck/anaconda3/lib -lgfortran -lh5fortran

But I got this linker error:


/usr/bin/ld: ./h5fortran/build//libh5fortran.a(interface.f90.o): in function `__h5fortran_MOD_hdf_get_slice':
interface.f90:(.text+0x783): undefined reference to `__h5d_MOD_h5dopen_f'
/usr/bin/ld: interface.f90:(.text+0x7cc): undefined reference to `_gfortran_st_write'
/usr/bin/ld: interface.f90:(.text+0x7e0): undefined reference to `_gfortran_transfer_character_write'
/usr/bin/ld: interface.f90:(.text+0x7f2): undefined reference to `_gfortran_transfer_character_write'
/usr/bin/ld: interface.f90:(.text+0x842): undefined reference to `_gfortran_st_write'
/usr/bin/ld: interface.f90:(.text+0x856): undefined reference to `_gfortran_transfer_character_write'
/usr/bin/ld: interface.f90:(.text+0x868): undefined reference to `_gfortran_transfer_character_write'
/usr/bin/ld: interface.f90:(.text+0x87c): undefined reference to `_gfortran_transfer_character_write'
/usr/bin/ld: interface.f90:(.text+0x884): undefined reference to `_gfortran_st_write_done'
/usr/bin/ld: interface.f90:(.text+0xa93): undefined reference to `_gfortran_st_write'
/usr/bin/ld: interface.f90:(.text+0xaa7): undefined reference to `_gfortran_transfer_character_write'
/usr/bin/ld: interface.f90:(.text+0xb25): undefined reference to `_gfortran_transfer_array_write'
/usr/bin/ld: interface.f90:(.text+0xb2d): undefined reference to `_gfortran_st_write_done'
/usr/bin/ld: interface.f90:(.text+0xbc2): undefined reference to `_gfortran_st_write'
/usr/bin/ld: interface.f90:(.text+0xbf3): undefined reference to `__h5d_MOD_h5dget_space_f'
/usr/bin/ld: interface.f90:(.text+0xc8b): undefined reference to `__h5global_MOD_h5s_select_set_f'
/usr/bin/ld: interface.f90:(.text+0xc99): undefined reference to `__h5s_MOD_h5sselect_hyperslab_f'
/usr/bin/ld: interface.f90:(.text+0xcc5): undefined reference to `__h5s_MOD_h5screate_simple_f'
/usr/bin/ld: interface.f90:(.text+0xe9d): undefined reference to `_gfortran_st_write'
/usr/bin/ld: interface.f90:(.text+0xf52): undefined reference to `_gfortran_st_write'
/usr/bin/ld: interface.f90:(.text+0x101f): undefined reference to `_gfortran_error_stop_string'
/usr/bin/ld: ./h5fortran/build//libh5fortran.a(interface.f90.o): in function `__h5fortran_MOD_check':
interface.f90:(.text+0x10fa): undefined reference to `_gfortran_st_write'
/usr/bin/ld: interface.f90:(.text+0x112c): undefined reference to `_gfortran_concat_string'
/usr/bin/ld: interface.f90:(.text+0x1162): undefined reference to `_gfortran_concat_string'
/usr/bin/ld: interface.f90:(.text+0x11a5): undefined reference to `_gfortran_concat_string'
/usr/bin/ld: interface.f90:(.text+0x11e0): undefined reference to `_gfortran_concat_string'
/usr/bin/ld: interface.f90:(.text+0x1200): undefined reference to `_gfortran_transfer_character_write'
/usr/bin/ld: interface.f90:(.text+0x1224): undefined reference to `_gfortran_transfer_integer_write'
/usr/bin/ld: interface.f90:(.text+0x1237): undefined reference to `_gfortran_st_write_done'
/usr/bin/ld: interface.f90:(.text+0x12d6): undefined reference to `_gfortran_st_write'
/usr/bin/ld: interface.f90:(.text+0x130f): undefined reference to `_gfortran_concat_string'
/usr/bin/ld: interface.f90:(.text+0x134c): undefined reference to `_gfortran_concat_string'
/usr/bin/ld: interface.f90:(.text+0x1393): undefined reference to `_gfortran_concat_string'
/usr/bin/ld: interface.f90:(.text+0x13db): undefined reference to `_gfortran_concat_string'
/usr/bin/ld: interface.f90:(.text+0x1400): undefined reference to `_gfortran_transfer_character_write'
/usr/bin/ld: interface.f90:(.text+0x141b): undefined reference to `_gfortran_st_write_done'
/usr/bin/ld: interface.f90:(.text+0x148c): undefined reference to `_gfortran_st_write'
/usr/bin/ld: interface.f90:(.text+0x14c9): undefined reference to `_gfortran_concat_string'
/usr/bin/ld: interface.f90:(.text+0x14ff): undefined reference to `_gfortran_concat_string'
/usr/bin/ld: interface.f90:(.text+0x1515): undefined reference to `_gfortran_transfer_character_write'
/usr/bin/ld: interface.f90:(.text+0x1525): undefined reference to `_gfortran_st_write_done'
/usr/bin/ld: ./h5fortran/build//libh5fortran.a(interface.f90.o): in function `__h5fortran_MOD_hdf_shape_check':
interface.f90:(.text+0x1645): undefined reference to `__h5lt_const_MOD_h5ltget_dataset_ndims_f'
/usr/bin/ld: interface.f90:(.text+0x1682): undefined reference to `_gfortran_concat_string'
/usr/bin/ld: interface.f90:(.text+0x16c2): undefined reference to `_gfortran_concat_string'
/usr/bin/ld: interface.f90:(.text+0x1717): undefined reference to `_gfortran_concat_string'
/usr/bin/ld: interface.f90:(.text+0x17c3): undefined reference to `_gfortran_st_write'
/usr/bin/ld: interface.f90:(.text+0x17f3): undefined reference to `_gfortran_concat_string'
/usr/bin/ld: interface.f90:(.text+0x181e): undefined reference to `_gfortran_concat_string'
/usr/bin/ld: interface.f90:(.text+0x1834): undefined reference to `_gfortran_transfer_character_write'
/usr/bin/ld: interface.f90:(.text+0x184e): undefined reference to `_gfortran_transfer_integer_write'
/usr/bin/ld: interface.f90:(.text+0x1862): undefined reference to `_gfortran_transfer_character_write'
/usr/bin/ld: interface.f90:(.text+0x1882): undefined reference to `_gfortran_transfer_integer_write'
/usr/bin/ld: interface.f90:(.text+0x188a): undefined reference to `_gfortran_st_write_done'
/usr/bin/ld: interface.f90:(.text+0x1902): undefined reference to `_gfortran_st_write'
/usr/bin/ld: interface.f90:(.text+0x193f): undefined reference to `_gfortran_concat_string'
/usr/bin/ld: interface.f90:(.text+0x1975): undefined reference to `_gfortran_concat_string'
/usr/bin/ld: interface.f90:(.text+0x19b4): undefined reference to `_gfortran_concat_string'
/usr/bin/ld: interface.f90:(.text+0x19ce): undefined reference to `_gfortran_transfer_character_write'
/usr/bin/ld: interface.f90:(.text+0x19de): undefined reference to `_gfortran_st_write_done'
/usr/bin/ld: interface.f90:(.text+0x1a20): undefined reference to `__h5lt_const_MOD_h5ltget_dataset_info_f'
/usr/bin/ld: interface.f90:(.text+0x1a4c): undefined reference to `_gfortran_concat_string'
/usr/bin/ld: interface.f90:(.text+0x1a81): undefined reference to `_gfortran_concat_string'
/usr/bin/ld: interface.f90:(.text+0x1acf): undefined reference to `_gfortran_concat_string'
/usr/bin/ld: interface.f90:(.text+0x1b91): undefined reference to `_gfortran_st_write'
/usr/bin/ld: interface.f90:(.text+0x1bc1): undefined reference to `_gfortran_concat_string'
/usr/bin/ld: interface.f90:(.text+0x1bf2): undefined reference to `_gfortran_concat_string'
/usr/bin/ld: interface.f90:(.text+0x1c08): undefined reference to `_gfortran_transfer_character_write'
/usr/bin/ld: interface.f90:(.text+0x1c99): undefined reference to `_gfortran_transfer_array_write'
/usr/bin/ld: interface.f90:(.text+0x1cad): undefined reference to `_gfortran_transfer_character_write'
/usr/bin/ld: interface.f90:(.text+0x1d30): undefined reference to `_gfortran_transfer_array_write'
/usr/bin/ld: interface.f90:(.text+0x1d38): undefined reference to `_gfortran_st_write_done'
/usr/bin/ld: interface.f90:(.text+0x1d9c): undefined reference to `_gfortran_error_stop_string'
/usr/bin/ld: ./h5fortran/build//libh5fortran.a(interface.f90.o): in function `__h5fortran_MOD_hdf_wrapup':
interface.f90:(.text+0x1dba): undefined reference to `__h5s_MOD_h5sclose_f'
/usr/bin/ld: interface.f90:(.text+0x1de2): undefined reference to `__h5d_MOD_h5dclose_f'
/usr/bin/ld: ./h5fortran/build//libh5fortran.a(interface.f90.o): in function `__h5fortran_MOD_write_group':
interface.f90:(.text+0x1e89): undefined reference to `_gfortran_string_index'
/usr/bin/ld: interface.f90:(.text+0x1eca): undefined reference to `__h5l_MOD_h5lexists_f'
/usr/bin/ld: interface.f90:(.text+0x1f2e): undefined reference to `__h5g_MOD_h5gcreate_f'
/usr/bin/ld: interface.f90:(.text+0x1f73): undefined reference to `__h5g_MOD_h5gclose_f'
/usr/bin/ld: interface.f90:(.text+0x1fcb): undefined reference to `_gfortran_error_stop_string'
/usr/bin/ld: interface.f90:(.text+0x1fd6): undefined reference to `_gfortran_error_stop_string'
/usr/bin/ld: ./h5fortran/build//libh5fortran.a(interface.f90.o): in function `__h5fortran_MOD_hdf_flush':
interface.f90:(.text+0x1fed): undefined reference to `__h5global_MOD_h5f_scope_global_f'
/usr/bin/ld: interface.f90:(.text+0x2006): undefined reference to `__h5f_MOD_h5fflush_f'
/usr/bin/ld: interface.f90:(.text+0x204b): undefined reference to `_gfortran_concat_string'
/usr/bin/ld: interface.f90:(.text+0x20b5): undefined reference to `_gfortran_concat_string'
/usr/bin/ld: interface.f90:(.text+0x20f3): undefined reference to `_gfortran_error_stop_string'
/usr/bin/ld: ./h5fortran/build//libh5fortran.a(interface.f90.o): in function `__h5fortran_MOD_hdf_finalize':
interface.f90:(.text+0x2137): undefined reference to `__h5f_MOD_h5fclose_f'
/usr/bin/ld: interface.f90:(.text+0x2195): undefined reference to `_gfortran_concat_string'
/usr/bin/ld: interface.f90:(.text+0x2206): undefined reference to `_gfortran_st_write'
/usr/bin/ld: interface.f90:(.text+0x2242): undefined reference to `_gfortran_concat_string'
/usr/bin/ld: interface.f90:(.text+0x2258): undefined reference to `_gfortran_transfer_character_write'
/usr/bin/ld: interface.f90:(.text+0x2268): undefined reference to `_gfortran_st_write_done'
/usr/bin/ld: interface.f90:(.text+0x22c2): undefined reference to `_gfortran_concat_string'
/usr/bin/ld: interface.f90:(.text+0x233c): undefined reference to `__h5lib_MOD_h5close_f'
/usr/bin/ld: interface.f90:(.text+0x2398): undefined reference to `_gfortran_error_stop_string'
/usr/bin/ld: interface.f90:(.text+0x23c6): undefined reference to `_gfortran_st_write'
/usr/bin/ld: interface.f90:(.text+0x2402): undefined reference to `_gfortran_concat_string'
/usr/bin/ld: interface.f90:(.text+0x2418): undefined reference to `_gfortran_transfer_character_write'
/usr/bin/ld: interface.f90:(.text+0x2428): undefined reference to `_gfortran_st_write_done'
/usr/bin/ld: ./h5fortran/build//libh5fortran.a(interface.f90.o): in function `__h5fortran_MOD_hdf_initialize':
interface.f90:(.text+0x24f7): undefined reference to `__h5lib_MOD_h5open_f'
/usr/bin/ld: interface.f90:(.text+0x25e4): undefined reference to `__h5lib_MOD_h5get_libversion_f'
/usr/bin/ld: interface.f90:(.text+0x2646): undefined reference to `__h5e_MOD_h5eset_auto_f'
/usr/bin/ld: interface.f90:(.text+0x2825): undefined reference to `_gfortran_select_string'
/usr/bin/ld: interface.f90:(.text+0x287a): undefined reference to `_gfortran_st_write'
/usr/bin/ld: interface.f90:(.text+0x28b6): undefined reference to `_gfortran_concat_string'
/usr/bin/ld: interface.f90:(.text+0x28cc): undefined reference to `_gfortran_transfer_character_write'
/usr/bin/ld: interface.f90:(.text+0x28dc): undefined reference to `_gfortran_st_write_done'
/usr/bin/ld: interface.f90:(.text+0x293d): undefined reference to `_gfortran_st_write'
/usr/bin/ld: interface.f90:(.text+0x2953): undefined reference to `_gfortran_transfer_character_write'
/usr/bin/ld: interface.f90:(.text+0x29c4): undefined reference to `_gfortran_transfer_array_write'
/usr/bin/ld: interface.f90:(.text+0x29ce): undefined reference to `_gfortran_st_write_done'
/usr/bin/ld: interface.f90:(.text+0x2a08): undefined reference to `_gfortran_error_stop_string'
/usr/bin/ld: interface.f90:(.text+0x2a58): undefined reference to `__h5e_MOD_h5eset_auto_f'
/usr/bin/ld: interface.f90:(.text+0x2a74): undefined reference to `__h5global_MOD_h5f_acc_trunc_f'
/usr/bin/ld: interface.f90:(.text+0x2a89): undefined reference to `__h5f_MOD_h5fcreate_f'
/usr/bin/ld: interface.f90:(.text+0x2b05): undefined reference to `_gfortran_select_string'
/usr/bin/ld: interface.f90:(.text+0x2b3d): undefined reference to `__h5global_MOD_h5f_acc_trunc_f'
/usr/bin/ld: interface.f90:(.text+0x2b45): undefined reference to `__h5f_MOD_h5fcreate_f'
/usr/bin/ld: interface.f90:(.text+0x2beb): undefined reference to `_gfortran_concat_string'
/usr/bin/ld: interface.f90:(.text+0x2c49): undefined reference to `_gfortran_concat_string'
/usr/bin/ld: interface.f90:(.text+0x2d3e): undefined reference to `_gfortran_st_inquire'
/usr/bin/ld: interface.f90:(.text+0x2d61): undefined reference to `__h5f_MOD_h5fis_hdf5_f'
/usr/bin/ld: interface.f90:(.text+0x2d97): undefined reference to `__h5global_MOD_h5f_acc_rdwr_f'
/usr/bin/ld: interface.f90:(.text+0x2d9f): undefined reference to `__h5f_MOD_h5fopen_f'
/usr/bin/ld: interface.f90:(.text+0x2dbb): undefined reference to `__h5global_MOD_h5f_acc_rdonly_f'
/usr/bin/ld: interface.f90:(.text+0x2dc3): undefined reference to `__h5f_MOD_h5fopen_f'
/usr/bin/ld: interface.f90:(.text+0x2f28): undefined reference to `_gfortran_st_write'
/usr/bin/ld: interface.f90:(.text+0x2f59): undefined reference to `_gfortran_concat_string'
/usr/bin/ld: interface.f90:(.text+0x2f67): undefined reference to `_gfortran_transfer_character_write'
/usr/bin/ld: interface.f90:(.text+0x2f77): undefined reference to `_gfortran_st_write_done'
/usr/bin/ld: interface.f90:(.text+0x2f83): undefined reference to `_gfortran_error_stop_numeric'
/usr/bin/ld: interface.f90:(.text+0x2fb9): undefined reference to `_gfortran_st_write'
/usr/bin/ld: interface.f90:(.text+0x2fec): undefined reference to `_gfortran_concat_string'
/usr/bin/ld: ./h5fortran/build//libh5fortran.a(interface.f90.o): in function `__h5fortran_MOD_is_hdf5':
interface.f90:(.text+0x3061): undefined reference to `_gfortran_st_inquire'
/usr/bin/ld: interface.f90:(.text+0x308d): undefined reference to `__h5f_MOD_h5fis_hdf5_f'
/usr/bin/ld: ./h5fortran/build//libh5fortran.a(interface.f90.o): in function `__h5fortran_MOD_hdf5_close':
interface.f90:(.text+0x30c2): undefined reference to `__h5lib_MOD_h5close_f'
/usr/bin/ld: interface.f90:(.text+0x311c): undefined reference to `_gfortran_error_stop_string'
/usr/bin/ld: ./h5fortran/build//libh5fortran.a(read.f90.o): in function `__h5fortran_MOD_hdf_check_exist':
read.f90:(.text+0x52): undefined reference to `__h5lt_const_MOD_h5ltpath_valid_f'
/usr/bin/ld: read.f90:(.text+0xa6): undefined reference to `_gfortran_st_write'
/usr/bin/ld: read.f90:(.text+0xba): undefined reference to `_gfortran_transfer_character_write'
/usr/bin/ld: read.f90:(.text+0xc2): undefined reference to `_gfortran_st_write_done'
/usr/bin/ld: read.f90:(.text+0xf6): undefined reference to `_gfortran_st_write'
/usr/bin/ld: read.f90:(.text+0x131): undefined reference to `_gfortran_concat_string'
/usr/bin/ld: read.f90:(.text+0x145): undefined reference to `_gfortran_transfer_character_write'
/usr/bin/ld: read.f90:(.text+0x155): undefined reference to `_gfortran_st_write_done'
/usr/bin/ld: read.f90:(.text+0x186): undefined reference to `_gfortran_st_write'
/usr/bin/ld: read.f90:(.text+0x1c5): undefined reference to `_gfortran_concat_string'
/usr/bin/ld: read.f90:(.text+0x1fd): undefined reference to `_gfortran_concat_string'
/usr/bin/ld: read.f90:(.text+0x240): undefined reference to `_gfortran_concat_string'
/usr/bin/ld: read.f90:(.text+0x25b): undefined reference to `_gfortran_transfer_character_write'
/usr/bin/ld: read.f90:(.text+0x26b): undefined reference to `_gfortran_st_write_done'
/usr/bin/ld: ./h5fortran/build//libh5fortran.a(read.f90.o): in function `__h5fortran_MOD_hdf_is_chunked':
read.f90:(.text+0x290): undefined reference to `__h5global_MOD_h5d_chunked_f'
/usr/bin/ld: ./h5fortran/build//libh5fortran.a(read.f90.o): in function `__h5fortran_MOD_hdf_is_contig':
read.f90:(.text+0x2b0): undefined reference to `__h5global_MOD_h5d_contiguous_f'
/usr/bin/ld: ./h5fortran/build//libh5fortran.a(read.f90.o): in function `__h5fortran_MOD_hdf_get_layout':
read.f90:(.text+0x321): undefined reference to `__h5d_MOD_h5dopen_f'
/usr/bin/ld: read.f90:(.text+0x365): undefined reference to `_gfortran_concat_string'
/usr/bin/ld: read.f90:(.text+0x3a2): undefined reference to `_gfortran_concat_string'
/usr/bin/ld: read.f90:(.text+0x3f5): undefined reference to `_gfortran_concat_string'
/usr/bin/ld: read.f90:(.text+0x44f): undefined reference to `__h5d_MOD_h5dget_create_plist_f'
/usr/bin/ld: read.f90:(.text+0x489): undefined reference to `_gfortran_concat_string'
/usr/bin/ld: read.f90:(.text+0x4c3): undefined reference to `_gfortran_concat_string'
/usr/bin/ld: read.f90:(.text+0x519): undefined reference to `_gfortran_concat_string'
/usr/bin/ld: read.f90:(.text+0x566): undefined reference to `__h5p_MOD_h5pget_layout_f'
/usr/bin/ld: read.f90:(.text+0x5aa): undefined reference to `_gfortran_concat_string'
/usr/bin/ld: read.f90:(.text+0x5e7): undefined reference to `_gfortran_concat_string'
/usr/bin/ld: read.f90:(.text+0x63a): undefined reference to `_gfortran_concat_string'
/usr/bin/ld: read.f90:(.text+0x69c): undefined reference to `__h5d_MOD_h5dclose_f'
/usr/bin/ld: read.f90:(.text+0x6ce): undefined reference to `_gfortran_concat_string'
/usr/bin/ld: read.f90:(.text+0x701): undefined reference to `_gfortran_concat_string'
/usr/bin/ld: read.f90:(.text+0x743): undefined reference to `_gfortran_concat_string'
/usr/bin/ld: read.f90:(.text+0x7b1): undefined reference to `_gfortran_st_write'
/usr/bin/ld: read.f90:(.text+0x7e3): undefined reference to `_gfortran_concat_string'
/usr/bin/ld: read.f90:(.text+0x816): undefined reference to `_gfortran_concat_string'
/usr/bin/ld: read.f90:(.text+0x858): undefined reference to `_gfortran_concat_string'
/usr/bin/ld: read.f90:(.text+0x872): undefined reference to `_gfortran_transfer_character_write'
/usr/bin/ld: read.f90:(.text+0x882): undefined reference to `_gfortran_st_write_done'
/usr/bin/ld: read.f90:(.text+0x89f): undefined reference to `_gfortran_error_stop_string'
/usr/bin/ld: ./h5fortran/build//libh5fortran.a(read.f90.o): in function `__h5fortran_MOD_hdf_get_chunk':
read.f90:(.text+0x9be): undefined reference to `__h5lt_const_MOD_h5ltget_dataset_ndims_f'
/usr/bin/ld: read.f90:(.text+0xa05): undefined reference to `_gfortran_concat_string'
/usr/bin/ld: read.f90:(.text+0xa45): undefined reference to `_gfortran_concat_string'
/usr/bin/ld: read.f90:(.text+0xa9c): undefined reference to `_gfortran_concat_string'
/usr/bin/ld: read.f90:(.text+0xb07): undefined reference to `__h5d_MOD_h5dopen_f'
/usr/bin/ld: read.f90:(.text+0xb4b): undefined reference to `_gfortran_concat_string'
/usr/bin/ld: read.f90:(.text+0xb88): undefined reference to `_gfortran_concat_string'
/usr/bin/ld: read.f90:(.text+0xbdc): undefined reference to `_gfortran_concat_string'
/usr/bin/ld: read.f90:(.text+0xc3e): undefined reference to `__h5d_MOD_h5dget_create_plist_f'
/usr/bin/ld: read.f90:(.text+0xc80): undefined reference to `_gfortran_concat_string'
/usr/bin/ld: read.f90:(.text+0xcba): undefined reference to `_gfortran_concat_string'
/usr/bin/ld: read.f90:(.text+0xd11): undefined reference to `_gfortran_concat_string'
/usr/bin/ld: read.f90:(.text+0xdbe): undefined reference to `_gfortran_internal_pack'
/usr/bin/ld: read.f90:(.text+0xdd8): undefined reference to `__h5p_MOD_h5pget_chunk_f'
/usr/bin/ld: read.f90:(.text+0xdea): undefined reference to `_gfortran_internal_unpack'
/usr/bin/ld: read.f90:(.text+0xe28): undefined reference to `_gfortran_st_write'
/usr/bin/ld: read.f90:(.text+0xe65): undefined reference to `_gfortran_concat_string'
/usr/bin/ld: read.f90:(.text+0xe9c): undefined reference to `_gfortran_concat_string'
/usr/bin/ld: read.f90:(.text+0xedd): undefined reference to `_gfortran_concat_string'
/usr/bin/ld: read.f90:(.text+0xef8): undefined reference to `_gfortran_transfer_character_write'
/usr/bin/ld: read.f90:(.text+0xf08): undefined reference to `_gfortran_st_write_done'
/usr/bin/ld: read.f90:(.text+0xf41): undefined reference to `_gfortran_st_write'
/usr/bin/ld: read.f90:(.text+0xf7e): undefined reference to `_gfortran_concat_string'
/usr/bin/ld: read.f90:(.text+0xfb5): undefined reference to `_gfortran_concat_string'
/usr/bin/ld: read.f90:(.text+0xff6): undefined reference to `_gfortran_concat_string'
/usr/bin/ld: read.f90:(.text+0x1011): undefined reference to `_gfortran_transfer_character_write'
/usr/bin/ld: read.f90:(.text+0x1021): undefined reference to `_gfortran_st_write_done'
/usr/bin/ld: read.f90:(.text+0x1068): undefined reference to `__h5d_MOD_h5dclose_f'
/usr/bin/ld: read.f90:(.text+0x109d): undefined reference to `_gfortran_concat_string'
/usr/bin/ld: read.f90:(.text+0x10d3): undefined reference to `_gfortran_concat_string'
/usr/bin/ld: read.f90:(.text+0x1112): undefined reference to `_gfortran_concat_string'
/usr/bin/ld: read.f90:(.text+0x1160): undefined reference to `_gfortran_error_stop_string'
/usr/bin/ld: ./h5fortran/build//libh5fortran.a(read.f90.o): in function `__h5fortran_MOD_hdf_get_shape':
read.f90:(.text+0x11d6): undefined reference to `__h5lt_const_MOD_h5ltget_dataset_ndims_f'
/usr/bin/ld: read.f90:(.text+0x1281): undefined reference to `__h5lt_const_MOD_h5ltget_dataset_info_f'
/usr/bin/ld: read.f90:(.text+0x12cb): undefined reference to `_gfortran_st_write'
/usr/bin/ld: read.f90:(.text+0x1308): undefined reference to `_gfortran_concat_string'
/usr/bin/ld: read.f90:(.text+0x133e): undefined reference to `_gfortran_concat_string'
/usr/bin/ld: read.f90:(.text+0x137f): undefined reference to `_gfortran_concat_string'
/usr/bin/ld: read.f90:(.text+0x139a): undefined reference to `_gfortran_transfer_character_write'
/usr/bin/ld: read.f90:(.text+0x13aa): undefined reference to `_gfortran_st_write_done'
/usr/bin/ld: read.f90:(.text+0x13e7): undefined reference to `_gfortran_error_stop_string'
/usr/bin/ld: read.f90:(.text+0x13fa): undefined reference to `_gfortran_error_stop_string'
/usr/bin/ld: read.f90:(.text+0x1414): undefined reference to `_gfortran_runtime_error_at'
/usr/bin/ld: read.f90:(.text+0x1420): undefined reference to `_gfortran_os_error'
/usr/bin/ld: ./h5fortran/build//libh5fortran.a(read.f90.o): in function `__h5fortran_MOD_hdf_get_ndims':
read.f90:(.text+0x1497): undefined reference to `_gfortran_st_write'
/usr/bin/ld: read.f90:(.text+0x14c9): undefined reference to `_gfortran_concat_string'
/usr/bin/ld: read.f90:(.text+0x14fc): undefined reference to `_gfortran_concat_string'
/usr/bin/ld: read.f90:(.text+0x153e): undefined reference to `_gfortran_concat_string'
/usr/bin/ld: read.f90:(.text+0x1558): undefined reference to `_gfortran_transfer_character_write'
/usr/bin/ld: read.f90:(.text+0x1568): undefined reference to `_gfortran_st_write_done'
/usr/bin/ld: read.f90:(.text+0x159d): undefined reference to `__h5lt_const_MOD_h5ltget_dataset_ndims_f'
/usr/bin/ld: read.f90:(.text+0x15b6): undefined reference to `_gfortran_error_stop_string'
/usr/bin/ld: ./h5fortran/build//libh5fortran.a(reader.f90.o): in function `__h5fortran_MOD_hdf_read_7d':
reader.f90:(.text+0x76a): undefined reference to `__h5global_MOD_h5s_all_f'
/usr/bin/ld: reader.f90:(.text+0x95a): undefined reference to `_gfortran_shape_4'
/usr/bin/ld: reader.f90:(.text+0xd4c): undefined reference to `_gfortran_error_stop_string'
/usr/bin/ld: reader.f90:(.text+0xd98): undefined reference to `__h5d_MOD_h5dopen_f'
/usr/bin/ld: reader.f90:(.text+0x11d8): undefined reference to `_gfortran_internal_pack'
/usr/bin/ld: reader.f90:(.text+0x11e9): undefined reference to `__h5global_MOD_h5t_native_integer'
/usr/bin/ld: reader.f90:(.text+0x120e): undefined reference to `__h5_gen_MOD_h5dread_ikind_4_rank_7'
/usr/bin/ld: reader.f90:(.text+0x147c): undefined reference to `_gfortran_internal_pack'
/usr/bin/ld: reader.f90:(.text+0x149d): undefined reference to `__h5global_MOD_h5t_native_real'
/usr/bin/ld: reader.f90:(.text+0x14b2): undefined reference to `__h5_gen_MOD_h5dread_rkind_4_rank_7'
/usr/bin/ld: reader.f90:(.text+0x1722): undefined reference to `_gfortran_internal_pack'
/usr/bin/ld: reader.f90:(.text+0x1743): undefined reference to `__h5global_MOD_h5t_native_double'
/usr/bin/ld: reader.f90:(.text+0x1758): undefined reference to `__h5_gen_MOD_h5dread_rkind_8_rank_7'
/usr/bin/ld: reader.f90:(.text+0x176f): undefined reference to `_gfortran_internal_unpack'
/usr/bin/ld: ./h5fortran/build//libh5fortran.a(reader.f90.o): in function `__h5fortran_MOD_hdf_read_6d':
reader.f90:(.text+0x1de3): undefined reference to `__h5global_MOD_h5s_all_f'
/usr/bin/ld: reader.f90:(.text+0x1fa3): undefined reference to `_gfortran_shape_4'
/usr/bin/ld: reader.f90:(.text+0x234f): undefined reference to `_gfortran_error_stop_string'
/usr/bin/ld: reader.f90:(.text+0x23a0): undefined reference to `__h5d_MOD_h5dopen_f'
/usr/bin/ld: reader.f90:(.text+0x2796): undefined reference to `_gfortran_internal_pack'
/usr/bin/ld: reader.f90:(.text+0x27a7): undefined reference to `__h5global_MOD_h5t_native_integer'
/usr/bin/ld: reader.f90:(.text+0x27cc): undefined reference to `__h5_gen_MOD_h5dread_ikind_4_rank_6'
/usr/bin/ld: reader.f90:(.text+0x29f0): undefined reference to `_gfortran_internal_pack'
/usr/bin/ld: reader.f90:(.text+0x2a11): undefined reference to `__h5global_MOD_h5t_native_real'
/usr/bin/ld: reader.f90:(.text+0x2a26): undefined reference to `__h5_gen_MOD_h5dread_rkind_4_rank_6'
/usr/bin/ld: reader.f90:(.text+0x2c4c): undefined reference to `_gfortran_internal_pack'
/usr/bin/ld: reader.f90:(.text+0x2c6d): undefined reference to `__h5global_MOD_h5t_native_double'
/usr/bin/ld: reader.f90:(.text+0x2c82): undefined reference to `__h5_gen_MOD_h5dread_rkind_8_rank_6'
/usr/bin/ld: reader.f90:(.text+0x2c99): undefined reference to `_gfortran_internal_unpack'
/usr/bin/ld: ./h5fortran/build//libh5fortran.a(reader.f90.o): in function `__h5fortran_MOD_hdf_read_5d':
reader.f90:(.text+0x3248): undefined reference to `__h5global_MOD_h5s_all_f'
/usr/bin/ld: reader.f90:(.text+0x33e0): undefined reference to `_gfortran_shape_4'
/usr/bin/ld: reader.f90:(.text+0x3780): undefined reference to `_gfortran_error_stop_string'
/usr/bin/ld: reader.f90:(.text+0x37d0): undefined reference to `__h5d_MOD_h5dopen_f'
/usr/bin/ld: reader.f90:(.text+0x3b85): undefined reference to `_gfortran_internal_pack'
/usr/bin/ld: reader.f90:(.text+0x3b96): undefined reference to `__h5global_MOD_h5t_native_integer'
/usr/bin/ld: reader.f90:(.text+0x3bbb): undefined reference to `__h5_gen_MOD_h5dread_ikind_4_rank_5'
/usr/bin/ld: reader.f90:(.text+0x3d9e): undefined reference to `_gfortran_internal_pack'
/usr/bin/ld: reader.f90:(.text+0x3dbf): undefined reference to `__h5global_MOD_h5t_native_real'
/usr/bin/ld: reader.f90:(.text+0x3dd4): undefined reference to `__h5_gen_MOD_h5dread_rkind_4_rank_5'
/usr/bin/ld: reader.f90:(.text+0x3fb9): undefined reference to `_gfortran_internal_pack'
/usr/bin/ld: reader.f90:(.text+0x3fda): undefined reference to `__h5global_MOD_h5t_native_double'
/usr/bin/ld: reader.f90:(.text+0x3fef): undefined reference to `__h5_gen_MOD_h5dread_rkind_8_rank_5'
/usr/bin/ld: reader.f90:(.text+0x4006): undefined reference to `_gfortran_internal_unpack'
/usr/bin/ld: ./h5fortran/build//libh5fortran.a(reader.f90.o): in function `__h5fortran_MOD_hdf_read_4d':
reader.f90:(.text+0x44f0): undefined reference to `__h5global_MOD_h5s_all_f'
/usr/bin/ld: reader.f90:(.text+0x4640): undefined reference to `_gfortran_shape_4'
/usr/bin/ld: reader.f90:(.text+0x49e2): undefined reference to `__h5d_MOD_h5dopen_f'
/usr/bin/ld: reader.f90:(.text+0x4a95): undefined reference to `_gfortran_error_stop_string'
/usr/bin/ld: reader.f90:(.text+0x4ba8): undefined reference to `_gfortran_internal_pack'
/usr/bin/ld: reader.f90:(.text+0x4bc9): undefined reference to `__h5global_MOD_h5t_native_double'
/usr/bin/ld: reader.f90:(.text+0x4bdc): undefined reference to `__h5_gen_MOD_h5dread_rkind_8_rank_4'
/usr/bin/ld: reader.f90:(.text+0x4bf7): undefined reference to `_gfortran_internal_unpack'
/usr/bin/ld: reader.f90:(.text+0x4e6a): undefined reference to `_gfortran_internal_pack'
/usr/bin/ld: reader.f90:(.text+0x4e8b): undefined reference to `__h5global_MOD_h5t_native_integer'
/usr/bin/ld: reader.f90:(.text+0x4e9e): undefined reference to `__h5_gen_MOD_h5dread_ikind_4_rank_4'
/usr/bin/ld: reader.f90:(.text+0x4fa0): undefined reference to `_gfortran_internal_pack'
/usr/bin/ld: reader.f90:(.text+0x4fc4): undefined reference to `__h5global_MOD_h5t_native_real'
/usr/bin/ld: reader.f90:(.text+0x4fd4): undefined reference to `__h5_gen_MOD_h5dread_rkind_4_rank_4'
/usr/bin/ld: ./h5fortran/build//libh5fortran.a(reader.f90.o): in function `__h5fortran_MOD_hdf_read_3d':
reader.f90:(.text+0x53d5): undefined reference to `__h5global_MOD_h5s_all_f'
/usr/bin/ld: reader.f90:(.text+0x54f8): undefined reference to `_gfortran_shape_4'
/usr/bin/ld: reader.f90:(.text+0x58a1): undefined reference to `__h5d_MOD_h5dopen_f'
/usr/bin/ld: reader.f90:(.text+0x5917): undefined reference to `_gfortran_error_stop_string'
/usr/bin/ld: reader.f90:(.text+0x5b97): undefined reference to `_gfortran_internal_pack'
/usr/bin/ld: reader.f90:(.text+0x5bb8): undefined reference to `__h5global_MOD_h5t_native_double'
/usr/bin/ld: reader.f90:(.text+0x5bcb): undefined reference to `__h5_gen_MOD_h5dread_rkind_8_rank_3'
/usr/bin/ld: reader.f90:(.text+0x5be6): undefined reference to `_gfortran_internal_unpack'
/usr/bin/ld: reader.f90:(.text+0x5cd5): undefined reference to `_gfortran_internal_pack'
/usr/bin/ld: reader.f90:(.text+0x5cf6): undefined reference to `__h5global_MOD_h5t_native_integer'
/usr/bin/ld: reader.f90:(.text+0x5d09): undefined reference to `__h5_gen_MOD_h5dread_ikind_4_rank_3'
/usr/bin/ld: reader.f90:(.text+0x5de3): undefined reference to `_gfortran_internal_pack'
/usr/bin/ld: reader.f90:(.text+0x5e07): undefined reference to `__h5global_MOD_h5t_native_real'
/usr/bin/ld: reader.f90:(.text+0x5e17): undefined reference to `__h5_gen_MOD_h5dread_rkind_4_rank_3'
/usr/bin/ld: ./h5fortran/build//libh5fortran.a(reader.f90.o): in function `__h5fortran_MOD_hdf_read_2d':
reader.f90:(.text+0x6171): undefined reference to `__h5global_MOD_h5s_all_f'
/usr/bin/ld: reader.f90:(.text+0x6270): undefined reference to `_gfortran_shape_4'
/usr/bin/ld: reader.f90:(.text+0x65ed): undefined reference to `__h5d_MOD_h5dopen_f'
/usr/bin/ld: reader.f90:(.text+0x665d): undefined reference to `_gfortran_error_stop_string'
/usr/bin/ld: reader.f90:(.text+0x68b2): undefined reference to `_gfortran_internal_pack'
/usr/bin/ld: reader.f90:(.text+0x68d3): undefined reference to `__h5global_MOD_h5t_native_double'
/usr/bin/ld: reader.f90:(.text+0x68e6): undefined reference to `__h5_gen_MOD_h5dread_rkind_8_rank_2'
/usr/bin/ld: reader.f90:(.text+0x6901): undefined reference to `_gfortran_internal_unpack'
/usr/bin/ld: reader.f90:(.text+0x69c7): undefined reference to `_gfortran_internal_pack'
/usr/bin/ld: reader.f90:(.text+0x69eb): undefined reference to `__h5global_MOD_h5t_native_real'
/usr/bin/ld: reader.f90:(.text+0x69fb): undefined reference to `__h5_gen_MOD_h5dread_rkind_4_rank_2'
/usr/bin/ld: reader.f90:(.text+0x6aad): undefined reference to `_gfortran_internal_pack'
/usr/bin/ld: reader.f90:(.text+0x6ace): undefined reference to `__h5global_MOD_h5t_native_integer'
/usr/bin/ld: reader.f90:(.text+0x6ae1): undefined reference to `__h5_gen_MOD_h5dread_ikind_4_rank_2'
/usr/bin/ld: ./h5fortran/build//libh5fortran.a(reader.f90.o): in function `__h5fortran_MOD_hdf_read_1d':
reader.f90:(.text+0x6d65): undefined reference to `__h5global_MOD_h5s_all_f'
/usr/bin/ld: reader.f90:(.text+0x6e3d): undefined reference to `_gfortran_shape_4'
/usr/bin/ld: reader.f90:(.text+0x71ab): undefined reference to `__h5d_MOD_h5dopen_f'
/usr/bin/ld: reader.f90:(.text+0x7224): undefined reference to `_gfortran_error_stop_string'
/usr/bin/ld: reader.f90:(.text+0x7453): undefined reference to `_gfortran_internal_pack'
/usr/bin/ld: reader.f90:(.text+0x7474): undefined reference to `__h5global_MOD_h5t_native_double'
/usr/bin/ld: reader.f90:(.text+0x7487): undefined reference to `__h5_gen_MOD_h5dread_rkind_8_rank_1'
/usr/bin/ld: reader.f90:(.text+0x74a2): undefined reference to `_gfortran_internal_unpack'
/usr/bin/ld: reader.f90:(.text+0x7541): undefined reference to `_gfortran_internal_pack'
/usr/bin/ld: reader.f90:(.text+0x7565): undefined reference to `__h5global_MOD_h5t_native_real'
/usr/bin/ld: reader.f90:(.text+0x7575): undefined reference to `__h5_gen_MOD_h5dread_rkind_4_rank_1'
/usr/bin/ld: reader.f90:(.text+0x7601): undefined reference to `_gfortran_internal_pack'
/usr/bin/ld: reader.f90:(.text+0x7622): undefined reference to `__h5global_MOD_h5t_native_integer'
/usr/bin/ld: reader.f90:(.text+0x7635): undefined reference to `__h5_gen_MOD_h5dread_ikind_4_rank_1'
/usr/bin/ld: ./h5fortran/build//libh5fortran.a(reader.f90.o): in function `__h5fortran_MOD_hdf_read_scalar':
reader.f90:(.text+0x7720): undefined reference to `__h5d_MOD_h5dopen_f'
/usr/bin/ld: reader.f90:(.text+0x77c8): undefined reference to `_gfortran_st_write'
/usr/bin/ld: reader.f90:(.text+0x7808): undefined reference to `_gfortran_concat_string'
/usr/bin/ld: reader.f90:(.text+0x785a): undefined reference to `_gfortran_concat_string'
/usr/bin/ld: reader.f90:(.text+0x78c3): undefined reference to `_gfortran_concat_string'
/usr/bin/ld: reader.f90:(.text+0x78f2): undefined reference to `_gfortran_transfer_character_write'
/usr/bin/ld: reader.f90:(.text+0x7909): undefined reference to `_gfortran_st_write_done'
/usr/bin/ld: reader.f90:(.text+0x794c): undefined reference to `_gfortran_error_stop_string'
/usr/bin/ld: reader.f90:(.text+0x796a): undefined reference to `__h5global_MOD_h5t_native_double'
/usr/bin/ld: reader.f90:(.text+0x797d): undefined reference to `__h5_gen_MOD_h5dread_rkind_8_rank_0'
/usr/bin/ld: reader.f90:(.text+0x79e0): undefined reference to `__h5global_MOD_h5t_native_real'
/usr/bin/ld: reader.f90:(.text+0x79fd): undefined reference to `__h5_gen_MOD_h5dread_rkind_4_rank_0'
/usr/bin/ld: reader.f90:(.text+0x7a74): undefined reference to `__h5lt_const_MOD_h5ltread_dataset_string_f'
/usr/bin/ld: reader.f90:(.text+0x7ad2): undefined reference to `__h5global_MOD_h5t_native_integer'
/usr/bin/ld: reader.f90:(.text+0x7ae5): undefined reference to `__h5_gen_MOD_h5dread_ikind_4_rank_0'
/usr/bin/ld: reader.f90:(.text+0x7b21): undefined reference to `_gfortran_error_stop_string'
/usr/bin/ld: ./h5fortran/build//libh5fortran.a(write.f90.o): in function `__h5fortran_MOD_hdf_close_group':
write.f90:(.text+0x29): undefined reference to `__h5g_MOD_h5gclose_f'
/usr/bin/ld: write.f90:(.text+0x96): undefined reference to `_gfortran_error_stop_string'
/usr/bin/ld: write.f90:(.text+0xa9): undefined reference to `_gfortran_error_stop_string'
/usr/bin/ld: ./h5fortran/build//libh5fortran.a(write.f90.o): in function `__h5fortran_MOD_hdf_open_group':
write.f90:(.text+0xed): undefined reference to `__h5g_MOD_h5gopen_f'
/usr/bin/ld: write.f90:(.text+0x173): undefined reference to `_gfortran_error_stop_string'
/usr/bin/ld: write.f90:(.text+0x186): undefined reference to `_gfortran_error_stop_string'
/usr/bin/ld: ./h5fortran/build//libh5fortran.a(write.f90.o): in function `__h5fortran.write_MOD_guess_chunk_size':
write.f90:(.text+0x60b): undefined reference to `_gfortran_error_stop_string'
/usr/bin/ld: ./h5fortran/build//libh5fortran.a(write.f90.o): in function `__h5fortran.write_MOD_hdf_set_deflate':
write.f90:(.text+0xa01): undefined reference to `__h5global_MOD_h5p_dataset_create_f'
/usr/bin/ld: write.f90:(.text+0xa06): undefined reference to `__h5p_MOD_h5pcreate_f'
/usr/bin/ld: write.f90:(.text+0xa49): undefined reference to `__h5p_MOD_h5pset_chunk_f'
/usr/bin/ld: write.f90:(.text+0xa73): undefined reference to `__h5p_MOD_h5pset_shuffle_f'
/usr/bin/ld: write.f90:(.text+0xa9d): undefined reference to `__h5p_MOD_h5pset_fletcher32_f'
/usr/bin/ld: write.f90:(.text+0xace): undefined reference to `__h5p_MOD_h5pset_deflate_f'
/usr/bin/ld: write.f90:(.text+0xb2f): undefined reference to `_gfortran_st_write'
/usr/bin/ld: write.f90:(.text+0xb43): undefined reference to `_gfortran_transfer_character_write'
/usr/bin/ld: write.f90:(.text+0xb4b): undefined reference to `_gfortran_st_write_done'
/usr/bin/ld: write.f90:(.text+0xbb7): undefined reference to `_gfortran_st_write'
/usr/bin/ld: write.f90:(.text+0xbcb): undefined reference to `_gfortran_transfer_character_write'
/usr/bin/ld: write.f90:(.text+0xc44): undefined reference to `_gfortran_transfer_array_write'
/usr/bin/ld: write.f90:(.text+0xc58): undefined reference to `_gfortran_transfer_character_write'
/usr/bin/ld: write.f90:(.text+0xcc0): undefined reference to `_gfortran_transfer_array_write'
/usr/bin/ld: write.f90:(.text+0xcc8): undefined reference to `_gfortran_st_write_done'
/usr/bin/ld: write.f90:(.text+0xe17): undefined reference to `_gfortran_st_write'
/usr/bin/ld: write.f90:(.text+0xe2b): undefined reference to `_gfortran_transfer_character_write'
/usr/bin/ld: write.f90:(.text+0xe95): undefined reference to `_gfortran_transfer_array_write'
/usr/bin/ld: write.f90:(.text+0xe9d): undefined reference to `_gfortran_st_write_done'
/usr/bin/ld: write.f90:(.text+0xf42): undefined reference to `_gfortran_error_stop_string'
/usr/bin/ld: write.f90:(.text+0xf55): undefined reference to `_gfortran_error_stop_string'
/usr/bin/ld: ./h5fortran/build//libh5fortran.a(write.f90.o): in function `__h5fortran.write_MOD_hdf_setup_write':
write.f90:(.text+0x1049): undefined reference to `__h5lt_const_MOD_h5ltpath_valid_f'
/usr/bin/ld: write.f90:(.text+0x1290): undefined reference to `_gfortran_internal_pack'
/usr/bin/ld: write.f90:(.text+0x12ad): undefined reference to `__h5s_MOD_h5screate_simple_f'
/usr/bin/ld: write.f90:(.text+0x1317): undefined reference to `__h5d_MOD_h5dcreate_f'
/usr/bin/ld: write.f90:(.text+0x1342): undefined reference to `__h5p_MOD_h5pclose_f'
/usr/bin/ld: write.f90:(.text+0x1440): undefined reference to `__h5d_MOD_h5dopen_f'
/usr/bin/ld: write.f90:(.text+0x14a2): undefined reference to `__h5global_MOD_h5s_scalar_f'
/usr/bin/ld: write.f90:(.text+0x14a7): undefined reference to `__h5s_MOD_h5screate_f'
/usr/bin/ld: write.f90:(.text+0x14ce): undefined reference to `__h5d_MOD_h5dcreate_f'
/usr/bin/ld: write.f90:(.text+0x151a): undefined reference to `_gfortran_st_write'
/usr/bin/ld: write.f90:(.text+0x1558): undefined reference to `_gfortran_concat_string'
/usr/bin/ld: write.f90:(.text+0x1574): undefined reference to `_gfortran_transfer_character_write'
/usr/bin/ld: write.f90:(.text+0x158b): undefined reference to `_gfortran_st_write_done'
/usr/bin/ld: write.f90:(.text+0x15ad): undefined reference to `_gfortran_error_stop_string'
/usr/bin/ld: ./h5fortran/build//libh5fortran.a(writer.f90.o): in function `__h5fortran_MOD_hdf_write_7d':
writer.f90:(.text+0x33e): undefined reference to `_gfortran_shape_4'
/usr/bin/ld: writer.f90:(.text+0x776): undefined reference to `__h5global_MOD_h5t_native_real'
/usr/bin/ld: writer.f90:(.text+0x7b7): undefined reference to `_gfortran_internal_pack'
/usr/bin/ld: writer.f90:(.text+0x7ce): undefined reference to `__h5global_MOD_h5t_native_real'
/usr/bin/ld: writer.f90:(.text+0x7d9): undefined reference to `__h5_gen_MOD_h5dwrite_rkind_4_rank_7'
/usr/bin/ld: writer.f90:(.text+0xb13): undefined reference to `__h5global_MOD_h5t_native_double'
/usr/bin/ld: writer.f90:(.text+0xb54): undefined reference to `_gfortran_internal_pack'
/usr/bin/ld: writer.f90:(.text+0xb6b): undefined reference to `__h5global_MOD_h5t_native_double'
/usr/bin/ld: writer.f90:(.text+0xb76): undefined reference to `__h5_gen_MOD_h5dwrite_rkind_8_rank_7'
/usr/bin/ld: writer.f90:(.text+0xbd9): undefined reference to `_gfortran_error_stop_string'
/usr/bin/ld: writer.f90:(.text+0xeee): undefined reference to `__h5global_MOD_h5t_native_integer'
/usr/bin/ld: writer.f90:(.text+0xf37): undefined reference to `_gfortran_internal_pack'
/usr/bin/ld: writer.f90:(.text+0xf4e): undefined reference to `__h5global_MOD_h5t_native_integer'
/usr/bin/ld: writer.f90:(.text+0xf59): undefined reference to `__h5_gen_MOD_h5dwrite_ikind_4_rank_7'
/usr/bin/ld: ./h5fortran/build//libh5fortran.a(writer.f90.o): in function `__h5fortran_MOD_hdf_write_6d':
writer.f90:(.text+0x11e3): undefined reference to `_gfortran_shape_4'
/usr/bin/ld: writer.f90:(.text+0x15cb): undefined reference to `__h5global_MOD_h5t_native_real'
/usr/bin/ld: writer.f90:(.text+0x1606): undefined reference to `_gfortran_internal_pack'
/usr/bin/ld: writer.f90:(.text+0x161d): undefined reference to `__h5global_MOD_h5t_native_real'
/usr/bin/ld: writer.f90:(.text+0x1628): undefined reference to `__h5_gen_MOD_h5dwrite_rkind_4_rank_6'
/usr/bin/ld: writer.f90:(.text+0x191d): undefined reference to `__h5global_MOD_h5t_native_double'
/usr/bin/ld: writer.f90:(.text+0x195b): undefined reference to `_gfortran_internal_pack'
/usr/bin/ld: writer.f90:(.text+0x1972): undefined reference to `__h5global_MOD_h5t_native_double'
/usr/bin/ld: writer.f90:(.text+0x197d): undefined reference to `__h5_gen_MOD_h5dwrite_rkind_8_rank_6'
/usr/bin/ld: writer.f90:(.text+0x19e1): undefined reference to `_gfortran_error_stop_string'
/usr/bin/ld: writer.f90:(.text+0x1cb3): undefined reference to `__h5global_MOD_h5t_native_integer'
/usr/bin/ld: writer.f90:(.text+0x1cf9): undefined reference to `_gfortran_internal_pack'
/usr/bin/ld: writer.f90:(.text+0x1d10): undefined reference to `__h5global_MOD_h5t_native_integer'
/usr/bin/ld: writer.f90:(.text+0x1d1b): undefined reference to `__h5_gen_MOD_h5dwrite_ikind_4_rank_6'
/usr/bin/ld: ./h5fortran/build//libh5fortran.a(writer.f90.o): in function `__h5fortran_MOD_hdf_write_5d':
writer.f90:(.text+0x1f66): undefined reference to `_gfortran_shape_4'
/usr/bin/ld: writer.f90:(.text+0x22fa): undefined reference to `__h5global_MOD_h5t_native_real'
/usr/bin/ld: writer.f90:(.text+0x2334): undefined reference to `_gfortran_internal_pack'
/usr/bin/ld: writer.f90:(.text+0x234b): undefined reference to `__h5global_MOD_h5t_native_real'
/usr/bin/ld: writer.f90:(.text+0x2356): undefined reference to `__h5_gen_MOD_h5dwrite_rkind_4_rank_5'
/usr/bin/ld: writer.f90:(.text+0x2624): undefined reference to `__h5global_MOD_h5t_native_double'
/usr/bin/ld: writer.f90:(.text+0x265a): undefined reference to `_gfortran_internal_pack'
/usr/bin/ld: writer.f90:(.text+0x2671): undefined reference to `__h5global_MOD_h5t_native_double'
/usr/bin/ld: writer.f90:(.text+0x267c): undefined reference to `__h5_gen_MOD_h5dwrite_rkind_8_rank_5'
/usr/bin/ld: writer.f90:(.text+0x26d9): undefined reference to `_gfortran_error_stop_string'
/usr/bin/ld: writer.f90:(.text+0x2987): undefined reference to `__h5global_MOD_h5t_native_integer'
/usr/bin/ld: writer.f90:(.text+0x29c2): undefined reference to `_gfortran_internal_pack'
/usr/bin/ld: writer.f90:(.text+0x29d9): undefined reference to `__h5global_MOD_h5t_native_integer'
/usr/bin/ld: writer.f90:(.text+0x29e4): undefined reference to `__h5_gen_MOD_h5dwrite_ikind_4_rank_5'
/usr/bin/ld: ./h5fortran/build//libh5fortran.a(writer.f90.o): in function `__h5fortran_MOD_hdf_write_4d':
writer.f90:(.text+0x2bf3): undefined reference to `_gfortran_shape_4'
/usr/bin/ld: writer.f90:(.text+0x2ea1): undefined reference to `__h5global_MOD_h5t_native_real'
/usr/bin/ld: writer.f90:(.text+0x2eda): undefined reference to `_gfortran_internal_pack'
/usr/bin/ld: writer.f90:(.text+0x2eee): undefined reference to `__h5global_MOD_h5t_native_real'
/usr/bin/ld: writer.f90:(.text+0x2efe): undefined reference to `__h5_gen_MOD_h5dwrite_rkind_4_rank_4'
/usr/bin/ld: writer.f90:(.text+0x30e5): undefined reference to `__h5global_MOD_h5t_native_double'
/usr/bin/ld: writer.f90:(.text+0x3122): undefined reference to `_gfortran_internal_pack'
/usr/bin/ld: writer.f90:(.text+0x3136): undefined reference to `__h5global_MOD_h5t_native_double'
/usr/bin/ld: writer.f90:(.text+0x3146): undefined reference to `__h5_gen_MOD_h5dwrite_rkind_8_rank_4'
/usr/bin/ld: writer.f90:(.text+0x31ad): undefined reference to `_gfortran_error_stop_string'
/usr/bin/ld: writer.f90:(.text+0x3384): undefined reference to `__h5global_MOD_h5t_native_integer'
/usr/bin/ld: writer.f90:(.text+0x33b9): undefined reference to `_gfortran_internal_pack'
/usr/bin/ld: writer.f90:(.text+0x33cd): undefined reference to `__h5global_MOD_h5t_native_integer'
/usr/bin/ld: writer.f90:(.text+0x33dd): undefined reference to `__h5_gen_MOD_h5dwrite_ikind_4_rank_4'
/usr/bin/ld: ./h5fortran/build//libh5fortran.a(writer.f90.o): in function `__h5fortran_MOD_hdf_write_3d':
writer.f90:(.text+0x35b1): undefined reference to `_gfortran_shape_4'
/usr/bin/ld: writer.f90:(.text+0x382e): undefined reference to `__h5global_MOD_h5t_native_real'
/usr/bin/ld: writer.f90:(.text+0x3865): undefined reference to `_gfortran_internal_pack'
/usr/bin/ld: writer.f90:(.text+0x3879): undefined reference to `__h5global_MOD_h5t_native_real'
/usr/bin/ld: writer.f90:(.text+0x3889): undefined reference to `__h5_gen_MOD_h5dwrite_rkind_4_rank_3'
/usr/bin/ld: writer.f90:(.text+0x3a4a): undefined reference to `__h5global_MOD_h5t_native_double'
/usr/bin/ld: writer.f90:(.text+0x3a85): undefined reference to `_gfortran_internal_pack'
/usr/bin/ld: writer.f90:(.text+0x3a99): undefined reference to `__h5global_MOD_h5t_native_double'
/usr/bin/ld: writer.f90:(.text+0x3aa9): undefined reference to `__h5_gen_MOD_h5dwrite_rkind_8_rank_3'
/usr/bin/ld: writer.f90:(.text+0x3b0d): undefined reference to `_gfortran_error_stop_string'
/usr/bin/ld: writer.f90:(.text+0x3cb9): undefined reference to `__h5global_MOD_h5t_native_integer'
/usr/bin/ld: writer.f90:(.text+0x3cef): undefined reference to `_gfortran_internal_pack'
/usr/bin/ld: writer.f90:(.text+0x3d03): undefined reference to `__h5global_MOD_h5t_native_integer'
/usr/bin/ld: writer.f90:(.text+0x3d13): undefined reference to `__h5_gen_MOD_h5dwrite_ikind_4_rank_3'
/usr/bin/ld: ./h5fortran/build//libh5fortran.a(writer.f90.o): in function `__h5fortran_MOD_hdf_write_2d':
writer.f90:(.text+0x3ebb): undefined reference to `_gfortran_shape_4'
/usr/bin/ld: writer.f90:(.text+0x4105): undefined reference to `__h5global_MOD_h5t_native_real'
/usr/bin/ld: writer.f90:(.text+0x413e): undefined reference to `_gfortran_internal_pack'
/usr/bin/ld: writer.f90:(.text+0x4152): undefined reference to `__h5global_MOD_h5t_native_real'
/usr/bin/ld: writer.f90:(.text+0x4162): undefined reference to `__h5_gen_MOD_h5dwrite_rkind_4_rank_2'
/usr/bin/ld: writer.f90:(.text+0x42fe): undefined reference to `__h5global_MOD_h5t_native_double'
/usr/bin/ld: writer.f90:(.text+0x4334): undefined reference to `_gfortran_internal_pack'
/usr/bin/ld: writer.f90:(.text+0x4348): undefined reference to `__h5global_MOD_h5t_native_double'
/usr/bin/ld: writer.f90:(.text+0x4358): undefined reference to `__h5_gen_MOD_h5dwrite_rkind_8_rank_2'
/usr/bin/ld: writer.f90:(.text+0x43bd): undefined reference to `_gfortran_error_stop_string'
/usr/bin/ld: writer.f90:(.text+0x4543): undefined reference to `__h5global_MOD_h5t_native_integer'
/usr/bin/ld: writer.f90:(.text+0x4576): undefined reference to `_gfortran_internal_pack'
/usr/bin/ld: writer.f90:(.text+0x458a): undefined reference to `__h5global_MOD_h5t_native_integer'
/usr/bin/ld: writer.f90:(.text+0x459a): undefined reference to `__h5_gen_MOD_h5dwrite_ikind_4_rank_2'
/usr/bin/ld: ./h5fortran/build//libh5fortran.a(writer.f90.o): in function `__h5fortran_MOD_hdf_write_1d':
writer.f90:(.text+0x46fd): undefined reference to `_gfortran_shape_4'
/usr/bin/ld: writer.f90:(.text+0x4919): undefined reference to `__h5global_MOD_h5t_native_real'
/usr/bin/ld: writer.f90:(.text+0x496d): undefined reference to `_gfortran_internal_pack'
/usr/bin/ld: writer.f90:(.text+0x4981): undefined reference to `__h5global_MOD_h5t_native_real'
/usr/bin/ld: writer.f90:(.text+0x499b): undefined reference to `__h5_gen_MOD_h5dwrite_rkind_4_rank_1'
/usr/bin/ld: writer.f90:(.text+0x4b19): undefined reference to `__h5global_MOD_h5t_native_double'
/usr/bin/ld: writer.f90:(.text+0x4b68): undefined reference to `_gfortran_internal_pack'
/usr/bin/ld: writer.f90:(.text+0x4b7c): undefined reference to `__h5global_MOD_h5t_native_double'
/usr/bin/ld: writer.f90:(.text+0x4b96): undefined reference to `__h5_gen_MOD_h5dwrite_rkind_8_rank_1'
/usr/bin/ld: writer.f90:(.text+0x4c12): undefined reference to `_gfortran_error_stop_string'
/usr/bin/ld: writer.f90:(.text+0x4d6a): undefined reference to `__h5global_MOD_h5t_native_integer'
/usr/bin/ld: writer.f90:(.text+0x4dbb): undefined reference to `_gfortran_internal_pack'
/usr/bin/ld: writer.f90:(.text+0x4dcf): undefined reference to `__h5global_MOD_h5t_native_integer'
/usr/bin/ld: writer.f90:(.text+0x4de9): undefined reference to `__h5_gen_MOD_h5dwrite_ikind_4_rank_1'
/usr/bin/ld: ./h5fortran/build//libh5fortran.a(writer.f90.o): in function `__h5fortran_MOD_hdf_write_scalar':
writer.f90:(.text+0x4f49): undefined reference to `_gfortran_error_stop_string'
/usr/bin/ld: writer.f90:(.text+0x4f6f): undefined reference to `__h5lt_const_MOD_h5ltmake_dataset_string_f'
/usr/bin/ld: writer.f90:(.text+0x4fdb): undefined reference to `__h5global_MOD_h5t_native_integer'
/usr/bin/ld: writer.f90:(.text+0x5070): undefined reference to `__h5global_MOD_h5t_native_double'
/usr/bin/ld: writer.f90:(.text+0x50c7): undefined reference to `__h5global_MOD_h5t_native_double'
/usr/bin/ld: writer.f90:(.text+0x50d1): undefined reference to `__h5_gen_MOD_h5dwrite_rkind_8_rank_0'
/usr/bin/ld: writer.f90:(.text+0x5130): undefined reference to `__h5global_MOD_h5t_native_real'
/usr/bin/ld: writer.f90:(.text+0x5189): undefined reference to `__h5global_MOD_h5t_native_real'
/usr/bin/ld: writer.f90:(.text+0x5193): undefined reference to `__h5_gen_MOD_h5dwrite_rkind_4_rank_0'
/usr/bin/ld: writer.f90:(.text+0x51cd): undefined reference to `__h5global_MOD_h5t_native_integer'
/usr/bin/ld: writer.f90:(.text+0x51d7): undefined reference to `__h5_gen_MOD_h5dwrite_ikind_4_rank_0'
/usr/bin/ld: writer.f90:(.text+0x51f4): undefined reference to `_gfortran_os_error'
/usr/bin/ld: writer.f90:(.text+0x5207): undefined reference to `_gfortran_error_stop_string'
/usr/bin/ld: ./h5fortran/build//libh5fortran.a(attributes.f90.o): in function `__h5fortran.attributes_MOD_attr_shape_check':
attributes.f90:(.text+0x9d): undefined reference to `__h5lt_const_MOD_h5ltget_attribute_ndims_f'
/usr/bin/ld: attributes.f90:(.text+0xdf): undefined reference to `_gfortran_concat_string'
/usr/bin/ld: attributes.f90:(.text+0x117): undefined reference to `_gfortran_concat_string'
/usr/bin/ld: attributes.f90:(.text+0x163): undefined reference to `_gfortran_concat_string'
/usr/bin/ld: attributes.f90:(.text+0x20c): undefined reference to `_gfortran_st_write'
/usr/bin/ld: attributes.f90:(.text+0x234): undefined reference to `_gfortran_concat_string'
/usr/bin/ld: attributes.f90:(.text+0x270): undefined reference to `_gfortran_concat_string'
/usr/bin/ld: attributes.f90:(.text+0x2b5): undefined reference to `_gfortran_concat_string'
/usr/bin/ld: attributes.f90:(.text+0x2f3): undefined reference to `_gfortran_concat_string'
/usr/bin/ld: attributes.f90:(.text+0x309): undefined reference to `_gfortran_transfer_character_write'
/usr/bin/ld: attributes.f90:(.text+0x323): undefined reference to `_gfortran_transfer_integer_write'
/usr/bin/ld: attributes.f90:(.text+0x337): undefined reference to `_gfortran_transfer_character_write'
/usr/bin/ld: attributes.f90:(.text+0x33f): undefined reference to `_gfortran_st_write_done'
/usr/bin/ld: attributes.f90:(.text+0x398): undefined reference to `_gfortran_st_write'
/usr/bin/ld: attributes.f90:(.text+0x3d5): undefined reference to `_gfortran_concat_string'
/usr/bin/ld: attributes.f90:(.text+0x40e): undefined reference to `_gfortran_concat_string'
/usr/bin/ld: attributes.f90:(.text+0x450): undefined reference to `_gfortran_concat_string'
/usr/bin/ld: attributes.f90:(.text+0x491): undefined reference to `_gfortran_concat_string'
/usr/bin/ld: attributes.f90:(.text+0x4d6): undefined reference to `_gfortran_concat_string'
/usr/bin/ld: attributes.f90:(.text+0x4f0): undefined reference to `_gfortran_transfer_character_write'
/usr/bin/ld: attributes.f90:(.text+0x500): undefined reference to `_gfortran_st_write_done'
/usr/bin/ld: attributes.f90:(.text+0x54b): undefined reference to `__h5lt_const_MOD_h5ltget_attribute_info_f'
/usr/bin/ld: attributes.f90:(.text+0x591): undefined reference to `_gfortran_concat_string'
/usr/bin/ld: attributes.f90:(.text+0x5bf): undefined reference to `_gfortran_concat_string'
/usr/bin/ld: attributes.f90:(.text+0x60e): undefined reference to `_gfortran_concat_string'
/usr/bin/ld: attributes.f90:(.text+0x68d): undefined reference to `_gfortran_st_write'
/usr/bin/ld: attributes.f90:(.text+0x6c1): undefined reference to `_gfortran_concat_string'
/usr/bin/ld: attributes.f90:(.text+0x6fc): undefined reference to `_gfortran_concat_string'
/usr/bin/ld: attributes.f90:(.text+0x743): undefined reference to `_gfortran_concat_string'
/usr/bin/ld: attributes.f90:(.text+0x77e): undefined reference to `_gfortran_concat_string'
/usr/bin/ld: attributes.f90:(.text+0x794): undefined reference to `_gfortran_transfer_character_write'
/usr/bin/ld: attributes.f90:(.text+0x80f): undefined reference to `_gfortran_transfer_array_write'
/usr/bin/ld: attributes.f90:(.text+0x823): undefined reference to `_gfortran_transfer_character_write'
/usr/bin/ld: attributes.f90:(.text+0x835): undefined reference to `_gfortran_transfer_integer_write'
/usr/bin/ld: attributes.f90:(.text+0x83d): undefined reference to `_gfortran_st_write_done'
/usr/bin/ld: attributes.f90:(.text+0x860): undefined reference to `_gfortran_error_stop_string'
/usr/bin/ld: ./h5fortran/build//libh5fortran.a(attributes.f90.o): in function `__h5fortran_MOD_writeattr_num':
attributes.f90:(.text+0x971): undefined reference to `_gfortran_error_stop_string'
/usr/bin/ld: attributes.f90:(.text+0x9cf): undefined reference to `_gfortran_internal_pack'
/usr/bin/ld: attributes.f90:(.text+0x9f6): undefined reference to `__h5lt_const_MOD_h5ltset_attribute_float_f'
/usr/bin/ld: attributes.f90:(.text+0xa87): undefined reference to `_gfortran_internal_pack'
/usr/bin/ld: attributes.f90:(.text+0xaae): undefined reference to `__h5lt_const_MOD_h5ltset_attribute_double_f'
/usr/bin/ld: attributes.f90:(.text+0xb21): undefined reference to `_gfortran_internal_pack'
/usr/bin/ld: attributes.f90:(.text+0xb48): undefined reference to `__h5lt_const_MOD_h5ltset_attribute_int_f'
/usr/bin/ld: attributes.f90:(.text+0xb69): undefined reference to `_gfortran_internal_unpack'
/usr/bin/ld: attributes.f90:(.text+0xb85): undefined reference to `_gfortran_error_stop_string'
/usr/bin/ld: ./h5fortran/build//libh5fortran.a(attributes.f90.o): in function `__h5fortran_MOD_writeattr_char':
attributes.f90:(.text+0xbc4): undefined reference to `__h5lt_const_MOD_h5ltset_attribute_string_f'
/usr/bin/ld: attributes.f90:(.text+0xc21): undefined reference to `_gfortran_error_stop_string'
/usr/bin/ld: attributes.f90:(.text+0xc34): undefined reference to `_gfortran_error_stop_string'
/usr/bin/ld: ./h5fortran/build//libh5fortran.a(attributes.f90.o): in function `__h5fortran_MOD_readattr_num':
attributes.f90:(.text+0xe85): undefined reference to `_gfortran_error_stop_string'
/usr/bin/ld: attributes.f90:(.text+0xef8): undefined reference to `_gfortran_internal_pack'
/usr/bin/ld: attributes.f90:(.text+0xf24): undefined reference to `__h5lt_const_MOD_h5ltget_attribute_float_f'
/usr/bin/ld: attributes.f90:(.text+0xf43): undefined reference to `_gfortran_internal_unpack'
/usr/bin/ld: attributes.f90:(.text+0xfbe): undefined reference to `_gfortran_internal_pack'
/usr/bin/ld: attributes.f90:(.text+0xfea): undefined reference to `__h5lt_const_MOD_h5ltget_attribute_double_f'
/usr/bin/ld: attributes.f90:(.text+0x106e): undefined reference to `_gfortran_internal_pack'
/usr/bin/ld: attributes.f90:(.text+0x109a): undefined reference to `__h5lt_const_MOD_h5ltget_attribute_int_f'
/usr/bin/ld: attributes.f90:(.text+0x10bf): undefined reference to `_gfortran_error_stop_string'
/usr/bin/ld: ./h5fortran/build//libh5fortran.a(attributes.f90.o): in function `__h5fortran_MOD_readattr_char':
attributes.f90:(.text+0x1137): undefined reference to `__h5lt_const_MOD_h5ltget_attribute_string_f'
/usr/bin/ld: attributes.f90:(.text+0x11f1): undefined reference to `_gfortran_error_stop_string'
/usr/bin/ld: attributes.f90:(.text+0x1204): undefined reference to `_gfortran_error_stop_string'
/usr/bin/ld: ./h5fortran/build//libh5fortran.a(string_utils.f90.o): in function `__string_utils_MOD_truncate_string_null':
string_utils.f90:(.text+0x35): undefined reference to `_gfortran_string_index'
/usr/bin/ld: string_utils.f90:(.text+0x4e): undefined reference to `_gfortran_string_trim'
/usr/bin/ld: string_utils.f90:(.text+0x87): undefined reference to `_gfortran_string_len_trim'
/usr/bin/ld: ./h5fortran/build//libh5fortran.a(string_utils.f90.o): in function `__string_utils_MOD_strip_trailing_null':
string_utils.f90:(.text+0x134): undefined reference to `_gfortran_string_len_trim'
/usr/bin/ld: string_utils.f90:(.text+0x163): undefined reference to `_gfortran_string_trim'
/usr/bin/ld: ./h5fortran/build//libh5fortran.a(string_utils.f90.o): in function `__string_utils_MOD_tolower':
string_utils.f90:(.text+0x27c): undefined reference to `_gfortran_string_index'
/usr/bin/ld: ./h5fortran/build//libh5fortran.a(pathlib.f90.o): in function `__pathlib_MOD_unlink':
pathlib.f90:(.text+0x6f): undefined reference to `_gfortran_st_open'
/usr/bin/ld: pathlib.f90:(.text+0xb6): undefined reference to `_gfortran_st_close'
/usr/bin/ld: pathlib.f90:(.text+0xeb): undefined reference to `_gfortran_st_inquire'
/usr/bin/ld: ./h5fortran/build//libh5fortran.a(pathlib.f90.o): in function `__pathlib_MOD_get_tempdir':
pathlib.f90:(.text+0x172): undefined reference to `_gfortran_get_environment_variable_i4'
/usr/bin/ld: pathlib.f90:(.text+0x193): undefined reference to `_gfortran_string_len_trim'
/usr/bin/ld: pathlib.f90:(.text+0x1fd): undefined reference to `_gfortran_get_environment_variable_i4'
/usr/bin/ld: pathlib.f90:(.text+0x240): undefined reference to `_gfortran_get_environment_variable_i4'
collect2: error: ld returned 1 exit status

What I'm doing wrong?

nyckmaia commented 4 years ago

UPDATE 1

I copied the same Fortran and C++ source-code and tried compiling the Fortran side using CMake.

cmake_minimum_required(VERSION 3.14)
project(h5fortranExample LANGUAGES Fortran)
enable_testing()

# --- h5fortran template
include(FetchContent)

FetchContent_Declare(h5fortran_proj
  GIT_REPOSITORY https://github.com/geospace-code/h5fortran.git
  GIT_TAG v2.11.1
)

FetchContent_MakeAvailable(h5fortran_proj)

add_library(example2 STATIC example2.f90)
target_link_libraries(example2 h5fortran::h5fortran)

The output is: libexample2.a

So, my compilation line is now:

g++ app2.o -o app2 -L . -L ./h5fortran/build/ -lh5fortran -lexample2 -lgfortran

But I still got a error message:


/usr/bin/ld: ./libexample2.a(example2.f90.o): in function `xxx':
example2.f90:(.text+0xc4): undefined reference to `__h5fortran_MOD___vtab_h5fortran_Hdf5_file'
/usr/bin/ld: example2.f90:(.text+0x10a): undefined reference to `__h5fortran_MOD_hdf_initialize'
/usr/bin/ld: example2.f90:(.text+0x115): undefined reference to `__h5fortran_MOD___vtab_h5fortran_Hdf5_file'
/usr/bin/ld: example2.f90:(.text+0x128): undefined reference to `__h5fortran_MOD___vtab_INTEGER_4_'
/usr/bin/ld: example2.f90:(.text+0x16a): undefined reference to `__h5fortran_MOD_hdf_write_scalar'
/usr/bin/ld: example2.f90:(.text+0x171): undefined reference to `__h5fortran_MOD___vtab_h5fortran_Hdf5_file'
/usr/bin/ld: example2.f90:(.text+0x19c): undefined reference to `__h5fortran_MOD_hdf_finalize'
collect2: error: ld returned 1 exit status

Could you help me?

scivision commented 4 years ago

Please see "example3" under Examples/ It is a C calling Fortran example--the commands issued by CMake have considerably more parameters

scivision commented 4 years ago

Also example 4 is a C++ example to h5fortran

nyckmaia commented 4 years ago

Thank you @scivision ! Your CMake examples are great and I will use them!

Just to add a non-CMake way to do that, I get compilation working good using:

Compiling a Fortran library called: libf_test.a

gfortran -c -Wall -Wextra -I ../h5fortran/build/include/ -L ../h5fortran/build/ -I/usr/include/hdf5/serial -L/usr/lib/x86_64-linux-gnu/hdf5/serial f_test.f90 -o libf_test.a

Compiling a main C++ program called app2 and linking it with libf_test.a

g++ app2.o -o app2 -L/usr/lib/x86_64-linux-gnu/hdf5/serial -L ../h5fortran/build/ -L. -Wl,-Bstatic -lf_test -lh5fortran -lhdf5hl_fortran -lhdf5_hl -lhdf5_fortran -lhdf5 -lz -Wl,-Bdynamic -lgfortran -lsz -laec -lpthread -ldl

Here is the Fortran source-code:

module mod
    use h5fortran, only: hdf5_file

    contains
    subroutine xxx() bind(C, name = 'xxx')

        type(hdf5_file) :: h5f
        call h5f%initialize('test.h5', status='new',action='w')

            call h5f%write('/myScalar', 10)

            call h5f%finalize()

        end subroutine xxx
    end module mod

And here is the C++ source-code:

extern "C" {
    void xxx(void);
}

int main(void)
{
    xxx();

    return 0;
}

My system is: