This archive contains answers to questions sent to Unidata support through mid-2025. Note that the archive is no longer being updated. We provide the archive for reference; many of the answers presented here remain technically correct, even if somewhat outdated. For the most up-to-date information on the use of NSF Unidata software and data services, please consult the Software Documentation first.
Steve, >Date: 2 Jun 1997 09:19:34 -0500 >From: "Steve Mauget" <address@hidden> >Organization: USDA >To: "Steve Emmerson" <address@hidden> >Subject: Re: 970530: compiling .F fil >Keywords: 199706021417.IAA27579 In the above message, you wrote: > Steve : > > In connection with our v. 3.3 installation problem on our > SGI, below are the output of: > > I. uname -a > II. env > IIIa. Standard output and error for "configure --prefix=/usr/local" > IIIb. Config.log > IV. The standard output and error for the "make" of src/nf_test > > Thanks for the help, > > Steve M. > > ###################################################################### > I. IRIX lbk155 6.2 03131015 IP22 > ###################################################################### > II. > _=/usr/sbin/xwsh > LANG= > PATH=.:/usr/sbin:/usr/bsd:/sbin:/usr/bin:/bin:/usr/bin/X11:/usr/local/bin:/usr/local/lib/f90:/usr/local/lib/grads:/usr/local/lib/grads/xample:/usr/etc:/usr/lib:/lib:/usr/local/lib/groff > NOMSGLABEL=1 > XUSERFILESEARCHPATH=/usr/people/mauget/.desktop-lbk155/%N:/usr/people/mauget/%N:/usr/people/mauget/%L/%N%C:/usr/people/mauget/%l/%N%C:/usr/people/mauget/%N%C:/usr/people/mauget/%L/%N:/usr/people/mauget/%l/%N > LOGNAME=mauget > MAIL=/usr/mail/mauget > USER=mauget > MSGVERB=text:action > LASTLOGIN=Last login: Sat May 31 10:05:16 CDT 1997 on :0 > DISPLAY=:0.0 > SHELL=/bin/csh > HOME=/usr/people/mauget > TERM=iris-ansi > PWD=/temp/netcdf-3.3/src > TZ=CST6CDT > NOMSGSEVERITY=1 > WINDOWID=71303172 > PS1=# > CC=/bin/c89 > FC=/usr/local/bin/f90 > FFLAGS=-g > CXX= > CPPFLAGS= > CFLAGS=-g The above looks OK. > ###################################################################### > IIIa. > creating cache ./config.cache > checking for m4... m4 > checking user-defined C compiler "/bin/c89" > checking C compiler... works > checking for how to make dependencies... cc -M > configure: warning: Empty CXX variable > configure: warning: The C++ interface will not be built > checking user-defined FORTRAN compiler "/usr/local/bin/f90"... works > checking for math library > checking for -lc... no > checking for -lm... yes > checking FORTRAN-type equivalent to netCDF "byte"... integer*1 > checking FORTRAN-type equivalent to C "signed char"... integer*1 > checking FORTRAN fill-value for netCDF version 2 byte... -127 > checking FORTRAN-type equivalent to netCDF "short"... integer*2 > checking FORTRAN-type equivalent to C "short"... integer*2 > checking FORTRAN-type equivalent to netCDF "long"... integer*4 > checking FORTRAN-type equivalent to C "int"... integer > checking FORTRAN-type equivalent to netCDF "float"... real*4 > checking FORTRAN-type equivalent to C "float"... real*4 > checking FORTRAN-type equivalent to netCDF "double"... real*8 > checking FORTRAN-type equivalent to C "double"... real*8 > checking for ar... ar > checking for ranlib... : > checking how to run the C preprocessor... /bin/c89 -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... 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... yes > 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 > checking for command to create manual-page index... > checking binary distribution directory... /home/ftp/pub/binary/dummy_system > updating cache ./config.cache > creating ./config.status > creating macros.make > creating libsrc/ncconfig.h > creating fortran/netcdf-cpp.inc The above looks OK. > > ###################################################################### > IIIb. > > This file contains any messages produced by compilers while > running configure, to aid debugging if configure makes a mistake. > > configure:989: /bin/c89 -c -g conftest.c 1>&5 > configure:1224: /usr/local/bin/f90 -c -g conftest.f > Extension: conftest.f, line 1: TAB format input > Extension: conftest.f, line 2: TAB format input > [f90 continuing despite warning messages] > configure:1313: /usr/local/bin/f90 -c -g conftest.F > File with unknown suffix .F passed to ld Hmm... I wonder if the last command above exited with status 0 (i.e. success). If it did, then the configure script would think that the FORTRAN compiler correctly handles *.F files. To see if this is the case, would you please execute the following commands in a Standard shell: touch tmp.F /usr/local/bin/f90 -c tmp.F echo $? If the above succeeds (exit status 0), then would you please see if the following command fails: /usr/local/bin/f90 -o tmp tmp.F If the above command fails, then the configure script should use it to determine whether or not the FORTRAN compiler correctly handles *.F files. Try making the following modifications to the configure script: 1. Locate the first occurance of the symbol COMPILE_F in the configure script. 2. Change the subsequent assignment (15 lines later) doit='$FC -c ${FFLAGS-} conftest.F' to doit='$FC -o conftest ${FFLAGS-} conftest.F' Then re-execute the configure script. To verify that the configure now believes that the FORTRAN compiler doesn't handle *.F files, look at the definition for the macro COMPILE.F in the file macros.make. It should be the empty string. This should cause the makefiles to use a more complicated rule (involving the C preprocessor) to compile *.F files. Please let me know if this helps. Since we're trying to transition to netCDF-3 from netCDF-2, would you please try this solution before working on netCDF-2? Thanks. -------- Steve Emmerson <address@hidden>