- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Netcdf version = 4.3.0
#./configure --prefix=/app/netcdf-4.3.0 LDFLAGS="-L/app/hdf5-1.8.1/lib
While I was trying to install netcdf with hdf5 I am getting the following error message.
Stage 1 Error: c4var.c: In function 'nc_set_var_chunk_cache_ints':
nc4var.c:127: error: 'H5D_CHUNK_CACHE_NBYTES_DEFAULT' undeclared (first use inthis function)
nc4var.c:127: error: (Each undeclared identifier is reported only once
nc4var.c:127: error: for each function it appears in.)
nc4var.c:128: error: 'H5D_CHUNK_CACHE_NSLOTS_DEFAULT' undeclared (first use in this function)
nc4var.c:129: error: '' undeclared (first use in this function)
make[2]: *** [libnetcdf4_la-nc4var.lo] Error 1
make[2]: Leaving directory `/app/setups/netcdf-4.3.0/libsrc4'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/app/setups/netcdf-4.3.0'
make: *** [all] Error 2
Add the following line in c file(/app/setups/netcdf-4.3.0/libsrc4/nc4var.c). then the undeclared problem is resolved .
#define H5D_CHUNK_CACHE_NSLOTS_DEFAULT
#define H5D_CHUNK_CACHE_W0_DEFAULT
#define H5D_CHUNK_CACHE_W0_DEFAULT
Stage 2 Error : then, I am getting the following error message.
nc4var.c: In function 'nc_set_var_chunk_cache_ints':
nc4var.c:130: error: expected expression before ';' token
nc4var.c:131: error: expected expression before ';' token
nc4var.c:132: error: expected expression before ';' token
make[2]: *** [libnetcdf4_la-nc4var.lo] Error 1
make[2]: Leaving directory `/app/setups/netcdf-4.3.0/libsrc4'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/app/setups/netcdf-4.3.0'
make: *** [all] Error 2
After reading forum they suggest to remove ; from the define variable.
size_t real_size = H5D_CHUNK_CACHE_NBYTES_DEFAULT;
size_t real_nelems = H5D_CHUNK_CACHE_NSLOTS_DEFAULT;
float real_preemption = H5D_CHUNK_CACHE_W0_DEFAULT;
I removed. Then I am getting new error.
Stage 3 Error
nc4var.c: In function 'nc_set_var_chunk_cache_ints':
nc4var.c:131: error: expected expression before 'size_t'
nc4var.c:138: error: 'real_nelems' undeclared (first use in this function)
nc4var.c:138: error: (Each undeclared identifier is reported only once
nc4var.c:138: error: for each function it appears in.)
nc4var.c:141: error: 'real_preemption' undeclared (first use in this function)
make[2]: *** [libnetcdf4_la-nc4var.lo] Error 1
make[2]: Leaving directory `/app/setups/netcdf-4.3.0/libsrc4'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/app/setups/netcdf-4.3.0'
make: *** [all] Error 2
NOTE: Please Find attachment nc4var.c
Could you help us to resolve the problem?
Thanks & Regards,
Vijay Kumar TP
Link Copied
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Somewhat outdated instructions for netcdf:
By the way, only the Fortran compiler (if you use Fortran) need match the one you are using for your application. NetCDF built with gcc and g++ would be compatible with use of icc/icpc.
Even if your post is read by an expert in NetCDF, there are too many variables in what you may have done prior to what you have posted, so the "official Intel" instructions might be taken as a point of reference (using a newer NetCDF source of your choice).

- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page