gradshdf disabled problem in fc4
Patrice Dumas
pertusus at FREE.FR
Tue Mar 14 08:26:26 EST 2006
On Tue, Mar 14, 2006 at 09:02:50PM +0800, WD ZH wrote:
> Hi Pat,
>
> Now I have realized hdf4 might be all the problem.
>
> I noticed the "-DHAVE_NETCDF" issue, it has bothered me a lot.
>
> The INSTALL file of HDF4.2R1 is not very clear for me, and I do not know where shoud I put the "-DHAVE_NETCDF" in.
In CFLAGS.
But you don't need to set it...
> I have tried many times...for LDFLAGS, I have make install error saying undefined reference to 'sd_ncxxx'
With grads or hdf? You should try make before make install.
If you have compiled HDF4 with -DHAVE_NETCDF you'll have the ncxxx
symbols renamed sd_ncxxx.
> For other flags, I could have install passed, but there seems no "rename the HDF version of the C-interface(ncxxx) of the netCDF API to sd_ncxxx " as INSTALL said.
> And every time the HDF-SD C interfaces tests failed in make check whether the make install passed or not.
Maybe you could try the attached patch that comes from the hdf rpm
(you may need -lm for some math library functions).
> For GrADS, the "checking for netcdf 3 interface" became "yes" when I disabled gradshdf.
Strange...
> The problem now is somewhat not referring to GrADS, I have wrote NCSA HDF Helpdesk a email, but no reply yet.
It is certainly not within the grads or hdf code themselves, these are
certainly link/install issues, but may well be within the autoconf macros
I produced...
--
Pat
-------------- next part --------------
--- HDF4.2r1/configure.ac.orig 2005-07-15 14:52:14.000000000 -0600
+++ HDF4.2r1/configure.ac 2005-07-15 14:53:35.000000000 -0600
@@ -528,7 +528,7 @@
dnl ======================================================================
AC_MSG_CHECKING([for math library support])
-AC_TRY_LINK([#include <math.h>], [sqrt(37.927)],
+AC_TRY_LINK([#include <math.h>], [sinh(37.927)],
[AC_MSG_RESULT([yes])],
[AC_MSG_RESULT([no]); LIBS="$LIBS -lm"])
--- HDF4.2r1/mfhdf/fortran/config/ftest-linux.f.orig 2005-02-08 20:04:07.000000000 -0700
+++ HDF4.2r1/mfhdf/fortran/config/ftest-linux.f 2005-07-15 15:37:22.000000000 -0600
@@ -138,13 +138,13 @@
integer*2 shval(2)
integer i, j, k
character*31 varnam, attname(2,7), gattnam(2)
- byte bytval(2)
+ integer*1 bytval(2)
common /atts/attname, gattnam
integer*2 svalidrg(2)
real rvalidrg(2)
integer lvalidrg(2)
double precision dvalidrg(2)
- byte bvalidrg(2)
+ integer*1 bvalidrg(2)
character*31 gavalue(2), cavalue(2)
real epsilon
@@ -337,7 +337,7 @@
real flval(2)
integer lngval(2)
integer*2 shval(2)
- byte bytval(2)
+ integer*1 bytval(2)
integer vartyp, nvdims, vdims(MAXVDIMS), nvatts
character*31 varnam, attname(2,7), gattnam(2)
@@ -346,7 +346,7 @@
real rvalidrg(2)
integer lvalidrg(2)
double precision dvalidrg(2)
- byte bvalidrg(2)
+ integer*1 bvalidrg(2)
character*31 gavalue(2), cavalue(2)
real epsilon
@@ -470,7 +470,7 @@
real rvalidrg(2)
integer lvalidrg(2)
double precision dvalidrg(2)
- byte bvalidrg(2)
+ integer*1 bvalidrg(2)
c variable ids
integer bid, sid, lid, fid, did, cid, chid
@@ -883,7 +883,7 @@
integer itime, ilev, ilat, ilon
c arrays of data values to be read
- byte barray(times), byval(times)
+ integer*1 barray(times), byval(times)
integer*2 sarray(times), shval(times)
integer larray(lats)
real farray(levels, lats, lons, times)
@@ -1009,7 +1009,7 @@
integer bid, sid, lid, fid, did, cid, chid
common /vars/bid, sid, lid, fid, did, cid, chid
- byte bvalue
+ integer*1 bvalue
integer*2 svalue
integer lvalue
real fvalue
@@ -1097,7 +1097,7 @@
integer count(MAXNCDIM)
c arrays of data values to be written
- byte barray(times)
+ integer*1 barray(times)
integer*2 sarray(times)
integer larray(lats)
real farray(levels, lats, lons, times)
@@ -1184,7 +1184,7 @@
integer lvalue
integer*2 svalue
- byte bvalue
+ integer*1 bvalue
double precision onethird
integer bid, sid, lid, fid, did, cid, chid
common /vars/bid, sid, lid, fid, did, cid, chid
More information about the gradsusr
mailing list