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

Re: 19990601: netcdf "make test" failure under Red Hat Linux 2.2.5



Graham,

>Date: Wed, 02 Jun 1999 16:03:54 +0000
>From: Graham Campbell <address@hidden>
>Organization: Brookhaven National Laboratory
>To: Steve Emmerson <address@hidden>
>Subject: Re: 19990601: netcdf "make test" failure under Red Hat Linux 2.2.5
>Keywords: 199905282013.OAA17107

In the above message, you wrote:

> > If you're using /usr/bin/g77 as your Fortran compiler (/usr/bin/f77 is
> > a link to /usr/bin/g77 on our Red Hat Linux system) then -- according
> > to the TESTED SYSTEMS section in the INSTALL file -- you shouldn't use the
> > "-Nx400" option.
> 
> I don't want to nit-pick too much since you have been very helpful,
> but there is only one Linux system in the INSTALL file that comes with
> 3.4 and it has the -Nx400 option.

You're right.  Sorry about that.  I was looking at the next version of
the INSTALL file (which has a g77" example -- for which the "-Nx400"
option is invalid).

> ... On the RedHat system we are
> running there is no fort77, which is used in the INSTALL file and it
> came as a complete surprise to me that f77 is a link to g77. How are
> you supposed to keep up with this stuff? Well anyway.

You think you've got problems?  Try managing a package that's supposed
to build under almost all possible combinations of hardware, operating
systems, compilers, and options! :-)

> >     1.  Fix your system's clock.
> >
> >     2.  Perform steps 2 through 4 near the end of the INSTALL file.
> >
> >     3.  Set your environment variables as before but ensure that the
> >         following environment variables have the suggested values:
> >
> >             ENVIRONMENT VARIABLE        SUGGESTED VALUE
> >             --------------------        ----------------
> >             FC                          /usr/bin/g77 (assuming it
> >                                                       exists; otherwise, use
> >                                                       /usr/bin/f77 again)
> >             FFLAGS                      -O -Wno-globals
> >
> >     4.  Perform steps 6 through 9 near the end of the INSTALL file.
...
> I did the above and got essentially the same results. I attach all the
> usual files. (PS the clock problem went away)

The clock problem went away?  That's amazing.

