This archive contains answers to questions sent to Unidata support through mid-2025. Note that the archive is no longer being updated. We provide the archive for reference; many of the answers presented here remain technically correct, even if somewhat outdated. For the most up-to-date information on the use of NSF Unidata software and data services, please consult the Software Documentation first.
Hello Dyah, What version of hdf5 are you using on your system? I suspect that the issue is either a very old version of libhdf5, or potentially a version that is too new to work with the version of netCDF you have. NetCDF 4.1.3 is quite old, and currently unsupported. You may be better served trying to install the latest release, available from https://github.com/Unidata/netcdf-c/releases. If you can confirm to me what version of hdf5 you are using, I can help you decide if the issue requires updating your netCDF version. Thank you, I hope this helps, -Ward > Dear Sir/Madam, > > I tried to install netcdf with hdf5. > I followed step by step that is written on this website: > > https://www.unidata.ucar.edu/software/netcdf/netcdf-4/newdocs/netcdf-install/Quick-Instructions.html > > I got error when I did make. Which shows as follow: > > nc4file.c: In function 'nc4_create_file': > nc4file.c:272: error: 'H5F_LIBVER_18' undeclared (first use in this function) > nc4file.c:272: error: (Each undeclared identifier is reported only once > nc4file.c:272: error: for each function it appears in.) > make[2]: *** [libnetcdf4_la-nc4file.lo] Error 1 > make[2]: Leaving directory > `/workr/dyah/Build_WRF/WRF/WRFGHG/LIBRARIES/netcdf-4.1.3/libsrc4' > make[1]: *** [all-recursive] Error 1 > make[1]: Leaving directory > `/workr/dyah/Build_WRF/WRF/WRFGHG/LIBRARIES/netcdf-4.1.3' > make: *** [all] Error 2 > > I am aware that there is a thread with similar problem. But I still got > the same error even after declaring CPPFLAGS, LDFLAGS and LD_LIBRARY_PATH > in the bashrc for hdf5 and zlib. > > I have also tried this command: > > CPPFLAGS="-I$DIR/hdf5/include -I$DIR/zlib/include" LDFLAGS="-L$DIR/hdf5/lib > -L$DIR/zlib/lib" ./configure --prefix=$DIR/ncdf4 --enable-netcdf4 > --enable-large-file-tests > > But it doesn't work, the error message is still the same. > > Do you have any suggestion? > > Best regards, > Dyah? > > > Dear Sir/Madam, > > I tried to install netcdf with hdf5. > I followed step by step that is written on this website: > > https://www.unidata.ucar.edu/software/netcdf/netcdf-4/newdocs/netcdf-install/Quick-Instructions.html > > I got error when I did make. Which shows as follow: > > nc4file.c: In function 'nc4_create_file': > nc4file.c:272: error: 'H5F_LIBVER_18' undeclared (first use in this function) > nc4file.c:272: error: (Each undeclared identifier is reported only once > nc4file.c:272: error: for each function it appears in.) > make[2]: *** [libnetcdf4_la-nc4file.lo] Error 1 > make[2]: Leaving directory > `/workr/dyah/Build_WRF/WRF/WRFGHG/LIBRARIES/netcdf-4.1.3/libsrc4' > make[1]: *** [all-recursive] Error 1 > make[1]: Leaving directory > `/workr/dyah/Build_WRF/WRF/WRFGHG/LIBRARIES/netcdf-4.1.3' > make: *** [all] Error 2 > > I am aware that there is a thread with similar problem. But I still got > the same error even after declaring CPPFLAGS, LDFLAGS and LD_LIBRARY_PATH > in the bashrc for hdf5 and zlib. > > I have also tried this command: > > CPPFLAGS="-I$DIR/hdf5/include -I$DIR/zlib/include" LDFLAGS="-L$DIR/hdf5/lib > -L$DIR/zlib/lib" ./configure --prefix=$DIR/ncdf4 --enable-netcdf4 > --enable-large-file-tests > > But it doesn't work, the error message is still the same. > > Do you have any suggestion? > > Best regards, > Dyah? > > Ticket Details =================== Ticket ID: GCQ-189816 Department: Support netCDF Priority: Normal Status: Closed =================== 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.