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

Re: 20000229: help building netcdf3-4



>To: Unidata Support <address@hidden>
>From: Eric Pani <address@hidden>
>Subject: help building netcdf3-4
>Organization: Northeast Louisiana University

Hi Eric,

> We are rebuilding our entire system from scratch because we got hacked
> into last year.
>
> We are running Solaris 5.7 with the SUNWspro compilers (v 5.0) on a
> SPARC 20.  I've built udunits-1.11.7 successfully but had to exclude the
> perl modules.  Now I'm trying to get netcdf-3.4 built and ran into a
> snag.  I've attached the log file from the configure and make commands.
> It seems that the build crashed with it hit a C compilation but I am
> stuck about a fix.
 ...
> loading cache ./config.cache
> checking for m4... (cached) m4
> checking for xlc... (cached) c89
> checking C compiler... works
> checking how to make dependencies... cc -xM
> checking for CC... (cached) CC
> checking C++ compiler "CC"... works
 ...
> Making `all' in directory /opt/unidata/netcdf-3.4/src/cxx
>
> ar cru libnetcdf_c++.a netcdf.o ncvalues.o
> ranlib libnetcdf_c++.a
> CC -o nctst -I../libsrc  -DNDEBUG -O  nctst.o libnetcdf_c++.a -L../libsrc 
> -lnetcdf 
> Undefined                     first referenced
>  symbol                           in file
> std::bad_alloc::__vtbl          
> /opt/SUNWspro/SC5.0/lib/libCstd.a(zOtiZS4hQ7CvMDXtQoDv.o)
> [Hint: try checking whether the first non-inlined, non-pure virtual function 
> of class std is defined]
>
> void __Cimpl::cplus_init()        (command line)
> ld: fatal: Symbol referencing errors. No output written to nctst
> *** Error code 1
> make: Fatal error: Command failed for target `nctst'
> Current working directory /opt/unidata/netcdf-3.4/src/cxx

This is an error in trying to link a C++ test program with the C++
interface ("CC" is the C++ compiler), which was apparently compiled
correctly.  I've never seen this error before, but I notice when you
ran the "configure" script there's several results that were
"(cached)", indicating the configure script is using the results from
a previous "configure" run rather than computing the results from
scratch.  To prevent this, please remove the file "config.cache" and
run "make clean" before running the "configure" script, to make sure
it isn't using results from a "config.cache" file generated long ago
or on a different platform.

If that doesn't fix the problem, please tell us which version of C++
compiler you are using, by running "CC -V" and sending us the output.
On our Solaris 5.7 system, we have:

    $ CC -V
    CC: WorkShop Compilers 5.0 98/12/15 C++ 5.0

Finally, if we can't reproduce the problem here, and you don't really
need the C++ netCDF interface (none of the Unidata software uses it),
you might be able to get around the problem by just building netCDF
without the C++ interface, by setting the CXX environment variable to
"" before you invoke the "configure" script.

--Russ