...
> --------------EE087DDB1E868AEB2B364597
> Content-Type: text/plain; charset=us-ascii;
>  name="config.log"
> Content-Transfer-Encoding: 7bit
> Content-Disposition: inline;
>  filename="config.log"
> 
> This file contains any messages produced by compilers while
> running configure, to aid debugging if configure makes a mistake.
> 
> configure:1020: /usr/bin/cc -c -g -Df2cFortran conftest.c 1>&5
> configure:1153: /usr/bin/c++ -c  -Df2cFortran conftest.C 1>&5
> configure:1220: /usr/bin/cc -E -Df2cFortran conftest.c >/dev/null 
> 2>conftest.out
> configure:1319: /usr/bin/g77 -c -O -Wno-globals conftest.f
> configure:1422: /usr/bin/g77 -o conftest -O -Wno-globals conftest.F  
> configure:1463: /usr/bin/g77 -c -O -Wno-globals conftest.f
> configure:1498: /usr/bin/g77 -c -O -Wno-globals conftest.f
> configure:1521: /usr/bin/g77 -c -O -Wno-globals conftest.f
> configure:1555: /usr/bin/cc -c -Df2cFortran -g conftest.c
> configure:1557: /usr/bin/g77 -O -Wno-globals -c conftestf.f
> configure:1559: /usr/bin/g77 -o conftest -O -Wno-globals  conftestf.o 
> conftest.o 
> configure:1561: ./conftest
> configure:1602: /usr/bin/cc -c -Df2cFortran -g conftest.c
> configure:1604: /usr/bin/g77 -O -Wno-globals -c conftestf.f
> configure:1606: /usr/bin/g77 -o conftest -O -Wno-globals  conftestf.o 
> conftest.o 
> configure:1608: ./conftest
> configure:1649: /usr/bin/cc -c -Df2cFortran -g conftest.c
> configure:1651: /usr/bin/g77 -O -Wno-globals -c conftestf.f
> configure:1653: /usr/bin/g77 -o conftest -O -Wno-globals  conftestf.o 
> conftest.o 
> configure:1655: ./conftest
> configure:1696: /usr/bin/cc -c -Df2cFortran -g conftest.c
> configure:1698: /usr/bin/g77 -O -Wno-globals -c conftestf.f
> configure:1700: /usr/bin/g77 -o conftest -O -Wno-globals  conftestf.o 
> conftest.o 
> configure:1702: ./conftest
> configure:1747: /usr/bin/cc -c -Df2cFortran -g conftest.c
> configure:1749: /usr/bin/g77 -O -Wno-globals -c conftestf.f
> configure:1751: /usr/bin/g77 -o conftest -O -Wno-globals  conftestf.o 
> conftest.o 
> configure:1753: ./conftest
> configure:1794: /usr/bin/cc -c -Df2cFortran -g conftest.c
> configure:1796: /usr/bin/g77 -O -Wno-globals -c conftestf.f
> configure:1798: /usr/bin/g77 -o conftest -O -Wno-globals  conftestf.o 
> conftest.o 
> configure:1800: ./conftest
> configure:1841: /usr/bin/cc -c -Df2cFortran -g conftest.c
> configure:1843: /usr/bin/g77 -O -Wno-globals -c conftestf.f
> configure:1845: /usr/bin/g77 -o conftest -O -Wno-globals  conftestf.o 
> conftest.o 
> configure:1847: ./conftest
> configure:1890: /usr/bin/cc -c -Df2cFortran -g conftest.c
> configure:1892: /usr/bin/g77 -O -Wno-globals -c conftestf.f
> configure:1894: /usr/bin/g77 -o conftest -O -Wno-globals  conftestf.o 
> conftest.o 
> configure:1896: ./conftest
> configure:1937: /usr/bin/cc -c -Df2cFortran -g conftest.c
> configure:1939: /usr/bin/g77 -O -Wno-globals -c conftestf.f
> configure:1941: /usr/bin/g77 -o conftest -O -Wno-globals  conftestf.o 
> conftest.o 
> configure:1943: ./conftest
> configure:1984: /usr/bin/cc -c -Df2cFortran -g conftest.c
> configure:1986: /usr/bin/g77 -O -Wno-globals -c conftestf.f
> configure:1988: /usr/bin/g77 -o conftest -O -Wno-globals  conftestf.o 
> conftest.o 
> configure:1990: ./conftest
> configure:2023: /usr/bin/g77 -c -O -Wno-globals conftest.f
> configure:2044: /usr/bin/g77 -c -O -Wno-globals conftest.f
> configure:2084: /usr/bin/cc -o conftest -g -Df2cFortran  conftest.c -lc   1>&5
> /tmp/ccHcWvEq.o: In function `t':
> /home/gc/netcdf-linux/netcdf-3.4/src/configure:2080: undefined reference to 
> `tanh'
> collect2: ld returned 1 exit status
> configure:2118: /usr/bin/cc -o conftest -g -Df2cFortran  conftest.c -lm   1>&5
> configure:2213: /usr/bin/cc -E -Df2cFortran conftest.c >/dev/null 
> 2>conftest.out
> configure:2247: /usr/bin/cc -E -Df2cFortran conftest.c >/dev/null 
> 2>conftest.out
> configure:2297: /usr/bin/cc -o conftest -g -Df2cFortran  conftest.c  1>&5
> configure:2331: /usr/bin/cc -o conftest -g -Df2cFortran  conftest.c  1>&5
> configure:2398: /usr/bin/cc -o conftest -g -Df2cFortran  conftest.c  1>&5
> configure:2428: /usr/bin/cc -o conftest -g -Df2cFortran  conftest.c  1>&5
> configure:2476: /usr/bin/cc -o conftest -g -Df2cFortran  conftest.c  1>&5
> configure:2644: /usr/bin/cc -c -g -Df2cFortran conftest.c 1>&5
> configure:2702: /usr/bin/cc -o conftest -g -Df2cFortran  conftest.c  1>&5
> configure:2731: /usr/bin/cc -E -Df2cFortran conftest.c >/dev/null 
> 2>conftest.out
> configure:2796: /usr/bin/cc -o conftest -g -Df2cFortran  conftest.c  1>&5
> configure:3014: /usr/bin/cc -o conftest -g -Df2cFortran  conftest.c  1>&5
> configure:3052: /usr/bin/cc -c -g -Df2cFortran conftest.c 1>&5
> configure:3068: /usr/bin/cc -c -g -Df2cFortran conftest.c 1>&5
> configure: In function `t':
> configure:3063: `not' undeclared (first use in this function)
> configure:3063: (Each undeclared identifier is reported only once
> configure:3063: for each function it appears in.)
> configure:3063: parse error before `big'
> configure:3136: /usr/bin/cc -o conftest -g -Df2cFortran  conftest.c  1>&5
> configure:3170: /usr/bin/cc -o conftest -g -Df2cFortran  conftest.c  1>&5
> configure:3204: /usr/bin/cc -o conftest -g -Df2cFortran  conftest.c  1>&5
> configure:3238: /usr/bin/cc -o conftest -g -Df2cFortran  conftest.c  1>&5
> configure:3272: /usr/bin/cc -o conftest -g -Df2cFortran  conftest.c  1>&5
> configure:3310: /usr/bin/cc -o conftest -g -Df2cFortran  conftest.c  1>&5
> configure:3348: /usr/bin/cc -o conftest -g -Df2cFortran  conftest.c  1>&5

The above looks like regular results from the configure script as it
explores your system.  It indicates no obvious problem.

> --------------EE087DDB1E868AEB2B364597
> Content-Type: text/plain; charset=us-ascii;
>  name="configure.log"
> Content-Transfer-Encoding: 7bit
> Content-Disposition: inline;
>  filename="configure.log"
> 
> creating cache ./config.cache
> checking for m4... m4
> checking user-defined C compiler "/usr/bin/cc"
> checking C compiler... works
> checking how to make dependencies... false
> checking for /usr/bin/c++... /usr/bin/c++
> checking C++ compiler "/usr/bin/c++"... works
> checking how to run the C preprocessor... /usr/bin/cc -E
> checking user-defined Fortran compiler "/usr/bin/g77"... works
> checking for Fortran .F compiler... 
> checking if Fortran compiler handles *.F files... yes
> checking for C-equivalent to Fortran routine "SUB"... sub_
> checking for Fortran "byte"... yes
> checking for Fortran "integer*2"... yes
> checking if Fortran "byte" is C "signed char"... yes
> checking if Fortran "byte" is C "short"... no
> checking if Fortran "byte" is C "int"... no
> checking if Fortran "byte" is C "long"... no
> checking if Fortran "integer*2" is C "short"... yes
> checking if Fortran "integer*2" is C "int"... no
> checking if Fortran "integer*2" is C "long"... no
> checking if Fortran "integer" is C "int"... yes
> checking if Fortran "real" is C "float"... yes
> checking if Fortran "doubleprecision" is C "double"... yes
> checking for Fortran-equivalent to netCDF "byte"... byte
> checking for Fortran-equivalent to netCDF "short"... integer*2
> checking for math library
> checking for -lc... no
> checking for -lm... yes
> checking for ar... ar
> checking for ranlib... ranlib
> checking for stdlib.h... yes
> checking for sys/types.h... yes
> checking for strerror... yes
> checking whether cross-compiling... no
> checking for working ftruncate()... yes
> checking for working alloca.h... yes
> checking for alloca... yes
> checking for st_blksize in struct stat... yes
> checking for IEEE floating point format... yes
> 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... no
> 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
> checking for manual-page index command... 
> checking binary distribution directory... /home/ftp/pub/binary/dummy_system
> updating cache ./config.cache
> creating ./config.status
> creating macros.make
> udcreating fortran/nfconfig.inc
> creating libsrc/ncconfig.h

The above looks OK.

> --------------EE087DDB1E868AEB2B364597
> Content-Type: text/plain; charset=us-ascii;
>  name="details.log"
> Content-Transfer-Encoding: 7bit
> Content-Disposition: inline;
>  filename="details.log"
> 
> + uname -a
> Linux pro11.bnl.gov 2.2.5-15smp #1 SMP Mon Apr 19 22:43:28 EDT 1999 i686 
> unknown
> + cat VERSION
> 3.4
> + env
...
> CC=/usr/bin/cc
> CXX=/usr/bin/c++
...
> LD_LIBRARY_PATH=/usr/openwin/lib:/usr/lib:/opt/SUNWSpro/lib:/usr/dt/lib
...
> FC=/usr/bin/g77
> CPPFLAGS=-Df2cFortran
> CFLAGS=-g
...
> PATH=/usr/bin:/bin:/sbin:/usr/bin:/usr/sbin:/usr/X11R6/bin:/usr/bin:/usr/X11R6/bin:/usr/sbin:/usr/dt/bin:/usr/openwin/bin:/opt/SUNWspro/bin:/home/gc/tomog/src:/home/gc/tomog/src/gridrec2:/usr/local/bin:/home/gc/tomog/ncview/ncview-1.72e:/home/gc/netcdf-3.5a/bin
...
> FFLAGS=-O -Wno-globals
...

The above looks OK.

> --------------EE087DDB1E868AEB2B364597
> Content-Type: text/plain; charset=us-ascii;
>  name="make.log"
> Content-Transfer-Encoding: 7bit
> Content-Disposition: inline;
>  filename="make.log"
> 
> make[1]: Entering directory `/home/gc/netcdf-linux/netcdf-3.4/src'
> 
> Making `all' in directory /home/gc/netcdf-linux/netcdf-3.4/src/libsrc
> 
> make[2]: Entering directory `/home/gc/netcdf-linux/netcdf-3.4/src/libsrc'
> /usr/bin/cc -c -g -I.  -Df2cFortran attr.c
> /usr/bin/cc -c -g -I.  -Df2cFortran dim.c
> /usr/bin/cc -c -g -I.  -Df2cFortran error.c
> /usr/bin/cc -c -g -I.  -Df2cFortran -DVERSION=`cat ../VERSION` libvers.c
> /usr/bin/cc -c -g -I.  -Df2cFortran nc.c
> /usr/bin/cc -c -g -I.  -Df2cFortran ncio.c
> /usr/bin/cc -c -g -I.  -Df2cFortran ncx.c
> /usr/bin/cc -c -g -I.  -Df2cFortran putget.c
> /usr/bin/cc -c -g -I.  -Df2cFortran string.c
> /usr/bin/cc -c -g -I.  -Df2cFortran v1hpg.c
> /usr/bin/cc -c -g -I.  -Df2cFortran v2i.c
> /usr/bin/cc -c -g -I.  -Df2cFortran var.c
> ar cru         libnetcdf.a attr.o dim.o error.o libvers.o nc.o ncio.o ncx.o 
> putget.o string.o v1hpg.o v2i.o var.o
> ranlib libnetcdf.a
> make[2]: Leaving directory `/home/gc/netcdf-linux/netcdf-3.4/src/libsrc'
> 
> Returning to directory /home/gc/netcdf-linux/netcdf-3.4/src
> 
> make[1]: Leaving directory `/home/gc/netcdf-linux/netcdf-3.4/src'
> make[1]: Entering directory `/home/gc/netcdf-linux/netcdf-3.4/src'
> 
> Making `all' in directory /home/gc/netcdf-linux/netcdf-3.4/src/fortran
> 
> make[2]: Entering directory `/home/gc/netcdf-linux/netcdf-3.4/src/fortran'
> /usr/bin/cc -c -g -I../libsrc  -Df2cFortran fort-attio.c
> /usr/bin/cc -c -g -I../libsrc  -Df2cFortran fort-control.c
> /usr/bin/cc -c -g -I../libsrc  -Df2cFortran fort-dim.c
> /usr/bin/cc -c -g -I../libsrc  -Df2cFortran fort-genatt.c
> /usr/bin/cc -c -g -I../libsrc  -Df2cFortran fort-geninq.c
> /usr/bin/cc -c -g -I../libsrc  -Df2cFortran fort-genvar.c
> /usr/bin/cc -c -g -I../libsrc  -Df2cFortran fort-lib.c
> /usr/bin/cc -c -g -I../libsrc  -Df2cFortran fort-misc.c
> /usr/bin/cc -c -g -I../libsrc  -Df2cFortran fort-v2compat.c
> /usr/bin/cc -c -g -I../libsrc  -Df2cFortran fort-vario.c
> /usr/bin/cc -c -g -I../libsrc  -Df2cFortran fort-var1io.c
> /usr/bin/cc -c -g -I../libsrc  -Df2cFortran fort-varaio.c
> /usr/bin/cc -c -g -I../libsrc  -Df2cFortran fort-varmio.c
> /usr/bin/cc -c -g -I../libsrc  -Df2cFortran fort-varsio.c
> ar cru         ../libsrc/libnetcdf.a fort-attio.o fort-control.o fort-dim.o 
> fort-genatt.o fort-geninq.o fort-genvar.o fort-lib.o fort-misc.o 
> fort-v2compat.o fort-vario.o fort-var1io.o fort-varaio.o fort-varmio.o 
> fort-varsio.o
> ranlib ../libsrc/libnetcdf.a
> make[2]: Leaving directory `/home/gc/netcdf-linux/netcdf-3.4/src/fortran'
> 
> Returning to directory /home/gc/netcdf-linux/netcdf-3.4/src
> 
> make[1]: Leaving directory `/home/gc/netcdf-linux/netcdf-3.4/src'
> make[1]: Entering directory `/home/gc/netcdf-linux/netcdf-3.4/src'
> 
> Making `all' in directory /home/gc/netcdf-linux/netcdf-3.4/src/ncdump
> 
> make[2]: Entering directory `/home/gc/netcdf-linux/netcdf-3.4/src/ncdump'
> /usr/bin/cc -c -g -I../libsrc  -Df2cFortran ncdump.c
> /usr/bin/cc -c -g -I../libsrc  -Df2cFortran vardata.c
> /usr/bin/cc -c -g -I../libsrc  -Df2cFortran dumplib.c
> /usr/bin/cc -o ncdump -g  ncdump.o vardata.o dumplib.o -L../libsrc -lnetcdf  
> make[2]: Leaving directory `/home/gc/netcdf-linux/netcdf-3.4/src/ncdump'
> 
> Returning to directory /home/gc/netcdf-linux/netcdf-3.4/src
> 
> make[1]: Leaving directory `/home/gc/netcdf-linux/netcdf-3.4/src'
> make[1]: Entering directory `/home/gc/netcdf-linux/netcdf-3.4/src'
> 
> Making `all' in directory /home/gc/netcdf-linux/netcdf-3.4/src/ncgen
> 
> make[2]: Entering directory `/home/gc/netcdf-linux/netcdf-3.4/src/ncgen'
> /usr/bin/cc -c -g -I../libsrc -I.  -Df2cFortran main.c
> /usr/bin/cc -c -g -I../libsrc -I.  -Df2cFortran load.c
> /usr/bin/cc -c -g -I../libsrc -I.  -Df2cFortran ncgentab.c
> /usr/bin/cc -c -g -I../libsrc -I.  -Df2cFortran escapes.c
> /usr/bin/cc -c -g -I../libsrc -I.  -Df2cFortran getfill.c
> /usr/bin/cc -c -g -I../libsrc -I.  -Df2cFortran init.c
> /usr/bin/cc -c -g -I../libsrc -I.  -Df2cFortran genlib.c
> /usr/bin/cc -o ncgen -g  main.o load.o ncgentab.o escapes.o getfill.o init.o 
> genlib.o ../libsrc/libnetcdf.a  
> make[2]: Leaving directory `/home/gc/netcdf-linux/netcdf-3.4/src/ncgen'
> 
> Returning to directory /home/gc/netcdf-linux/netcdf-3.4/src
> 
> make[1]: Leaving directory `/home/gc/netcdf-linux/netcdf-3.4/src'
> make[1]: Entering directory `/home/gc/netcdf-linux/netcdf-3.4/src'
> 
> Making `all' in directory /home/gc/netcdf-linux/netcdf-3.4/src/cxx
> 
> make[2]: Entering directory `/home/gc/netcdf-linux/netcdf-3.4/src/cxx'
> /usr/bin/c++ -c -g  -I../libsrc  -Df2cFortran netcdf.cc
> /usr/bin/c++ -c -g  -I../libsrc  -Df2cFortran ncvalues.cc
> ar cru         libnetcdf_c++.a netcdf.o ncvalues.o
> ranlib libnetcdf_c++.a
> /usr/bin/c++ -c -g  -I../libsrc  -Df2cFortran nctst.cc
> /usr/bin/c++ -o nctst -I../libsrc  -Df2cFortran -g   nctst.o libnetcdf_c++.a 
> -L../libsrc -lnetcdf 
> make[2]: Leaving directory `/home/gc/netcdf-linux/netcdf-3.4/src/cxx'
> 
> Returning to directory /home/gc/netcdf-linux/netcdf-3.4/src
> 
> make[1]: Leaving directory `/home/gc/netcdf-linux/netcdf-3.4/src'

