[gdal-dev] netcdf option build error

Jeshua Lacock jeshua at OpenOSX.com
Tue Apr 29 13:31:21 EDT 2008


On Apr 29, 2008, at 9:44 AM, Jeshua Lacock wrote:

> That seems to help some, as now I only get one error:
>
> GDapi.c: In function 'GDsdid':
> GDapi.c:10873: error: 'MAX_VAR_DIMS' undeclared (first use in this  
> function)
> GDapi.c:10873: error: (Each undeclared identifier is reported only  
> once
> GDapi.c:10873: error: for each function it appears in.)
> GDapi.c:10873: warning: unused variable 'dims'
> make[4]: *** [../../o/GDapi.o] Error 1
> make[3]: *** [lib-hdfeos] Error 2
> make[2]: *** [hdf4-install-obj] Error 2
> make[1]: *** [frmts-target] Error 2
> make: *** [gdal] Error 2

Note that I removed my entire HDF4 installation, followed the  
instructions at http://trac.osgeo.org/gdal/wiki/HDF, disabled the  
netcdf option for HDF4 and reinstalled HDF4, did a make clean in gdal,  
and I am still stuck. Cleary it must be using the wrong netcdf.h file,  
and if I manually #include netcdf.h with the full path in the source  
file it is ignored (so it must be parsed somewhere else).

If I manually define MAX_VAR_DIMS it compiles GDapi.c, then gets stuck  
on hdf4dataset.cpp.

If I manually define MAX_NC_NAME and MAX_VAR_DIMS, I get this error:

hdf4dataset.cpp: In static member function 'static GDALDataset*  
HDF4Dataset::Open(GDALOpenInfo*)':
hdf4dataset.cpp:744: error: cannot convert 'hdf_vartype_t' to  
'HDF4SubdatasetType' in assignment

I would really like to have netcdf and HDF capabilities. I suspect  
that it is a simple #include problem, but I cannot figure it out.

Any further tips would really be great.


Thanks,

Jeshua Lacock, Owner
<http://OpenOSX.com>
phone: 877.240.1364



More information about the gdal-dev mailing list