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

20020910: undef ref to 'nf_... (cont.)



>From: James McCreight <address@hidden>
>Organization: UMT
>Keywords: 200209031656.g83GuXZ04528 netCDF

James,

>In response to the message below (way down at the bottom), I have rebuilt
>netcdf and everything looks good to me. Just to make sure, I have included
>all the details below as directed in INSTALL.html #1-9.

Good.  This makes troubleshooting possible.

>I entered the env vars as
>specified except that I had to change FC according to the correct path for my
>pgf90.  Yes, I exported them too. 

Good.

>But, this reinstallation has not fixed my problem.
>My code uses libnetcdf.a and netcdf.inc. I think the problem is coming from
>the some sort of compiler interaction with netcdf.inc, but really am not be
>sure.
>The error message i get compiling my ccsm sea ice code follows directly after
>this message and the items A-H from INSTALL.html follow that.
>Please help!

I don't know if the output from your compile of the CCSM code is exact
(i.e., if the output shows spaces where they are and doesn't add spaces
where they aren't), but assuming it is, the following looks like an
error:

>./compile/ice_diagnostics.o -L/usr/local/lib/-lnetcdf 

What you have tells the linker to search the directory
/usr/local/lib/-lnetcdf for libraries.  What you want is to tell the
linker to search /usr/local/lib for libraries, including libnetcdf.a.

The way one specifies the search of a library is:

-L/usr/local/lib -lnetcdf
        ^       ^    ^____ library to search
        |       |_________ this is a space!
        |_________________ the directory in which to look for libraries

This specification will assume that libnetcdf.a is located in 
/usr/local/lib.

>Thanks again,

Please let me know if this isn't your problem.

Tom Yoksas