HDF5 + nagfor problem
- Dominant language
- C
- Stars
- 988
- Forks
- 355
- Avg merge
- 4d 2h
- Merged PRs (30d)
- 12
Description
I continue to have trouble with HDF5 and nagfor.
I’ve compiled the hdf5-1.14.6 library on my MacBook Pro with M2 Max processor and macOS Sequoia 15.6.1 with the followinbg commands:
export FC=nagfor
export CC=clang
export CXX=clang++
cmake .. \
-G "Unix Makefiles" \
-DCMAKE_INSTALL_PREFIX=/usr/local/hdf5 \
-DCMAKE_BUILD_TYPE=Release \
-DCMAKE_Fortran_COMPILER=$FC \
-DCMAKE_C_COMPILER=$CC \
-DCMAKE_CXX_COMPILER=$CXX \
-DBUILD_SHARED_LIBS=OFF \
-DBUILD_STATIC_LIBS=ON \
-DHDF5_BUILD_FORTRAN=ON \
-DCMAKE_Fortran_FLAGS=-kind=byte
installed in /usr/local/hdf5. I have the following in my makefile:
FFLAGS = -I/usr/local/hdf5/include \
LIBS = -L/usr/local/hdf5/lib \
I have the following in Fortran module desc_mod:
USE hdf5
USE, INTRINSIC :: ISO_FORTRAN_ENV, ONLY: INT64
I have the following statements in subroutine desc-H5read
either
INTEGER(hid_t) :: file_id
or
INTEGER(int64) :: file_id
and
CALL h5fopen_f(TRIM(path),H5F_ACC_RDONLY_F,file_id,hdferr)
In either case, I get the following error message:
Undefined symbols for architecture arm64:
"_h5f_MP_h5fopen_f", referenced from:
_desc_mod_MP_desc_h5read in desc.o
"_h5global_MP_h5f_acc_rdonly_f", referenced from:
_desc_mod_MP_desc_h5read in desc.o
ld: symbol(s) not found for architecture arm64
clang: error: linker command failed with exit code 1 (use -v to see invocation)
make: *** [dcon3d] Error 1
Please advise.
Contributor guide
Assessment
This issue has not been assessed yet.