NETCDF undefined reference

Hi,
I am trying to compile RIP4 for WRF. I have problems.
This maybe come from netcdf library.

I installed necdf4.1.1 using the below command.

#> CC=“pgcc”
#> CXX=“pgCC”
#> FC=“pgf90”
#> CFLAGS="-DpgiFortran -O2 -fPIC -tp nehalem-64"
#> FFLAGS="-DpgiFortran -O2 -fPIC -tp nehalem-64"
#> FCFLAGS="-DpgiFortran -O2 -fPIC -tp nehalem-64"
#> FCFLAGS_F90="-DpgiFortran -O2 -fPIC -tp nehalem-64"

#> ./configure --prefix=/opt/lib.pgi/NETCDF4 --enable-shared --enable-static --with-hdf5=/opt/lib.pgi/HDF5 --disable-dap --enable-netcdf-4 --enable-netcdf4

The install of NETCDF is no problem.

When I comile the RIP4, I get the error messages for undefined reference to nf_* like below…

Sincerely



 
**** Compiling rip ****
 
pgf90 -byteswapio  -o rip addorfill.o adjellip.o angle.o barb.o bes.o bogs.o brnshr.o bshear.o bvfricalc.o capecalc3d.o ceilingcalc.o colram.o 
colrln.o condheat.o contrive2.o cpchhl.o cpchll.o cpcolr.o cpmpxy.o createdtg.o cttcalc.o dbzcalc.o refmos2calc.o 
refmos3calc.o ddpcalc.o ddx.o ddy.o derivc.o drawcl.o driver.o egridfill.o eqthecalc.o extingcalc.o fields.o fillarray.o 
finterp.o finterp2d.o fregcalc.o frtitle.o fx.o fy.o getbasicvars.o getbasicvars_newdom.o getchar.o getconvals.o getdash.o 
getdims.o getheadinfo.o getheadinfo_newdom.o getinum.o getminfo.o getpt.o getrnum.o gettimes.o getvar.o getvarinfo.o 
hboxdraw.o hbulldraw.o hchadraw.o hcondraw.o hiresmap.o hlinedraw.o hmapdraw.o hodograph.o hsidsdraw.o
hstrdraw.o hticdraw.o htrajdraw.o hvecdraw.o igetcoind.o lennonblank.o liftparcel.o locinterp.o maptform.o maptick.o 
mconvert.o mktrjpts.o mlen.o monotonic.o netasc.o numeric.o omgcalc.o pfcalc.o pltitle.o prcver.o precprob.o premaptform.o 
profil.o profvelcalc.o pvocalc.o qgomg.o rdcolt.o readspec.o relhl.o rhucalc.o ricalc.o rip.o rotipslab.o rotpslab.o sateqthecalc.o 
saweli.o scondraw.o seaprs.o setripheader.o smooth.o smoothcp.o smoothcz.o smoothrain.o srflow.o srflow2.o sstats.o sticdraw.o 
sticdraw_polar.o svecdraw.o tdpcalc.o tfpcalc.o thecalc.o tonpsadiabat.o tserprep.o turb.o typhoon.o unblank.o vbardraw.o vc2dcalc.o 
vcondraw.o velbrb.o velvctmts.o vgp.o vinterp.o virtual.o virtualhyd.o viscalc.o vticdraw.o vtrajdraw.o vvecdraw.o vwinddraw.o wdircalc.o 
wetbulbcalc.o writefile.o wspcalc.o xmapcalc.o xtodot.o binio.o v5d.o 
-L/opt/lib.pgi/NETCDF4/lib -lnetcdf -I/opt/lib.pgi/NETCDF4/include  -L/usr/local/lib -lncarg -lcgm -lncarg_gks -lncarg_c -lX11 -lm 
-L/usr/X11R6/lib -lX11 -L/usr/local/pgi/linux86/lib -lpgftnrtl -lpgc -L/usr/lib/gcc/x86_64-redhat-linux/4.1.2 -lg2c -lgfortran
refmos2calc.o: In function `refmos2calc_':
/home/lim/local/RIP4/src/./refmos2calc.f:14: undefined reference to `nf_open_'
/home/lim/local/RIP4/src/./refmos2calc.f:14: undefined reference to `nf_inq_dimid_'
/home/lim/local/RIP4/src/./refmos2calc.f:14: undefined reference to `nf_inq_dimlen_'
/home/lim/local/RIP4/src/./refmos2calc.f:14: undefined reference to `nf_inq_dimid_'
/home/lim/local/RIP4/src/./refmos2calc.f:14: undefined reference to `nf_inq_dimlen_'
/home/lim/local/RIP4/src/./refmos2calc.f:21: undefined reference to `nf_get_att_real_'
/home/lim/local/RIP4/src/./refmos2calc.f:21: undefined reference to `nf_get_att_real_'
/home/lim/local/RIP4/src/./refmos2calc.f:21: undefined reference to `nf_get_att_real_'
/home/lim/local/RIP4/src/./refmos2calc.f:21: undefined reference to `nf_get_att_real_'
/home/lim/local/RIP4/src/./refmos2calc.f:21: undefined reference to `nf_inq_varid_'
/home/lim/local/RIP4/src/./refmos2calc.f:37: undefined reference to `nf_inq_varid_'
/home/lim/local/RIP4/src/./refmos2calc.f:39: undefined reference to `nf_get_var_int2_'
refmos3calc.o: In function `refmos3calc_':
/home/lim/local/RIP4/src/./refmos3calc.f:17: undefined reference to `nf_open_'
/home/lim/local/RIP4/src/./refmos3calc.f:17: undefined reference to `nf_inq_dimid_'
/home/lim/local/RIP4/src/./refmos3calc.f:17: undefined reference to `nf_inq_dimlen_'
/home/lim/local/RIP4/src/./refmos3calc.f:17: undefined reference to `nf_inq_dimid_'
/home/lim/local/RIP4/src/./refmos3calc.f:17: undefined reference to `nf_inq_dimlen_'
/home/lim/local/RIP4/src/./refmos3calc.f:17: undefined reference to `nf_inq_dimid_'
/home/lim/local/RIP4/src/./refmos3calc.f:17: undefined reference to `nf_inq_dimlen_'
/home/lim/local/RIP4/src/./refmos3calc.f:26: undefined reference to `nf_get_att_real_'
/home/lim/local/RIP4/src/./refmos3calc.f:26: undefined reference to `nf_get_att_real_'
/home/lim/local/RIP4/src/./refmos3calc.f:26: undefined reference to `nf_get_att_real_'
/home/lim/local/RIP4/src/./refmos3calc.f:26: undefined reference to `nf_get_att_real_'
/home/lim/local/RIP4/src/./refmos3calc.f:26: undefined reference to `nf_inq_varid_'
/home/lim/local/RIP4/src/./refmos3calc.f:26: undefined reference to `nf_get_var_int2_'
/home/lim/local/RIP4/src/./refmos3calc.f:26: undefined reference to `nf_open_'
/home/lim/local/RIP4/src/./refmos3calc.f:26: undefined reference to `nf_inq_varid_'
/home/lim/local/RIP4/src/./refmos3calc.f:26: undefined reference to `nf_get_var_int2_'
/home/lim/local/RIP4/src/./refmos3calc.f:81: undefined reference to `nf_inq_varid_'
/home/lim/local/RIP4/src/./refmos3calc.f:81: undefined reference to `nf_get_var_text_'
make: [rip] Error 2 (ignored)
pgf90 -byteswapio  -o ripdp_wrfarw  ripdp_wrfarw.f -L/opt/lib.pgi/NETCDF4/lib -lnetcdf  -I/opt/lib.pgi/NETCDF4/include  \
		premaptform.o maptform.o fillarray.o mconvert.o writefile_rdp.o \
		virtual.o xtodot.o 