I don't see any problems with the above "make".

> --------------EE087DDB1E868AEB2B364597
> Content-Type: text/plain; charset=us-ascii;
>  name="test.log"
> Content-Transfer-Encoding: 7bit
> Content-Disposition: inline;
>  filename="test.log"
> 
> make[1]: Entering directory `/home/gc/netcdf-linux/netcdf-3.4/src'
> 
> Making `test' in directory /home/gc/netcdf-linux/netcdf-3.4/src/libsrc
> 
> make[2]: Entering directory `/home/gc/netcdf-linux/netcdf-3.4/src/libsrc'
> /usr/bin/cc -c -g -I.  -Df2cFortran t_nc.c
> ar cru         libnetcdf.a attr.o dim.o error.o libvers.o nc.o ncio.o ncx.o 
> putget.o string.o v1hpg.o v2i.o var.o
> ranlib libnetcdf.a
> /usr/bin/cc -o t_nc -g  t_nc.o -L. -lnetcdf 
> ./t_nc
> make[2]: *** [test] Segmentation fault (core dumped)
> make[2]: Leaving directory `/home/gc/netcdf-linux/netcdf-3.4/src/libsrc'
> make[1]: *** [subdir_target] Error 1
> make[1]: Leaving directory `/home/gc/netcdf-linux/netcdf-3.4/src'
> make: *** [libsrc/test] Error 2

Bizarre!  Judging from the output that preceded the "make test" I'd say
it should have worked.

Since you built the netCDF package using the "-g" option, would you mind
executing the libsrc/t.nc program in a debugger to discover where the
problem lies:

    1.  Drop into the libsrc/ subdirectory.

    2.  Remove the file "test.nc" if it exists.

    3.  Execute the program ./t_nc in a debugger and tell me where it
        fails.

...

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