Undefined Reference to * when building icon

Hi all,

I got an error when I tried to build ICON. I think there is something wrong on my -lioapi, so I recompiled ioapi several times, but it still doesn’t work. Please, I need your help.

Makefile generated
ifort -qopenmp UTILIO_DEFN.o HGRD_DEFN.o IC_PARMS.o CGRID_SPCS.o VGRD_DEFN.o findex.o gc_spc_map.o get_envlist.o icon.o lat_lon.o lr_interp.o lst_spc_map.o ngc_spc_map.o opn_ic_file.o setup_logdev.o subhdomain.o prof_driver.o prof_icout.o prof_vinterp.o -L/home/dasol/CMAQ_v5.2.1/lib/x86_64/intel/ioapi/lib -L/home/dasol/Build_CMAQ/ioapi-3.1/Linux2_x86_64ifort -lioapi -L/home/dasol/CMAQ_v5.2.1/lib/x86_64/intel/netcdf/lib -L/home/dasol/Build_WRF/LIBRARIES/netcdf/lib -lnetcdf -lhdf5_hl -lhdf5 -lcurl -o ICON_v52_profile.exe
/home/dasol/CMAQ_v5.2.1/lib/x86_64/intel/ioapi/lib/libioapi.a(desc3.o): In function desc3_': desc3.F:(.text+0x2af): undefined reference to ncagtc_’
desc3.F:(.text+0x450): undefined reference to ncagt_' desc3.F:(.text+0x5d6): undefined reference to ncagt_’
desc3.F:(.text+0x75c): undefined reference to ncagt_' desc3.F:(.text+0x8e2): undefined reference to ncagt_’
desc3.F:(.text+0xa6c): undefined reference to ncagtc_' desc3.F:(.text+0xbfa): undefined reference to ncagtc_’
desc3.F:(.text+0xd88): undefined reference to ncagtc_' desc3.F:(.text+0xf6a): undefined reference to ncagtc_’
desc3.F:(.text+0x1288): undefined reference to ncagt_' desc3.F:(.text+0x1476): undefined reference to ncanam_’
desc3.F:(.text+0x1684): undefined reference to ncagt_' /home/dasol/CMAQ_v5.2.1/lib/x86_64/intel/ioapi/lib/libioapi.a(init3.o): In function init3_‘:
init3.F:(.text+0x86): undefined reference to ncpopt_' init3.F:(.text+0x99): undefined reference to nf_inq_libvers_’
/home/dasol/CMAQ_v5.2.1/lib/x86_64/intel/ioapi/lib/libioapi.a(open3.o): In function open3_': open3.F:(.text+0x785): undefined reference to ncclos_’
open3.F:(.text+0x7a4): undefined reference to ncclos_' /home/dasol/CMAQ_v5.2.1/lib/x86_64/intel/ioapi/lib/libioapi.a(opnfil3.o): In function opnfil3_‘:
opnfil3.F:(.text+0x105): undefined reference to nf_open_' opnfil3.F:(.text+0x142): undefined reference to ncagt_’
opnfil3.F:(.text+0x173): undefined reference to ncagt_' opnfil3.F:(.text+0x1c9): undefined reference to ncagt_’
opnfil3.F:(.text+0x1fa): undefined reference to ncagt_' opnfil3.F:(.text+0x22b): undefined reference to ncagt_’
/home/dasol/CMAQ_v5.2.1/lib/x86_64/intel/ioapi/lib/libioapi.a(opnfil3.o):opnfil3.F:(.text+0x25c): more undefined references to ncagt_' follow /home/dasol/CMAQ_v5.2.1/lib/x86_64/intel/ioapi/lib/libioapi.a(opnfil3.o): In function opnfil3_‘:
opnfil3.F:(.text+0x5b4): undefined reference to ncagtc_' opnfil3.F:(.text+0x5db): undefined reference to ncvid_’
opnfil3.F:(.text+0x605): undefined reference to ncdid_' opnfil3.F:(.text+0x63a): undefined reference to ncdinq_’
opnfil3.F:(.text+0x794): undefined reference to ncvid_' opnfil3.F:(.text+0x7e9): undefined reference to ncagtc_’
opnfil3.F:(.text+0x872): undefined reference to ncvid_' opnfil3.F:(.text+0x8d2): undefined reference to ncvinq_’
opnfil3.F:(.text+0x908): undefined reference to ncagtc_' opnfil3.F:(.text+0x971): undefined reference to ncsnc_’
opnfil3.F:(.text+0x998): undefined reference to ncclos_' opnfil3.F:(.text+0x9fa): undefined reference to ncvid_’
opnfil3.F:(.text+0xa24): undefined reference to ncvid_' opnfil3.F:(.text+0xa4e): undefined reference to ncvid_’
opnfil3.F:(.text+0xa78): undefined reference to ncvid_' opnfil3.F:(.text+0xa9e): undefined reference to ncvid_’
/home/dasol/CMAQ_v5.2.1/lib/x86_64/intel/ioapi/lib/libioapi.a(opnfil3.o):opnfil3.F:(.text+0xbf2): more undefined references to ncvid_' follow /home/dasol/CMAQ_v5.2.1/lib/x86_64/intel/ioapi/lib/libioapi.a(opnfil3.o): In function opnfil3_‘:
opnfil3.F:(.text+0x18a4): undefined reference to ncredf_' opnfil3.F:(.text+0x18ef): undefined reference to ncaptc_’
opnfil3.F:(.text+0x1941): undefined reference to ncaptc_' opnfil3.F:(.text+0x195a): undefined reference to ncendf_’
/home/dasol/CMAQ_v5.2.1/lib/x86_64/intel/ioapi/lib/libioapi.a(opnlog3.o): In function opnlog3_': opnlog3.F:(.text+0xab): undefined reference to ncagtc_’
/home/dasol/CMAQ_v5.2.1/lib/x86_64/intel/ioapi/lib/libioapi.a(shut3.o): In function shut3_': shut3.F:(.text+0xd7): undefined reference to ncclos_’
/home/dasol/CMAQ_v5.2.1/lib/x86_64/intel/ioapi/lib/libioapi.a(wrprofil.o): In function wrprofil_': wrprofil.F:(.text+0x8c): undefined reference to ncvpt1_’
wrprofil.F:(.text+0x1e4): undefined reference to ncvpt_' wrprofil.F:(.text+0x32c): undefined reference to ncvpt_’
wrprofil.F:(.text+0x475): undefined reference to ncvpt_' wrprofil.F:(.text+0x5b4): undefined reference to ncvpt_’
wrprofil.F:(.text+0x6f6): undefined reference to ncvpt_' /home/dasol/CMAQ_v5.2.1/lib/x86_64/intel/ioapi/lib/libioapi.a(wrvars.o):wrvars.F:(.text+0x9f): more undefined references to ncvpt_’ follow
/home/dasol/CMAQ_v5.2.1/lib/x86_64/intel/ioapi/lib/libioapi.a(chkfil3.o): In function chkfil3_': chkfil3.f:(.text+0x19f7): undefined reference to ncagt_’
chkfil3.f:(.text+0x1b7f): undefined reference to ncagt_' chkfil3.f:(.text+0x1d4f): undefined reference to ncagt_’
/home/dasol/CMAQ_v5.2.1/lib/x86_64/intel/ioapi/lib/libioapi.a(ckfile3.o): In function ckfile3_': ckfile3.f:(.text+0x8c5): undefined reference to ncagt_’
ckfile3.f:(.text+0xa51): undefined reference to ncagt_' /home/dasol/CMAQ_v5.2.1/lib/x86_64/intel/ioapi/lib/libioapi.a(close3.o): In function close3_‘:
close3.f:(.text+0xce): undefined reference to ncclos_' /home/dasol/CMAQ_v5.2.1/lib/x86_64/intel/ioapi/lib/libioapi.a(opnlist3.o): In function opnlist3_’:
opnlist3.f:(.text+0x76d): undefined reference to ncclos_' /home/dasol/CMAQ_v5.2.1/lib/x86_64/intel/ioapi/lib/libioapi.a(syncfid.o): In function syncfid_‘:
syncfid.f:(.text+0x5c): undefined reference to nf_sync_' syncfid.f:(.text+0x230): undefined reference to nf_sync_’
syncfid.f:(.text+0x277): undefined reference to nf_sync_' syncfid.f:(.text+0x2f6): undefined reference to nf_sync_’
/home/dasol/CMAQ_v5.2.1/lib/x86_64/intel/ioapi/lib/libioapi.a(wrdict3.o): In function wrdict3_': wrdict3.f:(.text+0xe9): undefined reference to ncvgtc_’
wrdict3.f:(.text+0x2fa): undefined reference to ncvptc_' wrdict3.f:(.text+0x4b0): undefined reference to ncvpt1_’
wrdict3.f:(.text+0x645): undefined reference to ncvpt1_' wrdict3.f:(.text+0x7d5): undefined reference to ncvpt1_’
wrdict3.f:(.text+0x96a): undefined reference to ncvpt1_' wrdict3.f:(.text+0xaff): undefined reference to ncvpt1_’
/home/dasol/CMAQ_v5.2.1/lib/x86_64/intel/ioapi/lib/libioapi.a(wrdict3.o):wrdict3.f:(.text+0xc94): more undefined references to ncvpt1_' follow /home/dasol/CMAQ_v5.2.1/lib/x86_64/intel/ioapi/lib/libioapi.a(wrdict3.o): In function wrdict3_‘:
wrdict3.f:(.text+0x130c): undefined reference to ncvpt_' wrdict3.f:(.text+0x14be): undefined reference to ncvpt1_’
wrdict3.f:(.text+0x1653): undefined reference to ncvpt1_' wrdict3.f:(.text+0x17e8): undefined reference to ncvpt1_’
wrdict3.f:(.text+0x197d): undefined reference to ncvpt1_' wrdict3.f:(.text+0x1b12): undefined reference to ncvpt1_’
/home/dasol/CMAQ_v5.2.1/lib/x86_64/intel/ioapi/lib/libioapi.a(wrdict3.o):wrdict3.f:(.text+0x1ca7): more undefined references to ncvpt1_' follow /home/dasol/CMAQ_v5.2.1/lib/x86_64/intel/ioapi/lib/libioapi.a(wrdict3.o): In function wrdict3_‘:
wrdict3.f:(.text+0x2324): undefined reference to ncvptc_' wrdict3.f:(.text+0x24f1): undefined reference to ncvptc_’
wrdict3.f:(.text+0x26c9): undefined reference to ncvptc_' wrdict3.f:(.text+0x28a1): undefined reference to ncvptc_’
wrdict3.f:(.text+0x2a7d): undefined reference to ncvptc_' wrdict3.f:(.text+0x2c3a): undefined reference to ncvpt_’
wrdict3.f:(.text+0x2dda): undefined reference to ncvpt1_' /home/dasol/CMAQ_v5.2.1/lib/x86_64/intel/ioapi/lib/libioapi.a(wriddata.o): In function wriddata_‘:
wriddata.f:(.text+0x90): undefined reference to ncvpt1_' wriddata.f:(.text+0x20f): undefined reference to ncvpt_’
/home/dasol/CMAQ_v5.2.1/lib/x86_64/intel/ioapi/lib/libioapi.a(wrsmatrx.o): In function wrsmatrx_': wrsmatrx.f:(.text+0xaf): undefined reference to ncvpt_’
wrsmatrx.f:(.text+0x204): undefined reference to ncvpt_' /home/dasol/CMAQ_v5.2.1/lib/x86_64/intel/ioapi/lib/libioapi.a(wrtflag.o): In function wrtflag_‘:
wrtflag.f:(.text+0xc0): undefined reference to ncvpt_' /home/dasol/CMAQ_v5.2.1/lib/x86_64/intel/ioapi/lib/libioapi.a(crtfil3.o): In function crtfil3_’:
crtfil3.F:(.text+0xb9): undefined reference to nf_create_' crtfil3.F:(.text+0x125): undefined reference to ncaptc_’
crtfil3.F:(.text+0x173): undefined reference to ncaptc_' crtfil3.F:(.text+0x1ba): undefined reference to ncapt_’
crtfil3.F:(.text+0x1f2): undefined reference to ncapt_' crtfil3.F:(.text+0x22a): undefined reference to ncapt_’
crtfil3.F:(.text+0x262): undefined reference to ncapt_' crtfil3.F:(.text+0x29a): undefined reference to ncapt_’
/home/dasol/CMAQ_v5.2.1/lib/x86_64/intel/ioapi/lib/libioapi.a(crtfil3.o):crtfil3.F:(.text+0x319): more undefined references to ncapt_' follow /home/dasol/CMAQ_v5.2.1/lib/x86_64/intel/ioapi/lib/libioapi.a(crtfil3.o): In function crtfil3_‘:
crtfil3.F:(.text+0x93e): undefined reference to ncaptc_' crtfil3.F:(.text+0x990): undefined reference to ncaptc_’
crtfil3.F:(.text+0x9ee): undefined reference to ncaptc_' crtfil3.F:(.text+0xa3c): undefined reference to ncaptc_’
crtfil3.F:(.text+0xa8a): undefined reference to ncaptc_' crtfil3.F:(.text+0xadd): undefined reference to ncddef_’
crtfil3.F:(.text+0xb07): undefined reference to ncddef_' crtfil3.F:(.text+0xb35): undefined reference to ncddef_’
crtfil3.F:(.text+0xb7a): undefined reference to ncddef_' crtfil3.F:(.text+0xc15): undefined reference to ncvdef_’
crtfil3.F:(.text+0xc76): undefined reference to ncaptc_' crtfil3.F:(.text+0xce5): undefined reference to ncaptc_’
crtfil3.F:(.text+0xd36): undefined reference to ncaptc_' crtfil3.F:(.text+0xd94): undefined reference to ncddef_’
crtfil3.F:(.text+0xdc6): undefined reference to ncddef_' crtfil3.F:(.text+0xe3a): undefined reference to ncddef_’
crtfil3.F:(.text+0xe6c): undefined reference to ncddef_' crtfil3.F:(.text+0xed7): undefined reference to ncddef_’
/home/dasol/CMAQ_v5.2.1/lib/x86_64/intel/ioapi/lib/libioapi.a(crtfil3.o):crtfil3.F:(.text+0xf09): more undefined references to ncddef_' follow /home/dasol/CMAQ_v5.2.1/lib/x86_64/intel/ioapi/lib/libioapi.a(crtfil3.o): In function crtfil3_‘:
crtfil3.F:(.text+0xf5d): undefined reference to ncvdef_' crtfil3.F:(.text+0xfb7): undefined reference to ncvdef_’
crtfil3.F:(.text+0x1009): undefined reference to ncddef_' crtfil3.F:(.text+0x1037): undefined reference to ncddef_’
crtfil3.F:(.text+0x107a): undefined reference to ncvdef_' crtfil3.F:(.text+0x10ce): undefined reference to ncvdef_’
crtfil3.F:(.text+0x1114): undefined reference to ncvdef_' crtfil3.F:(.text+0x115a): undefined reference to ncvdef_’
crtfil3.F:(.text+0x11a0): undefined reference to ncvdef_' /home/dasol/CMAQ_v5.2.1/lib/x86_64/intel/ioapi/lib/libioapi.a(crtfil3.o):crtfil3.F:(.text+0x11e6): more undefined references to ncvdef_’ follow
/home/dasol/CMAQ_v5.2.1/lib/x86_64/intel/ioapi/lib/libioapi.a(crtfil3.o): In function crtfil3_': crtfil3.F:(.text+0x1332): undefined reference to ncddef_’
crtfil3.F:(.text+0x1360): undefined reference to ncddef_' crtfil3.F:(.text+0x13a3): undefined reference to ncvdef_’
crtfil3.F:(.text+0x13f7): undefined reference to ncvdef_' crtfil3.F:(.text+0x143d): undefined reference to ncvdef_’
crtfil3.F:(.text+0x1483): undefined reference to ncvdef_' crtfil3.F:(.text+0x14c9): undefined reference to ncvdef_’
/home/dasol/CMAQ_v5.2.1/lib/x86_64/intel/ioapi/lib/libioapi.a(crtfil3.o):crtfil3.F:(.text+0x150f): more undefined references to ncvdef_' follow /home/dasol/CMAQ_v5.2.1/lib/x86_64/intel/ioapi/lib/libioapi.a(crtfil3.o): In function crtfil3_‘:
crtfil3.F:(.text+0x158e): undefined reference to ncddef_' crtfil3.F:(.text+0x15d1): undefined reference to ncvdef_’
crtfil3.F:(.text+0x1625): undefined reference to ncvdef_' crtfil3.F:(.text+0x16d9): undefined reference to ncddef_’
crtfil3.F:(.text+0x173f): undefined reference to ncddef_' crtfil3.F:(.text+0x1771): undefined reference to ncddef_’
crtfil3.F:(.text+0x17cc): undefined reference to ncddef_' crtfil3.F:(.text+0x1912): undefined reference to ncabor_’
crtfil3.F:(.text+0x1935): undefined reference to ncddef_' crtfil3.F:(.text+0x1963): undefined reference to ncddef_’
crtfil3.F:(.text+0x1991): undefined reference to ncddef_' crtfil3.F:(.text+0x19e9): undefined reference to ncvdef_’
crtfil3.F:(.text+0x1a55): undefined reference to ncvdef_' crtfil3.F:(.text+0x1a9b): undefined reference to ncvdef_’
crtfil3.F:(.text+0x1ae1): undefined reference to ncvdef_' crtfil3.F:(.text+0x1b27): undefined reference to ncvdef_’
/home/dasol/CMAQ_v5.2.1/lib/x86_64/intel/ioapi/lib/libioapi.a(crtfil3.o):crtfil3.F:(.text+0x1c5c): more undefined references to ncvdef_' follow /home/dasol/CMAQ_v5.2.1/lib/x86_64/intel/ioapi/lib/libioapi.a(crtfil3.o): In function crtfil3_‘:
crtfil3.F:(.text+0x1cc7): undefined reference to ncaptc_' crtfil3.F:(.text+0x1d1c): undefined reference to ncaptc_’
crtfil3.F:(.text+0x1d71): undefined reference to ncaptc_' crtfil3.F:(.text+0x1e69): undefined reference to ncapt_’
crtfil3.F:(.text+0x1ed8): undefined reference to ncapt_' crtfil3.F:(.text+0x1f5f): undefined reference to ncendf_’
crtfil3.F:(.text+0x2647): undefined reference to ncsnc_' crtfil3.F:(.text+0x2772): undefined reference to ncvpt_’
crtfil3.F:(.text+0x2b54): undefined reference to ncabor_' crtfil3.F:(.text+0x2d99): undefined reference to ncabor_’
crtfil3.F:(.text+0x38c5): undefined reference to ncclos_' /home/dasol/CMAQ_v5.2.1/lib/x86_64/intel/ioapi/lib/libioapi.a(m3abort.o): In function m3abort_‘:
m3abort.F:(.text+0x151): undefined reference to nf_strerror_' /home/dasol/CMAQ_v5.2.1/lib/x86_64/intel/ioapi/lib/libioapi.a(rdvars.o): In function rdvars_’:
rdvars.F:(.text+0x97): undefined reference to ncvgt_' rdvars.F:(.text+0x2d0): undefined reference to ncvgt_’
/home/dasol/CMAQ_v5.2.1/lib/x86_64/intel/ioapi/lib/libioapi.a(wrgrnest.o): In function wrgrnest_': wrgrnest.F:(.text+0x8c): undefined reference to ncvpt1_’
wrgrnest.F:(.text+0x1e4): undefined reference to ncvpt_' wrgrnest.F:(.text+0x32c): undefined reference to ncvpt_’
wrgrnest.F:(.text+0x475): undefined reference to ncvpt_' wrgrnest.F:(.text+0x5b4): undefined reference to ncvpt_’
wrgrnest.F:(.text+0x6f6): undefined reference to ncvpt_' /home/dasol/CMAQ_v5.2.1/lib/x86_64/intel/ioapi/lib/libioapi.a(wrgrnest.o):wrgrnest.F:(.text+0x839): more undefined references to ncvpt_’ follow
/home/dasol/CMAQ_v5.2.1/lib/x86_64/intel/ioapi/lib/libioapi.a(crdict3.o): In function crdict3_': crdict3.f:(.text+0x41): undefined reference to ncddef_’
crdict3.f:(.text+0x175): undefined reference to ncabor_' crdict3.f:(.text+0x19c): undefined reference to ncddef_’
crdict3.f:(.text+0x2d0): undefined reference to ncabor_' crdict3.f:(.text+0x2f7): undefined reference to ncddef_’
crdict3.f:(.text+0x42b): undefined reference to ncabor_' crdict3.f:(.text+0x452): undefined reference to ncddef_’
crdict3.f:(.text+0x585): undefined reference to ncabor_' crdict3.f:(.text+0x5ac): undefined reference to ncddef_’
crdict3.f:(.text+0x6e3): undefined reference to ncabor_' crdict3.f:(.text+0x70a): undefined reference to ncddef_’
crdict3.f:(.text+0x841): undefined reference to ncabor_' crdict3.f:(.text+0x87e): undefined reference to ncvdef_’
crdict3.f:(.text+0x9bb): undefined reference to ncabor_' crdict3.f:(.text+0xa11): undefined reference to ncaptc_’
crdict3.f:(.text+0xb46): undefined reference to ncabor_' crdict3.f:(.text+0xb94): undefined reference to ncaptc_’
crdict3.f:(.text+0xcc9): undefined reference to ncabor_' crdict3.f:(.text+0x2770): undefined reference to ncapt_’
crdict3.f:(.text+0x28a5): undefined reference to ncabor_' crdict3.f:(.text+0x2911): undefined reference to ncaptc_’
crdict3.f:(.text+0x2a46): undefined reference to ncabor_' crdict3.f:(.text+0x2a86): undefined reference to ncvdef_’
crdict3.f:(.text+0x2b0f): undefined reference to ncvdef_' crdict3.f:(.text+0x2ba0): undefined reference to ncvdef_’
crdict3.f:(.text+0x2c1f): undefined reference to ncvdef_' crdict3.f:(.text+0x2c9f): undefined reference to ncvdef_’
crdict3.f:(.text+0x2de2): undefined reference to ncabor_' crdict3.f:(.text+0x2e4a): undefined reference to ncvdef_’
crdict3.f:(.text+0x2fe6): undefined reference to ncabor_' crdict3.f:(.text+0x303d): undefined reference to ncvdef_’
crdict3.f:(.text+0x31d2): undefined reference to ncabor_' crdict3.f:(.text+0x321e): undefined reference to ncvdef_’
crdict3.f:(.text+0x33b3): undefined reference to ncabor_' crdict3.f:(.text+0x3412): undefined reference to ncvdef_’
crdict3.f:(.text+0x35a7): undefined reference to ncabor_' crdict3.f:(.text+0x35fb): undefined reference to ncvdef_’
crdict3.f:(.text+0x3790): undefined reference to ncabor_' crdict3.f:(.text+0x380d): undefined reference to ncaptc_’
crdict3.f:(.text+0x3862): undefined reference to ncaptc_' crdict3.f:(.text+0x3899): undefined reference to ncendf_’
crdict3.f:(.text+0x39c8): undefined reference to ncabor_' crdict3.f:(.text+0x3b8d): undefined reference to ncabor_’
crdict3.f:(.text+0x3d34): undefined reference to ncabor_' crdict3.f:(.text+0x3eb9): undefined reference to ncabor_’
crdict3.f:(.text+0x403e): undefined reference to ncabor_' /home/dasol/CMAQ_v5.2.1/lib/x86_64/intel/ioapi/lib/libioapi.a(crdict3.o):crdict3.f:(.text+0x41c6): more undefined references to ncabor_’ follow
make: *** [ICON_v52_profile.exe] Error 1
ERROR while running make command

