Yuanchong, >Date: Wed, 6 Apr 2005 15:51:38 -0400 (EDT) >From: Yuanchong Zhang <address@hidden> >Organization: Columbia University/NASA GISS >To: address@hidden (Steve Emmerson) >Subject: Re: 20050405: problem using UDUNITS with Fortran code > Keywords: 200504051922.j35JM9v2005883 The above message contained the following: > The following are > (1) Fortran compiling error message (the fortran program 11.f is successful > on SGI machine, on which somebody intalled UDUNITS at /usr/...) > (2) udunits.inc file > > Please help diagnose what problem really is. Thank you > > Yuanchong > --------------------(1) ---------------------------------------- > > Script command is started on Wed Apr 6 15:42:04 EDT address@hidden: > /d1b/rad> ff.nc11 11.f > xlf -O3 11.f astsub.o -qextname -L/usr/local/netcdf-3.4/lib -lnetcdf > -L/d1b/rad/ncep/Ying/udunits-1.11.7/lib -ludunits > "/d1b/rad/ncep/udunits-1.11.7/include/udunits.inc", line 27.7: 1515-022 (S) > Syntax Error: Extra token " fptrfineptrinteger " was found. The token is > ignored. It looks like the Fortran compiler is not correctly preprocessing the "udunits.inc" file with the C preprocessor. It looks like it failed on the "#define" in that file. Your options are 1. Remove the "#include <udunits.inc>" from the source file, 11.f. If you do this, then you will have to declare all the UDUNITS functions yourself in the file "11.f". 2. See if there's an option to the xlf(1) compiler that will ensure that it uses the C preprocessor; or 3. Try renaming the input file, 11.f, to "11.F". Sometimes a capital "F" extension gets different behavior from the preprocessor. Regards, Steve Emmerson
NOTE: All email exchanges with Unidata User Support are recorded in the Unidata inquiry tracking system and then made publicly available through the web. If you do not want to have your interactions made available in this way, you must let us know in each email you send to us.