Scheduled Downtime
On Friday 21 April 2023 @ 5pm MT, this website will be down for maintenance and expected to return online the morning of 24 April 2023 at the latest

WRF compile problem: undefined reference to 'xxx'

bluebulu108

New member
Dear all,
I am doing WRF3.2 compiling.
I typed the following in the command line: ./configure, and I chose 11 (dmpar) INTEL (ifort with icc), it succeeded.
However, when I typed the following in the command line: ./compile em_real >&log.compile , I got the following errors (see in WRF-comile.txt):

make[1]: [em_real] Error 1 (ignored)
......


I installed hdf5-1.10.4, mpich-4.0.2, netcdf-3.6.3, ioapi-3.2, libpng-1.6.37 and zlib-1.2.11.

~/.bashrc
source /opt/intel/oneapi/setvars.sh intel64
export CC=icx
export CXX=icpx
export FC=ifort
export CFLAGS=-m64-diag-disable=10441
export F77=ifort
export FFLAGS=-m64
export DIR=/disk2/public/usr_local
export F90=ifort
export AR=xiar
export LD=xild

......


I would appreciate it if you would take the time out of your busy schedule to check out my posts and give suggestions.
Best regards,
Janice
 

Attachments

  • WRF-compile.txt
    61.9 KB · Views: 3
  • .bashrc.txt
    1.1 KB · Views: 1
  • configure.wrf.txt
    20.6 KB · Views: 1
Last edited:
Since the attached WRF-compile.txt file is not the full compile error/output, it's hard for me to say exactly what the initial issue is; however, I do see these listed:

Code:
wrf_io.f:(.text+0x17e0a): undefined reference to `nf_put_att_int_'
wrf_io.f:(.text+0x1805c): undefined reference to `nf_redef_'
wrf_io.f:(.text+0x184a9): undefined reference to `nf_put_att_int_'
wrf_io.f:(.text+0x1859b): undefined reference to `nf_enddef_'
wrf_io.f:(.text+0x189da): undefined reference to `nf_strerror_'
wrf_io.f:(.text+0x18c91): undefined reference to `nf_strerror_'

which typically indicate an issue with your NetCDF installation. You'll need to make sure you have NetCDF installed, and that you've declared the environment variable for NetCDF. This compile tutorial may be helpful to ensure you have everything set up correctly, and that your libraries are all compatible.

Another thing to note is that the WRFV3.2 code is VERY outdated (12.5 years old). It is no longer supported, and likely will not compile with newer versions of your compiler (e.g., ifort). Unfortunately you may still not be able to get it compiled.
 
I put the full compile error/output in the attachment. Would you give me any suggestion, please? It still failed to compile and generate the exe file.
the server is el7 x86.
the compiler is intel-11.1, gcc-v 4.4.7.
I successfully installed zlib, jasper, libpng, hdf5, mpich2-1.1.1p1, netcdf-3.6.3 and ioapi-3.2.
 

Attachments

  • compile.txt
    74 KB · Views: 1
Last edited:
Since the attached WRF-compile.txt file is not the full compile error/output, it's hard for me to say exactly what the initial issue is; however, I do see these listed:

Code:
wrf_io.f:(.text+0x17e0a): undefined reference to `nf_put_att_int_'
wrf_io.f:(.text+0x1805c): undefined reference to `nf_redef_'
wrf_io.f:(.text+0x184a9): undefined reference to `nf_put_att_int_'
wrf_io.f:(.text+0x1859b): undefined reference to `nf_enddef_'
wrf_io.f:(.text+0x189da): undefined reference to `nf_strerror_'
wrf_io.f:(.text+0x18c91): undefined reference to `nf_strerror_'

which typically indicate an issue with your NetCDF installation. You'll need to make sure you have NetCDF installed, and that you've declared the environment variable for NetCDF. This compile tutorial may be helpful to ensure you have everything set up correctly, and that your libraries are all compatible.

Another thing to note is that the WRFV3.2 code is VERY outdated (12.5 years old). It is no longer supported, and likely will not compile with newer versions of your compiler (e.g., ifort). Unfortunately you may still not be able to get it compiled.
I put the full compile error/output in the attachment. Would you give me any suggestion, please? It still failed to compile and generate the exe file.
the server is el7 x86.
the compiler is intel-11.1, gcc-v 4.4.7.
I successfully installed zlib, jasper, libpng, hdf5, mpich2-1.1.1p1, netcdf-3.6.3 and ioapi-3.2.
 

Attachments

  • compile.txt
    74 KB · Views: 4
Last edited:
Hi,
When looking for cases of WRF not compiling due to a jasper library, I came across this, which I believe is your post, and you mentioned you solved the issue. Is that correct? If so, can you let us know how you solved it? It could help future users with the same issue. Thanks!
 
Top