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

970416: netCDF installation problems



Joerg,

> To: address@hidden
> cc: address@hidden
> From: Joerg Kaduk <address@hidden>
> Subject: netCDF installation problems
> Organization: Stanford University
> Keywords: 199704160532.XAA03476

In the above message, you wrote:

> I'm writing since I got stuck in trying to install netCDF here.
> I obtained:
> netcdf-3.3a.tar
> 
> I ran configure as follows and it said:
> 
> stipa.Stanford.EDU% .
> /home/joerg/netcdf/netcdf-3.3a/src
> 
> stipa.Stanford.EDU% setenv CPPFLAGS=-DNDEBUG

The above should have been "setenv CPPFLAGS -DNDEBUG" (no "=").

> stipa.Stanford.EDU% setenv CFLAGS -O
> 
> stipa.Stanford.EDU% configure -prefix=/home/joerg/netcdf/netcdf-3.3a/src
> creating cache ./config.cache
> checking for f77... f77
> checking for f77... (cached) f77
> checking for cc... cc
> checking type of operating system... sunos5
> checking for ar... ar
> checking for ranlib... ranlib
> checking how to run the C preprocessor... cc -E
> checking for stdlib.h... yes
> checking for sys/types.h... yes
> checking for strerror... yes
> checking for ftruncate... yes
> checking for st_blksize in struct stat... yes
> checking whether cross-compiling... no
> checking for IEEE floating point format... no
> checking for ANSI C header files... yes
> checking for size_t... yes
> checking for off_t... yes
> checking for ssize_t... yes
> checking for ptrdiff_t... yes
> checking for uchar... no
> checking whether char is unsigned... no
> checking whether byte ordering is bigendian... yes
> checking size of short... 2
> checking size of int... 4
> checking size of long... 4
> checking size of float... 4
> checking size of double... 8
> checking size of off_t... 4
> checking size of size_t... 4
> updating cache ./config.cache
> creating ./config.status
> creating macros.make
> creating libsrc/ncconfig.h
> stipa.Stanford.EDU% 
> 
> So far that seemed to have worked. 
> However I'm a bit confused about the statement:
> checking for IEEE floating point format... no

Our sun4/sunos5 system uses IEEE format.  I wonder if the missetting of
the CPPFLAGS environment variable could have caused this?

Anyway, would you please send me the standard output from the command
"uname -a".

> 
> Config.log looks like this:
> ::::::::::::::
> config.log
> ::::::::::::::
> This file contains any messages produced by compilers while
> running configure, to aid debugging if configure makes a mistake.
> 
> configure:1545: cc -E -DNDEBUG= conftest.c >/dev/null 2>conftest.out
> configure:1591: cc -E -DNDEBUG= conftest.c >/dev/null 2>conftest.out
> configure:1625: cc -E -DNDEBUG= conftest.c >/dev/null 2>conftest.out
> configure:1675: cc -o conftest -O -DNDEBUG=  conftest.c  1>&5
> configure:1723: cc -o conftest -O -DNDEBUG=  conftest.c  1>&5
> configure:1757: cc -c -O -DNDEBUG= conftest.c 1>&5
> configure:1789: cc -o conftest -O -DNDEBUG=  conftest.c  1>&5
> configure:1839: cc -o conftest -O -DNDEBUG=  conftest.c  1>&5
> "configure", line 1823:  (in preprocessor if): syntax error
> configure:1868: cc -E -DNDEBUG= conftest.c >/dev/null 2>conftest.out
> configure:1933: cc -o conftest -O -DNDEBUG=  conftest.c  1>&5
> configure:2151: cc -o conftest -O -DNDEBUG=  conftest.c  1>&5
> "configure", line 2147: warning: initializer does not fit or is out of range: 
> 25
> 5
> configure:2189: cc -c -O -DNDEBUG= conftest.c 1>&5
> "configure", line 2184: undefined symbol: bogus
> "configure", line 2184: syntax error before or at: endian
> configure:2235: cc -o conftest -O -DNDEBUG=  conftest.c  1>&5
> configure:2273: cc -o conftest -O -DNDEBUG=  conftest.c  1>&5
> configure:2307: cc -o conftest -O -DNDEBUG=  conftest.c  1>&5
> configure:2341: cc -o conftest -O -DNDEBUG=  conftest.c  1>&5
> configure:2375: cc -o conftest -O -DNDEBUG=  conftest.c  1>&5
> configure:2409: cc -o conftest -O -DNDEBUG=  conftest.c  1>&5
> configure:2447: cc -o conftest -O -DNDEBUG=  conftest.c  1>&5
> configure:2485: cc -o conftest -O -DNDEBUG=  conftest.c  1>&5
> 
> 
> I'm a bit confused about the messages, but I don't know enough about
> this stuff to have any idea what all this is about....

The above file (config.log) contains error message from the tests that
the configure script runs.  Thus, it's expected to not be empty.  I
don't, however, see any major problems in the above.

> Admittedly I don't have any idea whether this  -DNDEBUG= 
> is correct either....

It isn't correct.

