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

20020611: netCDF make fails when using Portland Group Fortran



>From: "Pablo Santos" <address@hidden>
>Organization: NOAA
>Keywords: 200206111928.g5BJSlJ15684 netCDF Portland Group Fortran CPPFLAGS

Pablo,

>Following procedure in INSTALL file here is a report of a problem I am
>having. Any help will be greatly appreciated. I can not make it passed
>the make step. My fortran compiler is the portland group compiler and it
>works fine with other programs.

When using the Portland Group Fortran compilers, you should define
the CPPFLAGS environment variable before running configure.  An
example of doing this is listed in:

http://www.unidata.ucar.edu/packages/netcdf/INSTALL.html

under the Linux section.  Here is a snippit from that section:

   CPPFLAGS='-DNDEBUG -DpgiFortran'
   CFLAGS=-O
   FFLAGS='-O -w'

After defining these, you should do the following:

make distclean
./configure
make

Please let us know if this doesn't get you by the problem you are having.

>output from uname -a: 
>Linux wfosoo 2.4.7-10 #1 Thu Sep 6 17:27:27 EDT 2001 i686 unknown
>
>Content of VERSION: 
>3.5.0
>
>Paths to compilers used:
>C: /usr/bin/gcc
>C++:/usr/bin/c++
>F77: /usr/pgi/linux86/bin/pgf77
>F90: /usr/pgi/linux86/bin/pgf90
>
>configure.log:
>
>creating cache ./config.cache
>checking for top-level source-directory
>/usr/local/src/netcdf-3.5.0/src
>checking for m4 preprocessor
>checking for m4... m4
>checking m4 flags... -B10000
>checking for xlc... no
>checking for c89... no
>checking for acc... no
>checking for cc... cc
>checking C compiler "cc"... works
>checking how to make dependencies... false
>checking for CC... no
>checking for cxx... no
>checking for c++... c++
>checking C++ compiler "c++"... works
>checking how to run the C preprocessor... cc -E
>checking user-defined Fortran-77 compiler
>"/usr/pgi/linux86/bin/pgf77"... works
>checking for Fortran .F compiler... 
>checking if Fortran-77 compiler handles *.F files... yes
>checking user-defined Fortran-90 compiler
>"/usr/pgi/linux86/bin/pgf90"... works
>checking for nm utility
>checking for nm... nm
>checking nm flags... 
>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 tanh in -lc... no
>checking for tanh in -lm... yes
>checking for ar utility
>checking for ar... ar
>checking ar flags... cru
>checking for nm utility
>checking for nm... (cached) nm
>checking nm flags... 
>checking for ranlib... ranlib
>checking for stdlib.h... yes
>checking for sys/types.h... yes
>checking for strerror... yes
>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
>
>make.log:
>
>make[1]: Entering directory `/usr/local/src/netcdf-3.5.0/src'
>
>Making `all' in directory /usr/local/src/netcdf-3.5.0/src/libsrc
>
>make[2]: Entering directory `/usr/local/src/netcdf-3.5.0/src/libsrc'
>cc -c -O -I.  -DNDEBUG attr.c
>cc -c -O -I.  -DNDEBUG dim.c
>cc -c -O -I.  -DNDEBUG error.c
>cc -c -O -I.  -DNDEBUG -DVERSION=`cat ../VERSION` libvers.c
>cc -c -O -I.  -DNDEBUG nc.c
>cc -c -O -I.  -DNDEBUG ncio.c
>cc -c -O -I.  -DNDEBUG ncx.c
>cc -c -O -I.  -DNDEBUG putget.c
>cc -c -O -I.  -DNDEBUG string.c
>cc -c -O -I.  -DNDEBUG v1hpg.c
>cc -c -O -I.  -DNDEBUG v2i.c
>cc -c -O -I.  -DNDEBUG 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 `/usr/local/src/netcdf-3.5.0/src/libsrc'
>
>Returning to directory /usr/local/src/netcdf-3.5.0/src
>
>make[1]: Leaving directory `/usr/local/src/netcdf-3.5.0/src'
>make[1]: Entering directory `/usr/local/src/netcdf-3.5.0/src'
>
>Making `all' in directory /usr/local/src/netcdf-3.5.0/src/fortran
>
>make[2]: Entering directory `/usr/local/src/netcdf-3.5.0/src/fortran'
>cc -c -O -I../libsrc  -DNDEBUG fort-attio.c
>In file included from ncfortran.h:13,
>                 from fort-attio.c:6:
>cfortran.h:134:3: #error "cfortran.h:  Can't find your environment
>among:    - MIPS cc and f77 2.0. (e.g. Silicon Graphics, DECstations,
>...)         - IBM AIX XL C and FORTRAN Compiler/6000 Version
>01.01.0000.0000         - VAX   VMS CC 3.1 and FORTRAN 5.4.            
>                         - Alpha VMS DEC C 1.3 and DEC FORTRAN 6.0.    
>                          - Alpha OSF DEC C and DEC Fortran for OSF/1
>AXP Version 1.2              - Apollo DomainOS 10.2 (sys5.3) with f77
>10.7 and cc 6.7.                - CRAY                                 
>                                 - NEC SX-4 SUPER-UX                   
>                                  - CONVEX                             
>                                   - Sun                               
>                                    - PowerStation Fortran with Visual
>C++                                   - HP9000s300/s700/s800 Latest test
>with: HP-UX A.08.07 A 9000/730        - LynxOS: cc or gcc with f2c.    
>                                       - VAXUltrix: vcc,cc or gcc with
>f2c. gcc or cc with f77.                 -            f77 with vcc
>works; but missing link magic for f77 I/O.     -            NO fort.
>None of gcc, cc or vcc generate required names.    - f2c    : Use
>#define    f2cFortran, or cc -Df2cFortran                 - NAG f90: Use
>#define NAGf90Fortran, or cc -DNAGf90Fortran              - Absoft UNIX
>F77: Use #define AbsoftUNIXFortran or cc -DAbsoftUNIXFortran     -
>Absoft Pro Fortran: Use #define AbsoftProFortran     - Portland Group
>Fortran: Use #define pgiFortran"
>make[2]: *** [fort-attio.o] Error 1
>make[2]: Leaving directory `/usr/local/src/netcdf-3.5.0/src/fortran'
>make[1]: *** [subdir_target] Error 1
>make[1]: Leaving directory `/usr/local/src/netcdf-3.5.0/src'
>make: *** [fortran/all] Error 2
>
>Any help will be greatly apprecited. Thanks.
>
>Pablo Santos
>Science and Operations Officer
>11691 SW 17th Street
>Miami, FL 33165
>305-229-4521 ext 521
>address@hidden
>address@hidden

Tom Yoksas