else
endif
mv Makefile Makefile.intel
mv: ‘Makefile’ and ‘Makefile.intel’ are the same file
ln -s Makefile.intel Makefile
ln: failed to create symbolic link ‘Makefile’: File exists
if ( 1 != 0 ) then
echo *** failure in /home/dasol/CMAQ_v5.2.1/UTIL/bldmake/bldmake_intel.exe -serial -verbose ***
*** failure in /home/dasol/CMAQ_v5.2.1/UTIL/bldmake/bldmake_intel.exe -serial -verbose ***
exit 1

Which I/O API version? Which netCDF version? (You need I/O API 3.2 for netCDF4). See https://www.cmascenter.org/ioapi/documentation/all_versions/html/AVAIL.html#ncf4:

Evidently, starting with netCDF-Fortran 4.4.2, UCAR in their wisdom decided to silently eliminate the CALL NC*() Fortran interfaces in terms of which the I/O API was originally implemented. [If you can find any documentation indicating this intent on the web, I would enjoy seeing it; I can’t find it.]

I/O API Version 3.2 was tediously re-coded to replace all 943 of these calls by the newer IERR=NF_*() Fortran interfaces that are still supported. Prior editions of the I/O API will have link errors with netCDF-Fortran 4.4.2 or later, because routines such as NCCLOS() are no longer in that library.

