Error in WRFDA 4.6.1 compilation with RTTOV 12.1

irok

New member
I am facing the following error when compiling WRFDA 4.6.1 4DVAR with RTTOV12.1.
/usr/bin/ld: cannot find -lhdf5_hl_f90cstub: No such file or directory
/usr/bin/ld: cannot find -lhdf5_f90cstub: No such file or directory
executables other than da_wrfvar.exe are created. I have successfully installed RTTOV12.1 and passed all the tests. I have also successfully compiled 4dvar with out the RTTOV. i am attaching the log file for further reference.

Thank you.
 

Attachments

Hi! Did you get this resolved? I'm currently experiencing the same issue and I'm not sure where to start.
 
I encountered the following errors during compilation:
/usr/bin/ld: cannot find -lhdf5_hl_f90cstub
/usr/bin/ld: cannot find -lhdf5_f90cstub
/usr/bin/ld: cannot find -lhdf5_hl_cpp
collect2: error: ld returned 1 exit status
To resolve this issue, I created symbolic links for the missing HDF5 libraries:
cd $HDF5/lib
ln -s libhdf5hl_fortran.so libhdf5_hl_f90cstub.so
ln -s libhdf5hl_fortran.a libhdf5_hl_f90cstub.a
ln -s libhdf5_fortran.so libhdf5_f90cstub.so
ln -s libhdf5_fortran.a libhdf5_f90cstub.a
ln -s libhdf5hl_fortran.so libhdf5_hl_cpp.so
ln -s libhdf5hl_fortran.a libhdf5_hl_cpp.a
After applying these fixes, the compilation proceeded without further errors.

[lab35dongxh@mu01 WRFDA]$ ls -l var/build/*exe var/obsproc/src/obsproc.exe | wc -l
44
binggo!
 
I encountered the following errors during compilation:
/usr/bin/ld: cannot find -lhdf5_hl_f90cstub
/usr/bin/ld: cannot find -lhdf5_f90cstub
/usr/bin/ld: cannot find -lhdf5_hl_cpp
collect2: error: ld returned 1 exit status
To resolve this issue, I created symbolic links for the missing HDF5 libraries:
cd $HDF5/lib
ln -s libhdf5hl_fortran.so libhdf5_hl_f90cstub.so
ln -s libhdf5hl_fortran.a libhdf5_hl_f90cstub.a
ln -s libhdf5_fortran.so libhdf5_f90cstub.so
ln -s libhdf5_fortran.a libhdf5_f90cstub.a
ln -s libhdf5hl_fortran.so libhdf5_hl_cpp.so
ln -s libhdf5hl_fortran.a libhdf5_hl_cpp.a
After applying these fixes, the compilation proceeded without further errors.

[lab35dongxh@mu01 WRFDA]$ ls -l var/build/*exe var/obsproc/src/obsproc.exe | wc -l
44
binggo!
another way is to export the variable HDF5 and set it equal to the path of the grib2 files

Bash:
export HDF5=/path/to/library/files/grib2
 
I encountered the following errors during compilation:
/usr/bin/ld: cannot find -lhdf5_hl_f90cstub
/usr/bin/ld: cannot find -lhdf5_f90cstub
/usr/bin/ld: cannot find -lhdf5_hl_cpp
collect2: error: ld returned 1 exit status
To resolve this issue, I created symbolic links for the missing HDF5 libraries:
cd $HDF5/lib
ln -s libhdf5hl_fortran.so libhdf5_hl_f90cstub.so
ln -s libhdf5hl_fortran.a libhdf5_hl_f90cstub.a
ln -s libhdf5_fortran.so libhdf5_f90cstub.so
ln -s libhdf5_fortran.a libhdf5_f90cstub.a
ln -s libhdf5hl_fortran.so libhdf5_hl_cpp.so
ln -s libhdf5hl_fortran.a libhdf5_hl_cpp.a
After applying these fixes, the compilation proceeded without further errors.

[lab35dongxh@mu01 WRFDA]$ ls -l var/build/*exe var/obsproc/src/obsproc.exe | wc -l
44
binggo!
Sorry for the late reply.
I checked my HDF5 installation, there are no files with f90cstub. Is there a problem with my HDF5 installation? But the WRFDA compiles successfully without the RTTOV.
 
Sorry for the late reply.
I checked my HDF5 installation, there are no files with f90cstub. Is there a problem with my HDF5 installation? But the WRFDA compiles successfully without the RTTOV.
cd /your/path of libraries/hdf5/lib
sudo ln -s libhdf5hl_fortran.a libhdf5_hl_f90cstub.a
sudo ln -s libhdf5_fortran.a libhdf5_f90cstub.a
sudo ln -s libhdf5_hl.a libhdf5_hl_cpp.a

sudo ldconfig

this can solve and and you found 44 executable.
 
I encountered the same error compiling WRF4.7.1 DA 4DVAR with RTTOV 12 using intel hdf5 1.12.2.
I grep "cstub" and found this error may stems from rttov compiling in compile file line 354:

# line 354
setenv RTTOV_LIB "-L${hdf5path}/lib -lhdf5_hl_fortran -lhdf5_hl -lhdf5_fortran -lhdf5 -lhdf5_hl_f90cstub -lhdf5_f90cstub -lhdf5_hl_cpp -L${RTTOV}/lib -lrttov12_coef_io -lrttov12_emis_atlas -lrttov12_main -lrttov12_hdf

And just after deleting
-lhdf5_hl_f90cstub -lhdf5_f90cstub -lhdf5_hl_cpp
and recompiling, da_wrfvar.exe compiled successfully

I have not do further tests to verify whether wrfda works with this method yet.

This method may help when you using module system and do not have sudo permission to edit files in HPC systems
 
Back
Top