> Runnning make resulted teh in a lot of unpleasent messages:
> 
> stipa.Stanford.EDU% make
> 
> Making `all' in directory /home/joerg/netcdf/netcdf-3.3a/src/libsrc
> 
> cc -c -O   -DNDEBUG= attr.c
> "./netcdf.h", line 290: warning: signed is a keyword in ANSI C
> "./netcdf.h", line 290: syntax error before or at: signed
> "./netcdf.h", line 290: warning: undefined or missing type for: signed
> "./netcdf.h", line 293: syntax error before or at: signed
> "./netcdf.h", line 293: warning: undefined or missing type for: signed
> ....
> This goes on like that for a while and then:
> "./netcdf.h", line 607: syntax error before or at: signed
> "./netcdf.h", line 607: warning: undefined or missing type for: signed
> "./netcdf.h", line 613: syntax error before or at: signed
> "./netcdf.h", line 613: warning: undefined or missing type for: signed
> "./netcdf.h", line 691: syntax error before or at: signed
> "./netcdf.h", line 691: warning: undefined or missing type for: signed
> "./netcdf.h", line 694: syntax error before or at: signed
> "./netcdf.h", line 694: warning: undefined or missing type for: signed
> "./ncx.h", line 135: undefined or not a type: signed
> "./ncx.h", line 135: warning: "typedef" valid only for function declaration
> "./ncx.h", line 135: parameter not in identifier list: schar
> "./ncx.h", line 220: only "register" valid as formal parameter storage class
> "./ncx.h", line 221: syntax error before or at: schar
> "./ncx.h", line 221: warning: undefined or missing type for: schar
> "./ncx.h", line 221: parameter not in identifier list: ncx_get_short_schar
> "./ncx.h", line 222: only "register" valid as formal parameter storage class
> "./ncx.h", line 223: parameter not in identifier list: ncx_get_short_uchar
> "./ncx.h", line 224: only "register" valid as formal parameter storage class
> "./ncx.h", line 225: parameter not in identifier list: ncx_get_short_short
> "./ncx.h", line 226: only "register" valid as formal parameter storage class
> "./ncx.h", line 227: parameter not in identifier list: ncx_get_short_int
> "./ncx.h", line 228: only "register" valid as formal parameter storage class
> "./ncx.h", line 229: parameter not in identifier list: ncx_get_short_long
> "./ncx.h", line 230: only "register" valid as formal parameter storage class
> "./ncx.h", line 231: parameter not in identifier list: ncx_get_short_float
> "./ncx.h", line 232: only "register" valid as formal parameter storage class
> "./ncx.h", line 233: parameter not in identifier list: ncx_get_short_double
> "./ncx.h", line 235: only "register" valid as formal parameter storage class
> "./ncx.h", line 236: syntax error before or at: schar
> "./ncx.h", line 236: warning: undefined or missing type for: schar
> "./ncx.h", line 236: parameter not in identifier list: ncx_put_short_schar
> "./ncx.h", line 237: only "register" valid as formal parameter storage class
> "./ncx.h", line 238: parameter not in identifier list: ncx_put_short_uchar
> 
> this does go on for some time as well ... ending with:
> 
> "./ncx.h", line 641: only "register" valid as formal parameter storage class
> "./ncx.h", line 642: parameter not in identifier list: ncx_getn_void
> "./ncx.h", line 643: only "register" valid as formal parameter storage class
> "./ncx.h", line 644: parameter not in identifier list: ncx_pad_getn_void
> "./ncx.h", line 647: only "register" valid as formal parameter storage class
> "./ncx.h", line 648: parameter not in identifier list: ncx_putn_void
> "./ncx.h", line 649: only "register" valid as formal parameter storage class
> "./ncx.h", line 650: parameter not in identifier list: ncx_pad_putn_void
> "attr.c", line 25: parameter not in identifier list: free_NC_attr
> "attr.c", line 25: syntax error before or at: {
> "attr.c", line 28: warning: syntax error:  empty declaration
> "attr.c", line 29: syntax error before or at: ->
> "attr.c", line 29: parameter not in identifier list: free_NC_string
> "attr.c", line 30: warning: function prototype parameters must have types
> "attr.c", line 30: parameter not in identifier list: free
> "attr.c", line 31: syntax error before or at: }
> "attr.c", line 38: only "register" valid as formal parameter storage class
> "attr.c", line 40: parameter not in identifier list: ncx_len_NC_attrV
> "attr.c", line 41: undefined symbol: type
> "attr.c", line 44: undefined symbol: nelems
> "attr.c", line 55: undefined symbol: stderr
> "attr.c", line 57: cannot recover from previous errors
> *** Error code 10
> make: Fatal error: Command failed for target `attr.o'
> Current working directory /home/joerg/netcdf/netcdf-3.3a/src/libsrc
> *** Error code 1
> make: Fatal error: Command failed for target `subdir_target'
> Current working directory /home/joerg/netcdf/netcdf-3.3a/src
> *** Error code 1
> make: Fatal error: Command failed for target `libsrc/all'
> stipa.Stanford.EDU% 

The above is bad.  Which "cc" are you using (i.e. what's its absolute
pathname and version)?  Do you have a "c89"?

> 
> I did try configure and make after an unsetenv CPPFLAGS again and
> running configure explicit under sh but that didn't change much ...

Because the configure script caches its finding in the file
"config.cache" and uses those findings when being re-executed, merely
re-executing the configure script won't change things much unless the
file "config.cache" is deleted first.

> config.log became:
> stipa.Stanford.EDU% m config.log
> This file contains any messages produced by compilers while
> running configure, to aid debugging if configure makes a mistake.
> 
> configure:1839: cc -o conftest -O   conftest.c  1>&5
> "configure", line 1823:  (in preprocessor if): syntax error
> 
> 
> I hope it's not all about something I could have easily figured
> out myself - although I don't have much an idea about C...

Well... The problem isn't obvious to me either.

> Sorry for all that garbage above - 'hope it helps... you and/or me?
> Anyway I'm looking forward to hearing from you. Thank you
> very much for all your patience and time!!

You're welcome.  Just send me the answers to my questions and we should
have you up and running soon.

--------
Steve Emmerson   <address@hidden>