Thank you for your help.
I was using netcdf-4.1.3 and ioapi-3.1.
As you said, I installed ioapi-3.2 and recompiled bldit_icon.csh, but similar error detected.
Please, I need your help.

Makefile generated
mpiifort -qopenmp UTILIO_DEFN.o HGRD_DEFN.o IC_PARMS.o CGRID_SPCS.o VGRD_DEFN.o findex.o gc_spc_map.o get_envlist.o icon.o lat_lon.o lr_interp.o lst_spc_map.o ngc_spc_map.o opn_ic_file.o setup_logdev.o subhdomain.o prof_driver.o prof_icout.o prof_vinterp.o -L/home/dasol/CMAQ_v5.2.1/lib/x86_64/intel/ioapi/lib -lioapi -L/home/dasol/Build_CMAQ/ioapi-3.2/Linux2_x86_64ifort -L/home/dasol/CMAQ_v5.2.1/lib/x86_64/intel/netcdf/lib -lnetcdf -L/home/dasol/Build_WRF/LIBRARIES/netcdf/lib -lcurl -o ICON_v52_profile.exe
/home/dasol/CMAQ_v5.2.1/lib/x86_64/intel/ioapi/lib/libioapi.a(desc3.o): In function desc3_': desc3.F90:(.text+0x2fb): undefined reference to nf_get_att_text_’
desc3.F90:(.text+0x479): undefined reference to nf_get_att_int_' desc3.F90:(.text+0x5cf): undefined reference to nf_get_att_int_’
desc3.F90:(.text+0x725): undefined reference to nf_get_att_int_' desc3.F90:(.text+0x87b): undefined reference to nf_get_att_int_’
desc3.F90:(.text+0x9d7): undefined reference to nf_get_att_text_' desc3.F90:(.text+0xb2d): undefined reference to nf_get_att_text_’
desc3.F90:(.text+0xc83): undefined reference to nf_get_att_text_' desc3.F90:(.text+0xe68): undefined reference to nf_get_att_text_’
desc3.F90:(.text+0x1198): undefined reference to nf_inq_varnatts_' desc3.F90:(.text+0x13c9): undefined reference to nf_inq_attname_’
desc3.F90:(.text+0x15de): undefined reference to nf_get_att_real_' /home/dasol/CMAQ_v5.2.1/lib/x86_64/intel/ioapi/lib/libioapi.a(init3.o): In function init3_‘:
init3.F90:(.text+0x8d): undefined reference to nf_inq_libvers_' /home/dasol/CMAQ_v5.2.1/lib/x86_64/intel/ioapi/lib/libioapi.a(open3.o): In function open3_’:
open3.F90:(.text+0xbfe): undefined reference to nf_close_' /home/dasol/CMAQ_v5.2.1/lib/x86_64/intel/ioapi/lib/libioapi.a(opnfil3.o): In function opnfil3_‘:
opnfil3.F90:(.text+0xfd): undefined reference to nf_open_' opnfil3.F90:(.text+0x136): undefined reference to nf_get_att_int_’
opnfil3.F90:(.text+0x164): undefined reference to nf_get_att_int_' opnfil3.F90:(.text+0x1b7): undefined reference to nf_get_att_int_’
opnfil3.F90:(.text+0x1e5): undefined reference to nf_get_att_int_' opnfil3.F90:(.text+0x213): undefined reference to nf_get_att_int_’
/home/dasol/CMAQ_v5.2.1/lib/x86_64/intel/ioapi/lib/libioapi.a(opnfil3.o):opnfil3.F90:(.text+0x241): more undefined references to nf_get_att_int_' follow /home/dasol/CMAQ_v5.2.1/lib/x86_64/intel/ioapi/lib/libioapi.a(opnfil3.o): In function opnfil3_‘:
opnfil3.F90:(.text+0x327): undefined reference to nf_get_att_double_' opnfil3.F90:(.text+0x355): undefined reference to nf_get_att_double_’
opnfil3.F90:(.text+0x383): undefined reference to nf_get_att_double_' opnfil3.F90:(.text+0x3b1): undefined reference to nf_get_att_double_’
opnfil3.F90:(.text+0x3df): undefined reference to nf_get_att_double_' /home/dasol/CMAQ_v5.2.1/lib/x86_64/intel/ioapi/lib/libioapi.a(opnfil3.o):opnfil3.F90:(.text+0x40d): more undefined references to nf_get_att_double_’ follow
/home/dasol/CMAQ_v5.2.1/lib/x86_64/intel/ioapi/lib/libioapi.a(opnfil3.o): In function opnfil3_': opnfil3.F90:(.text+0x4c5): undefined reference to nf_get_att_int_’
opnfil3.F90:(.text+0x4f3): undefined reference to nf_get_att_real_' opnfil3.F90:(.text+0x527): undefined reference to nf_get_att_real_’
opnfil3.F90:(.text+0x568): undefined reference to nf_get_att_text_' opnfil3.F90:(.text+0x590): undefined reference to nf_inq_varid_’
opnfil3.F90:(.text+0x5b4): undefined reference to nf_inq_dimid_' opnfil3.F90:(.text+0x5d6): undefined reference to nf_inq_dimlen_’
opnfil3.F90:(.text+0x735): undefined reference to nf_inq_varid_' opnfil3.F90:(.text+0x784): undefined reference to nf_get_att_text_’
opnfil3.F90:(.text+0x812): undefined reference to nf_inq_varid_' opnfil3.F90:(.text+0x850): undefined reference to nf_inq_var_’
opnfil3.F90:(.text+0x885): undefined reference to nf_get_att_text_' opnfil3.F90:(.text+0x8ea): undefined reference to nf_sync_’
opnfil3.F90:(.text+0x912): undefined reference to nf_close_' opnfil3.F90:(.text+0x969): undefined reference to nf_close_’
opnfil3.F90:(.text+0x9ef): undefined reference to nf_inq_varid_' opnfil3.F90:(.text+0xa17): undefined reference to nf_inq_varid_’
opnfil3.F90:(.text+0xa3f): undefined reference to nf_inq_varid_' opnfil3.F90:(.text+0xa67): undefined reference to nf_inq_varid_’
opnfil3.F90:(.text+0xa8b): undefined reference to nf_inq_varid_' /home/dasol/CMAQ_v5.2.1/lib/x86_64/intel/ioapi/lib/libioapi.a(opnfil3.o):opnfil3.F90:(.text+0xbdc): more undefined references to nf_inq_varid_’ follow
/home/dasol/CMAQ_v5.2.1/lib/x86_64/intel/ioapi/lib/libioapi.a(opnfil3.o): In function opnfil3_': opnfil3.F90:(.text+0x185d): undefined reference to nf_redef_’
opnfil3.F90:(.text+0x1893): undefined reference to nf_put_att_text_' opnfil3.F90:(.text+0x18d4): undefined reference to nf_put_att_text_’
opnfil3.F90:(.text+0x18ea): undefined reference to nf_enddef_' /home/dasol/CMAQ_v5.2.1/lib/x86_64/intel/ioapi/lib/libioapi.a(opnlog3.o): In function opnlog3_‘:
opnlog3.F90:(.text+0x112): undefined reference to nf_get_att_text_' /home/dasol/CMAQ_v5.2.1/lib/x86_64/intel/ioapi/lib/libioapi.a(shut3.o): In function shut3_’:
shut3.F90:(.text+0xda): undefined reference to nf_close_' /home/dasol/CMAQ_v5.2.1/lib/x86_64/intel/ioapi/lib/libioapi.a(syncfid.o): In function syncfid_‘:
syncfid.F90:(.text+0x6d): undefined reference to nf_sync_' /home/dasol/CMAQ_v5.2.1/lib/x86_64/intel/ioapi/lib/libioapi.a(wrgrnest.o): In function wrgrnest_’:
wrgrnest.F90:(.text+0x88): undefined reference to nf_put_var1_int_' wrgrnest.F90:(.text+0x1da): undefined reference to nf_put_vara_int_’
wrgrnest.F90:(.text+0x328): undefined reference to nf_put_vara_int_' wrgrnest.F90:(.text+0x46f): undefined reference to nf_put_vara_int_’
wrgrnest.F90:(.text+0x5ac): undefined reference to nf_put_vara_int_' wrgrnest.F90:(.text+0x6ec): undefined reference to nf_put_vara_double_’
wrgrnest.F90:(.text+0x82d): undefined reference to nf_put_vara_double_' wrgrnest.F90:(.text+0x96e): undefined reference to nf_put_vara_double_’
wrgrnest.F90:(.text+0xaaf): undefined reference to nf_put_vara_double_' /home/dasol/CMAQ_v5.2.1/lib/x86_64/intel/ioapi/lib/libioapi.a(wrprofil.o): In function wrprofil_‘:
wrprofil.F90:(.text+0x89): undefined reference to nf_put_var1_int_' wrprofil.F90:(.text+0x1d8): undefined reference to nf_put_vara_int_’
wrprofil.F90:(.text+0x327): undefined reference to nf_put_vara_int_' wrprofil.F90:(.text+0x477): undefined reference to nf_put_vara_double_’
wrprofil.F90:(.text+0x5bc): undefined reference to nf_put_vara_double_' wrprofil.F90:(.text+0x701): undefined reference to nf_put_vara_double_’
/home/dasol/CMAQ_v5.2.1/lib/x86_64/intel/ioapi/lib/libioapi.a(wrvars.o): In function wrvars_': wrvars.F90:(.text+0xc8): undefined reference to nf_put_vara_double_’
wrvars.F90:(.text+0xeb): undefined reference to nf_put_vara_int64_' wrvars.F90:(.text+0x111): undefined reference to nf_put_vara_real_’
wrvars.F90:(.text+0x185): undefined reference to nf_put_vara_int_' wrvars.F90:(.text+0x239): undefined reference to nf_put_vara_int_’
wrvars.F90:(.text+0x404): undefined reference to nf_put_vara_double_' wrvars.F90:(.text+0x432): undefined reference to nf_put_vara_int64_’
wrvars.F90:(.text+0x467): undefined reference to nf_put_vara_real_' /home/dasol/CMAQ_v5.2.1/lib/x86_64/intel/ioapi/lib/libioapi.a(m3abort.o): In function m3abort_‘:
m3abort.f90:(.text+0x158): undefined reference to nf_strerror_' m3abort.f90:(.text+0x199): undefined reference to nf_abort_’
m3abort.f90:(.text+0x1c2): undefined reference to nf_strerror_' /home/dasol/CMAQ_v5.2.1/lib/x86_64/intel/ioapi/lib/libioapi.a(opnlist3.o): In function opnlist3_‘:
opnlist3.f90:(.text+0x843): undefined reference to nf_close_' /home/dasol/CMAQ_v5.2.1/lib/x86_64/intel/ioapi/lib/libioapi.a(wrdict3.o): In function wrdict3_’:
wrdict3.f90:(.text+0xf0): undefined reference to nf_put_vara_text_' wrdict3.f90:(.text+0x343): undefined reference to nf_put_vara_text_’
wrdict3.f90:(.text+0x3a1): undefined reference to nf_put_vara_int_' wrdict3.f90:(.text+0x3cf): undefined reference to nf_put_vara_int_’
wrdict3.f90:(.text+0x400): undefined reference to nf_put_vara_int_' wrdict3.f90:(.text+0x42e): undefined reference to nf_put_vara_int_’
wrdict3.f90:(.text+0x45c): undefined reference to nf_put_vara_int_' /home/dasol/CMAQ_v5.2.1/lib/x86_64/intel/ioapi/lib/libioapi.a(wrdict3.o):wrdict3.f90:(.text+0x48d): more undefined references to nf_put_vara_int_’ follow
/home/dasol/CMAQ_v5.2.1/lib/x86_64/intel/ioapi/lib/libioapi.a(wrdict3.o): In function wrdict3_': wrdict3.f90:(.text+0x564): undefined reference to nf_put_vara_real_’
wrdict3.f90:(.text+0x5c2): undefined reference to nf_put_vara_double_' wrdict3.f90:(.text+0x5f0): undefined reference to nf_put_vara_double_’
wrdict3.f90:(.text+0x61e): undefined reference to nf_put_vara_double_' wrdict3.f90:(.text+0x64c): undefined reference to nf_put_vara_double_’
wrdict3.f90:(.text+0x67a): undefined reference to nf_put_vara_double_' /home/dasol/CMAQ_v5.2.1/lib/x86_64/intel/ioapi/lib/libioapi.a(wrdict3.o):wrdict3.f90:(.text+0x6a8): more undefined references to nf_put_vara_double_’ follow

