[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: 19990324: undefined reference to `nf_create__'



Baldeep,

> To: address@hidden
> From: baldeep hira <address@hidden>
> Subject: netcdf on linux
> Organization: Iowa State University
> Keywords: 199903222114.OAA11882

In the above message, you wrote:

> I compiled the netcdf on linux using gnu compilers namely gcc, g77
> and g++ and used the -Df2cFortran option.  It seemed to have gone 
> through the entire installation without any errors.  "make test" 
> command worked fine as well. The options that I used were
> 
> CC = gcc
> FC = g77
> CXX = g++
> CPPFLAGS = -Df2cFortran
> 
> But  when I try to make nf calls  like "nf_open", "nf_create" in 
> my fortran code it gives a link time error like
> 
> /tmp/cca026031.o(.text+0x365): undefined reference to `nf_create__'
> /tmp/cca026031.o(.text+0xa03): undefined reference to `nf_def_dim__'
> /tmp/cca026031.o(.text+0xa2a): undefined reference to `errore_'
> /tmp/cca026031.o(.text+0xa56): undefined reference to `nf_def_var__'
> /tmp/cca026031.o(.text+0xa7d): undefined reference to `errore_'
> /tmp/cca026031.o(.text+0xaa4): undefined reference to `nf_put_att_text__'   
> /tmp/cca026031.o(.text+0x3a0): undefined reference to `nf_close__'    
> 
> 
> Do you have any suggestions as to what the error may be? Could it 
> be a problem in f2c conversion? Or did I use some wrong option for 
> compiling the source for netcdf?

I'll need more information in order to diagnose the problem.  Would you
please send me the command that you used to link your program together
with any output the link command generated (such as the above).  The
problem could be a simple as an improper reference to the netCDF
library.

--------
Steve Emmerson   <http://www.unidata.ucar.edu>