[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
20030709: UDUNITS on UCAR's Blackforest IBM: underscore suffixes
- Subject: 20030709: UDUNITS on UCAR's Blackforest IBM: underscore suffixes
- Date: Wed, 09 Jul 2003 14:53:59 -0600
Richard,
>Date: Wed, 09 Jul 2003 16:20:10 -500
>From: Richard Anyah <address@hidden>
>Organization: North Carolina State University
>To: Steve Emmerson <address@hidden>
>Subject: Re: 20030709: UDUNITS on UCAR's Blackforest IBM
The above message contained the following:
...
making `all' in directory /home/blackforest/anyah/udunits-1.11.7/src/lib
ln -s ../port/misc/udalloc.c .
ln -s ../port/misc/udalloc.h .
c89 -c -O -I../port/misc -I../port/cfortran
-DUT_DEFAULT_PATH='"/ptmp/anyah/UNIT/etc/udunits.dat"' -D_ALL_SOURCE -Dextname
utlib.c
...
I think I see the problem and the solution. The UDUNITS package was
built with the C compiler's "-Dextname" option (recommended practice)
but the netCDF package was not. This means that the names of Fortran
routines in the UDUNITS package will end in underscores but the names of
Fortran routines in the netCDF package won't. Your program is caught
between these different conventions: whichever convention it uses, it
won't be able to find the Fortran routines in the package that used the
opposite convention.
I suggest that you try rebuilding the UDUNITS package without the
"-Dextname" option:
1. Go to the top-level source directory of the UDUNITS package.
2. Perform steps 3 through 5 described near the end of the file
INSTALL.
3. Edit the file "configure". Find the following lines:
# Ensure adherence to the trailing-underscore convention.
for arg in -Dextname; do
case "$CPPFLAGS" in
*$arg*)
;;
*)
CPPFLAGS="${CPPFLAGS-} $arg"
;;
esac
done
for arg in -qextname; do
case "$FFLAGS" in
*$arg*)
;;
*)
FFLAGS="${FFLAGS-} $arg"
;;
esac
done
and either remove them or comment them out.
4. Perform steps 6 through 9 described near the end of the file
INSTALL.
Then, recompile your program without the "-qextname" option and retry
the link step.
Please let me know if this helps.
Regards,
Steve Emmerson