ripdp_wrfarw.f:
ripdp_wrfarw.o: In function `ripdp_wrfarw':
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:103: undefined reference to `nf_open_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:103: undefined reference to `nf_get_att_text_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:146: undefined reference to `nf_inq_dimid_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:146: undefined reference to `nf_inq_dimlen_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:146: undefined reference to `nf_inq_dimid_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:146: undefined reference to `nf_inq_dimlen_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:146: undefined reference to `nf_inq_dimid_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:146: undefined reference to `nf_inq_dimid_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:162: undefined reference to `nf_inq_dimlen_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:168: undefined reference to `nf_get_att_text_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:178: undefined reference to `nf_get_att_text_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:194: undefined reference to `nf_close_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:210: undefined reference to `nf_open_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:210: undefined reference to `nf_inq_dimid_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:210: undefined reference to `nf_inq_dimlen_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:210: undefined reference to `nf_close_'
ripdp_wrfarw.o: In function `process_':
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:527: undefined reference to `nf_open_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:527: undefined reference to `nf_inq_dimid_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:527: undefined reference to `nf_inq_dimlen_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:527: undefined reference to `nf_inq_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:548: undefined reference to `nf_inq_dimid_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:548: undefined reference to `nf_inq_dimid_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:548: undefined reference to `nf_inq_dimid_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:548: undefined reference to `nf_inq_dimid_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:548: undefined reference to `nf_inq_dimid_'
ripdp_wrfarw.o:/home/lim/local/RIP4/src/./ripdp_wrfarw.f:564: more undefined references to `nf_inq_dimid_' follow
ripdp_wrfarw.o: In function `process_':
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:569: undefined reference to `nf_inq_varid_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:569: undefined reference to `nf_get_var_text_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:569: undefined reference to `nf_inq_varid_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:569: undefined reference to `nf_get_var_real_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:569: undefined reference to `nf_inq_varid_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:569: undefined reference to `nf_get_var_real_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:604: undefined reference to `nf_inq_varid_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:604: undefined reference to `nf_get_var_real_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:620: undefined reference to `nf_inq_dimid_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:620: undefined reference to `nf_inq_dimlen_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:672: undefined reference to `nf_get_att_real_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:692: undefined reference to `nf_get_att_int_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:692: undefined reference to `nf_get_att_int_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:714: undefined reference to `nf_get_att_real_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:714: undefined reference to `nf_get_att_real_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:735: undefined reference to `nf_get_att_real_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:744: undefined reference to `nf_get_att_int_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:753: undefined reference to `nf_get_att_real_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:753: undefined reference to `nf_get_att_real_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:779: undefined reference to `nf_get_att_text_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:817: undefined reference to `nf_inq_varid_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:837: undefined reference to `nf_get_att_text_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:889: undefined reference to `nf_inq_varid_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:889: undefined reference to `nf_get_vara_real_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:901: undefined reference to `nf_inq_varid_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:901: undefined reference to `nf_get_vara_real_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:928: undefined reference to `nf_inq_varid_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:928: undefined reference to `nf_get_vara_real_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:940: undefined reference to `nf_inq_varid_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:940: undefined reference to `nf_get_vara_real_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:952: undefined reference to `nf_get_att_int_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:973: undefined reference to `nf_get_att_int_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:998: undefined reference to `nf_get_att_int_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:1031: undefined reference to `nf_get_att_int_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:1056: undefined reference to `nf_get_att_real_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:1068: undefined reference to `nf_get_att_int_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:1086: undefined reference to `nf_get_att_int_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:1104: undefined reference to `nf_get_att_int_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:1121: undefined reference to `nf_get_att_int_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:1322: undefined reference to `nf_inq_varid_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:1322: undefined reference to `nf_inq_varid_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:1335: undefined reference to `nf_get_vara_real_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:1345: undefined reference to `nf_inq_varid_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:1345: undefined reference to `nf_inq_varid_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:1349: undefined reference to `nf_get_vara_real_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:1473: undefined reference to `nf_inq_varid_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:1487: undefined reference to `nf_inq_varid_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:1489: undefined reference to `nf_get_vara_real_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:1513: undefined reference to `nf_inq_varid_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:1524: undefined reference to `nf_inq_varid_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:1526: undefined reference to `nf_get_vara_real_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:1550: undefined reference to `nf_inq_varid_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:1572: undefined reference to `nf_get_vara_real_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:1585: undefined reference to `nf_inq_varid_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:1585: undefined reference to `nf_get_vara_real_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:1599: undefined reference to `nf_inq_varid_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:1599: undefined reference to `nf_get_vara_real_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:1621: undefined reference to `nf_inq_varid_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:1621: undefined reference to `nf_inq_varid_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:1635: undefined reference to `nf_get_vara_real_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:1656: undefined reference to `nf_get_vara_real_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:1675: undefined reference to `nf_inq_varid_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:1675: undefined reference to `nf_get_vara_real_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:1703: undefined reference to `nf_inq_varid_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:1703: undefined reference to `nf_get_vara_real_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:1741: undefined reference to `nf_inq_varid_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:1741: undefined reference to `nf_get_vara_real_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:1761: undefined reference to `nf_inq_varid_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:1761: undefined reference to `nf_get_vara_real_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:1800: undefined reference to `nf_inq_varid_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:1800: undefined reference to `nf_inq_varid_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:1807: undefined reference to `nf_get_vara_real_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:1817: undefined reference to `nf_inq_varid_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:1817: undefined reference to `nf_inq_varid_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:1817: undefined reference to `nf_get_vara_real_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:1848: undefined reference to `nf_get_vara_real_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:1859: undefined reference to `nf_inq_varid_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:1859: undefined reference to `nf_get_vara_real_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:1870: undefined reference to `nf_inq_varid_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:1870: undefined reference to `nf_get_vara_real_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:1887: undefined reference to `nf_inq_varid_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:1887: undefined reference to `nf_get_vara_real_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:1957: undefined reference to `nf_inq_varid_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:1957: undefined reference to `nf_get_vara_real_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:1976: undefined reference to `nf_inq_varid_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:1976: undefined reference to `nf_get_vara_real_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:2035: undefined reference to `nf_inq_varid_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:2035: undefined reference to `nf_inq_varid_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:2035: undefined reference to `nf_inq_varid_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:2045: undefined reference to `nf_get_vara_real_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:2053: undefined reference to `nf_inq_varid_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:2053: undefined reference to `nf_get_vara_real_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:2067: undefined reference to `nf_get_vara_real_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:2082: undefined reference to `nf_inq_varid_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:2082: undefined reference to `nf_inq_varid_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:2095: undefined reference to `nf_get_vara_real_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:2117: undefined reference to `nf_inq_varid_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:2117: undefined reference to `nf_get_vara_real_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:2137: undefined reference to `nf_inq_varid_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:2162: undefined reference to `nf_get_vara_real_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:2177: undefined reference to `nf_inq_varid_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:2185: undefined reference to `nf_get_vara_real_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:2200: undefined reference to `nf_inq_varid_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:2200: undefined reference to `nf_get_vara_real_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:2222: undefined reference to `nf_inq_varid_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:2222: undefined reference to `nf_get_vara_real_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:2236: undefined reference to `nf_inq_varid_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:2251: undefined reference to `nf_get_vara_real_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:2269: undefined reference to `nf_inq_varid_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:2277: undefined reference to `nf_get_vara_real_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:2295: undefined reference to `nf_inq_varid_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:2303: undefined reference to `nf_get_vara_real_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:2321: undefined reference to `nf_inq_varid_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:2329: undefined reference to `nf_get_vara_real_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:2347: undefined reference to `nf_inq_varid_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:2355: undefined reference to `nf_get_vara_real_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:2381: undefined reference to `nf_inq_varname_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:2414: undefined reference to `nf_inq_varndims_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:2414: undefined reference to `nf_inq_vardimid_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:2456: undefined reference to `nf_get_att_text_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:2456: undefined reference to `nf_get_att_text_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:2456: undefined reference to `nf_inq_attlen_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:2456: undefined reference to `nf_get_vara_real_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:2494: undefined reference to `nf_get_vara_real_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:2506: undefined reference to `nf_get_vara_real_'
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:2538: undefined reference to `nf_get_vara_real_'
ripdp_wrfarw.o: In function `handle_err_':
/home/lim/local/RIP4/src/./ripdp_wrfarw.f:2605: undefined reference to `nf_strerror_'
make: [ripdp_wrfarw] Error 2 (ignored)
pgf90 -byteswapio  -o ripdp_wrfnmm  ripdp_wrfnmm.f -L/opt/lib.pgi/NETCDF4/lib -lnetcdf  -I/opt/lib.pgi/NETCDF4/include \
		maptform.o	premaptform.o fillarray.o mconvert.o writefile_rdp.o \
		virtual.o xmapcalc.o egridfill.o xtodot.o 
ripdp_wrfnmm.f:
ripdp_wrfnmm.o: In function `ripdp_wrfnmm':
/home/lim/local/RIP4/src/./ripdp_wrfnmm.f:132: undefined reference to `nf_open_'
/home/lim/local/RIP4/src/./ripdp_wrfnmm.f:132: undefined reference to `nf_get_att_text_'
/home/lim/local/RIP4/src/./ripdp_wrfnmm.f:132: undefined reference to `nf_get_att_text_'
/home/lim/local/RIP4/src/./ripdp_wrfnmm.f:160: undefined reference to `nf_inq_dimid_'
/home/lim/local/RIP4/src/./ripdp_wrfnmm.f:160: undefined reference to `nf_inq_dimlen_'
/home/lim/local/RIP4/src/./ripdp_wrfnmm.f:160: undefined reference to `nf_inq_dimid_'
/home/lim/local/RIP4/src/./ripdp_wrfnmm.f:160: undefined reference to `nf_inq_dimlen_'
/home/lim/local/RIP4/src/./ripdp_wrfnmm.f:160: undefined reference to `nf_inq_dimid_'
/home/lim/local/RIP4/src/./ripdp_wrfnmm.f:160: undefined reference to `nf_inq_dimlen_'
/home/lim/local/RIP4/src/./ripdp_wrfnmm.f:160: undefined reference to `nf_get_att_text_'
/home/lim/local/RIP4/src/./ripdp_wrfnmm.f:268: undefined reference to `nf_close_'
/home/lim/local/RIP4/src/./ripdp_wrfnmm.f:284: undefined reference to `nf_open_'
/home/lim/local/RIP4/src/./ripdp_wrfnmm.f:284: undefined reference to `nf_inq_dimid_'
/home/lim/local/RIP4/src/./ripdp_wrfnmm.f:284: undefined reference to `nf_inq_dimlen_'
/home/lim/local/RIP4/src/./ripdp_wrfnmm.f:284: undefined reference to `nf_close_'
ripdp_wrfnmm.o: In function `process_':
/home/lim/local/RIP4/src/./ripdp_wrfnmm.f:663: undefined reference to `nf_open_'
/home/lim/local/RIP4/src/./ripdp_wrfnmm.f:663: undefined reference to `nf_inq_dimid_'
/home/lim/local/RIP4/src/./ripdp_wrfnmm.f:663: undefined reference to `nf_inq_dimlen_'
/home/lim/local/RIP4/src/./ripdp_wrfnmm.f:663: undefined reference to `nf_inq_'
/home/lim/local/RIP4/src/./ripdp_wrfnmm.f:684: undefined reference to `nf_inq_dimid_'
/home/lim/local/RIP4/src/./ripdp_wrfnmm.f:684: undefined reference to `nf_inq_dimid_'
/home/lim/local/RIP4/src/./ripdp_wrfnmm.f:684: undefined reference to `nf_inq_dimid_'
/home/lim/local/RIP4/src/./ripdp_wrfnmm.f:684: undefined reference to `nf_inq_dimid_'
/home/lim/local/RIP4/src/./ripdp_wrfnmm.f:684: undefined reference to `nf_inq_dimid_'
/home/lim/local/RIP4/src/./ripdp_wrfnmm.f:684: undefined reference to `nf_inq_varid_'
/home/lim/local/RIP4/src/./ripdp_wrfnmm.f:684: undefined reference to `nf_get_var_text_'
/home/lim/local/RIP4/src/./ripdp_wrfnmm.f:684: undefined reference to `nf_inq_dimid_'
/home/lim/local/RIP4/src/./ripdp_wrfnmm.f:684: undefined reference to `nf_inq_dimlen_'
/home/lim/local/RIP4/src/./ripdp_wrfnmm.f:684: undefined reference to `nf_get_att_real_'
/home/lim/local/RIP4/src/./ripdp_wrfnmm.f:755: undefined reference to `nf_get_att_real_'
/home/lim/local/RIP4/src/./ripdp_wrfnmm.f:758: undefined reference to `nf_get_att_real_'
/home/lim/local/RIP4/src/./ripdp_wrfnmm.f:761: undefined reference to `nf_get_att_real_'
/home/lim/local/RIP4/src/./ripdp_wrfnmm.f:764: undefined reference to `nf_inq_varid_'
/home/lim/local/RIP4/src/./ripdp_wrfnmm.f:764: undefined reference to `nf_get_vara_real_'
/home/lim/local/RIP4/src/./ripdp_wrfnmm.f:828: undefined reference to `nf_inq_varid_'
/home/lim/local/RIP4/src/./ripdp_wrfnmm.f:828: undefined reference to `nf_get_vara_real_'
/home/lim/local/RIP4/src/./ripdp_wrfnmm.f:884: undefined reference to `nf_get_att_text_'
/home/lim/local/RIP4/src/./ripdp_wrfnmm.f:899: undefined reference to `nf_inq_varid_'
/home/lim/local/RIP4/src/./ripdp_wrfnmm.f:919: undefined reference to `nf_get_att_text_'
/home/lim/local/RIP4/src/./ripdp_wrfnmm.f:919: undefined reference to `nf_get_att_int_'
/home/lim/local/RIP4/src/./ripdp_wrfnmm.f:968: undefined reference to `nf_get_att_int_'
/home/lim/local/RIP4/src/./ripdp_wrfnmm.f:968: undefined reference to `nf_get_att_int_'
/home/lim/local/RIP4/src/./ripdp_wrfnmm.f:987: undefined reference to `nf_get_att_int_'
/home/lim/local/RIP4/src/./ripdp_wrfnmm.f:1014: undefined reference to `nf_get_att_int_'
ripdp_wrfnmm.o:/home/lim/local/RIP4/src/./ripdp_wrfnmm.f:1014: more undefined references to `nf_get_att_int_' follow
ripdp_wrfnmm.o: In function `process_':
/home/lim/local/RIP4/src/./ripdp_wrfnmm.f:1043: undefined reference to `nf_get_att_real_'
/home/lim/local/RIP4/src/./ripdp_wrfnmm.f:1055: undefined reference to `nf_get_att_int_'
/home/lim/local/RIP4/src/./ripdp_wrfnmm.f:1069: undefined reference to `nf_get_att_int_'
/home/lim/local/RIP4/src/./ripdp_wrfnmm.f:1258: undefined reference to `nf_inq_varid_'
/home/lim/local/RIP4/src/./ripdp_wrfnmm.f:1258: undefined reference to `nf_get_vara_real_'
/home/lim/local/RIP4/src/./ripdp_wrfnmm.f:1278: undefined reference to `nf_inq_varid_'
/home/lim/local/RIP4/src/./ripdp_wrfnmm.f:1278: undefined reference to `nf_get_vara_real_'
/home/lim/local/RIP4/src/./ripdp_wrfnmm.f:1503: undefined reference to `nf_inq_varid_'
/home/lim/local/RIP4/src/./ripdp_wrfnmm.f:1503: undefined reference to `nf_get_vara_real_'
/home/lim/local/RIP4/src/./ripdp_wrfnmm.f:1560: undefined reference to `nf_inq_varid_'
/home/lim/local/RIP4/src/./ripdp_wrfnmm.f:1560: undefined reference to `nf_get_vara_real_'
/home/lim/local/RIP4/src/./ripdp_wrfnmm.f:1616: undefined reference to `nf_inq_varid_'
/home/lim/local/RIP4/src/./ripdp_wrfnmm.f:1616: undefined reference to `nf_get_vara_real_'
/home/lim/local/RIP4/src/./ripdp_wrfnmm.f:1647: undefined reference to `nf_inq_varid_'
/home/lim/local/RIP4/src/./ripdp_wrfnmm.f:1657: undefined reference to `nf_get_vara_real_'
/home/lim/local/RIP4/src/./ripdp_wrfnmm.f:1683: undefined reference to `nf_inq_varid_'
/home/lim/local/RIP4/src/./ripdp_wrfnmm.f:1683: undefined reference to `nf_get_vara_real_'
/home/lim/local/RIP4/src/./ripdp_wrfnmm.f:1713: undefined reference to `nf_inq_varid_'
/home/lim/local/RIP4/src/./ripdp_wrfnmm.f:1713: undefined reference to `nf_get_vara_real_'
/home/lim/local/RIP4/src/./ripdp_wrfnmm.f:1797: undefined reference to `nf_inq_varid_'
/home/lim/local/RIP4/src/./ripdp_wrfnmm.f:1797: undefined reference to `nf_get_vara_real_'
/home/lim/local/RIP4/src/./ripdp_wrfnmm.f:1967: undefined reference to `nf_inq_varid_'
/home/lim/local/RIP4/src/./ripdp_wrfnmm.f:2009: undefined reference to `nf_get_vara_real_'
/home/lim/local/RIP4/src/./ripdp_wrfnmm.f:2033: undefined reference to `nf_inq_varid_'
/home/lim/local/RIP4/src/./ripdp_wrfnmm.f:2042: undefined reference to `nf_get_vara_real_'
/home/lim/local/RIP4/src/./ripdp_wrfnmm.f:2066: undefined reference to `nf_inq_varid_'
/home/lim/local/RIP4/src/./ripdp_wrfnmm.f:2066: undefined reference to `nf_get_vara_real_'
/home/lim/local/RIP4/src/./ripdp_wrfnmm.f:2099: undefined reference to `nf_inq_varid_'
/home/lim/local/RIP4/src/./ripdp_wrfnmm.f:2113: undefined reference to `nf_get_vara_real_'
/home/lim/local/RIP4/src/./ripdp_wrfnmm.f:2127: undefined reference to `nf_inq_varid_'
/home/lim/local/RIP4/src/./ripdp_wrfnmm.f:2134: undefined reference to `nf_get_vara_real_'
/home/lim/local/RIP4/src/./ripdp_wrfnmm.f:2148: undefined reference to `nf_inq_varid_'
/home/lim/local/RIP4/src/./ripdp_wrfnmm.f:2155: undefined reference to `nf_get_vara_real_'
/home/lim/local/RIP4/src/./ripdp_wrfnmm.f:2169: undefined reference to `nf_inq_varid_'
/home/lim/local/RIP4/src/./ripdp_wrfnmm.f:2176: undefined reference to `nf_get_vara_real_'
/home/lim/local/RIP4/src/./ripdp_wrfnmm.f:2518: undefined reference to `nf_inq_varid_'
/home/lim/local/RIP4/src/./ripdp_wrfnmm.f:2526: undefined reference to `nf_get_vara_real_'
/home/lim/local/RIP4/src/./ripdp_wrfnmm.f:2553: undefined reference to `nf_inq_varid_'
/home/lim/local/RIP4/src/./ripdp_wrfnmm.f:2562: undefined reference to `nf_get_vara_real_'
/home/lim/local/RIP4/src/./ripdp_wrfnmm.f:2589: undefined reference to `nf_inq_varid_'
/home/lim/local/RIP4/src/./ripdp_wrfnmm.f:2598: undefined reference to `nf_get_vara_real_'
/home/lim/local/RIP4/src/./ripdp_wrfnmm.f:2625: undefined reference to `nf_inq_varid_'
/home/lim/local/RIP4/src/./ripdp_wrfnmm.f:2634: undefined reference to `nf_get_vara_real_'
/home/lim/local/RIP4/src/./ripdp_wrfnmm.f:2661: undefined reference to `nf_inq_varid_'
/home/lim/local/RIP4/src/./ripdp_wrfnmm.f:2670: undefined reference to `nf_get_vara_real_'
/home/lim/local/RIP4/src/./ripdp_wrfnmm.f:2708: undefined reference to `nf_inq_varname_'
/home/lim/local/RIP4/src/./ripdp_wrfnmm.f:2741: undefined reference to `nf_inq_varndims_'
/home/lim/local/RIP4/src/./ripdp_wrfnmm.f:2741: undefined reference to `nf_inq_vardimid_'
/home/lim/local/RIP4/src/./ripdp_wrfnmm.f:2778: undefined reference to `nf_get_att_text_'
/home/lim/local/RIP4/src/./ripdp_wrfnmm.f:2778: undefined reference to `nf_get_att_text_'
/home/lim/local/RIP4/src/./ripdp_wrfnmm.f:2778: undefined reference to `nf_inq_attlen_'
/home/lim/local/RIP4/src/./ripdp_wrfnmm.f:2778: undefined reference to `nf_get_vara_real_'
/home/lim/local/RIP4/src/./ripdp_wrfnmm.f:2818: undefined reference to `nf_get_vara_real_'
/home/lim/local/RIP4/src/./ripdp_wrfnmm.f:2840: undefined reference to `nf_get_vara_real_'
ripdp_wrfnmm.o: In function `handle_err_':
/home/lim/local/RIP4/src/./ripdp_wrfnmm.f:2916: undefined reference to `nf_strerror_'
make: [ripdp_wrfnmm] Error 2 (ignored)

Hi Happyez,

My best guess is you did not include “-Dpgifortran” in the “CPPFLAGS” when building NetCDF. Without this flag, NetCDF doesn’t decorate the Fortran to C interface functions with a trailing under score.

What is the output of the following command?

nm /opt/lib.pgi/NETCDF4/lib/libnetcdf.a | grep -i nf_get_vara_real

Note, instructions on building NetCDF can be found at http://www.pgroup.com/resources/netcdf/netcdf411_pgi2011.htm

  • Mat

Thank you
Mat

I compiled the NETCDF with “-Dpgifortran” in the “CPPFLAGS” .
And I added the “-lnetcdf -lnetcdff” in the configuration file.
After that, all of problems are resolved…

Thank you…