/home/dasol/CMAQ_v5.2.1/lib/x86_64/intel/ioapi/lib/libioapi.a(rdatt3.o): In function rdatt3_': rdatt3.F90:(.text+0x7e6): undefined reference to nf_get_att_text_’
/home/dasol/CMAQ_v5.2.1/lib/x86_64/intel/ioapi/lib/libioapi.a(wratt3.o): In function wrattc_': wratt3.F90:(.text+0x3fb): undefined reference to nf_redef_’
wratt3.F90:(.text+0x5a4): undefined reference to nf_put_att_double_' wratt3.F90:(.text+0x5de): undefined reference to nf_put_att_real_’
wratt3.F90:(.text+0x615): undefined reference to nf_put_att_int_' wratt3.F90:(.text+0x650): undefined reference to nf_put_att_text_’
wratt3.F90:(.text+0x7b0): undefined reference to `nf_enddef_’
make: *** [ICON_v52_profile.exe] Error 1
ERROR while running make command

else
endif
mv Makefile Makefile.intel
mv: ‘Makefile’ and ‘Makefile.intel’ are the same file
ln -s Makefile.intel Makefile
ln: failed to create symbolic link ‘Makefile’: File exists
if ( 1 != 0 ) then
echo *** failure in /home/dasol/CMAQ_v5.2.1/UTIL/bldmake/bldmake_intel.exe -serial -verbose ***
*** failure in /home/dasol/CMAQ_v5.2.1/UTIL/bldmake/bldmake_intel.exe -serial -verbose ***
exit 1

Sorry, I didn’t read your attachment.

I should have changed some codes after upgrading version of ioapi.

I successfully compiled icon thanks to you.

I really appreciate your help.