[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[netCDF #XXN-487077]: Installing NETCDF



It looks like HDF5 needs zlib to be compiled with the -fPIC flag (you can set 
CFLAGS="-arch x86_64 -g -O2 -fPIC", or something along those lines), so I'd 
start there. Also, what is the output of the following command:

file /home/ronnieleeper/prgfiles/zlib/lib/libz.a

Thanks!

Sean

> So initial tries to install HDF5 from source are not going well.  I have
> attempt to configure HDF5 source with the following command line argument:
> ./configure --enable-fortran --with-zlib=/home/ronnieleeper/prgfiles/zlib
> --with-szlib=/home/ronnieleeper/prgfiles/szip
> --prefix=/home/ronnieleeper/prgfiles/hdf5
> 
> The configure seems to run fine, but make errors with the following
> statement.  I am not sure where ­fPIC should be placed?
> 
> H5Ztrans.c:1406: warning: will never be executed
> CCLD   libhdf5.la
> /usr/bin/ld: /home/ronnieleeper/prgfiles/zlib/lib/libz.a(compress.o):
> relocation R_X86_64_32 against `a local symbol' can not be used when making
> a shared object; recompile with -fPIC
> /home/ronnieleeper/prgfiles/zlib/lib/libz.a: could not read symbols: Bad
> value
> collect2: ld returned 1 exit status
> make[2]: *** [libhdf5.la] Error 1
> make[2]: Leaving directory `/home/ronnieleeper/prgfiles/hdf5/hdf5-1.8.7/src'
> make[1]: *** [all] Error 2
> make[1]: Leaving directory `/home/ronnieleeper/prgfiles/hdf5/hdf5-1.8.7/src'
> make: *** [all-recursive] Error 1
> 
> In addition, here are hundreds of warning messages stating such as this one .
> H5.c:523: warning: will never be executed
> 
> However, searches from google suggest these lines indicate they are not
> issue?  In addition there were other error messages such as the following:
> 
> CC     H5make_libsettings.o
> CCLD   H5make_libsettings
> LD_LIBRARY_PATH="$LD_LIBRARY_PATH`echo  |                  \
> sed -e 's/-L/:/g' -e 's/ //g'`"
> \
> ./H5make_libsettings > H5lib_settings.c  ||
> \
> (test $HDF5_Make_Ignore && echo "*** Error ignored") ||
> \
> (rm -f H5lib_settings.c ; exit 1)
> CC     H5lib_settings.lo
> CC     H5MF.lo
> 
> Attached are the config.log and make.log files.
> 
> Any suggestions?
> 
> Ronald David Leeper
> USCRN Quality Assurance Specialist, NCDC
> Research Associate, CICS-NC
> Global Climate Applications Division
> National Climatic Data Center
> 151 Patton Ave.
> Asheville, NC 28801-5001
> address@hidden
> address@hidden
> Office: (828) 257-3185
> Fax: (828) 271-4022
> 
> 
> 
> On 8/23/11 5:37 PM, "Unidata netCDF Support"
> <address@hidden> wrote:
> 
> > Greetings,
> >
> > I wonder if there is a compatibility issue between the hdf5 RMP library 
> > (since
> > it's a binary distribution) and your compilers. Have you tried building hdf5
> > from source?
> >
> > Sean
> >
> >>  Not much luck there.  The configure crashes at the same location:
> >>  <from the command line>
> >>  checking for manual-page index command...
> >>  checking whether we should try to build netCDF-4... yes
> >>  checking for deflate in -lz... yes
> >>  checking for H5Fflush in -lhdf5... yes
> >>  checking for H5DSis_scale in -lhdf5_hl... no
> >>  configure: error: Can't find or link to the hdf5 high-level. Configure 
> >> with
> >>  --with-hdf5, or use       --disable-netcdf-4, or see config.log for 
> >> errors.
> >>
> >>  <from config.log>
> >>  configure:26872: checking for H5DSis_scale in -lhdf5_hl
> >>  configure:26897: cc -o conftest -g -O2  -I/usr/include
> >>  -I/home/ronnieleeper/prgfiles/hdf5/include -I/usr/local/szip/include
> >>  -L/usr/lib64 -L/usr/lib -L/home/ronnieleeper/prgfiles/hdf5/lib
> >>  -L/usr/local/szip/lib conftest.c -lhdf5_hl  -lhdf5 -lz  >&5
> >>  /tmp/cc6HuE8i.o: In function `main':
> >>  /home/ronnieleeper/prgfiles/netcdf/netcdf-4.1.2/conftest.c:114: undefined
> >>  reference to `H5DSis_scale'
> >>  collect2: ld returned 1 exit status
> >>  configure:26897: $? = 1
> >>  configure: failed program was:
> >>  | /* confdefs.h */
> >>  | #define PACKAGE_NAME "netCDF"
> >>  | #define PACKAGE_TARNAME "netcdf"
> >>  | #define PACKAGE_VERSION "4.1.2"
> >>  | #define PACKAGE_STRING "netCDF 4.1.2"
> >>  | #define PACKAGE_BUGREPORT "address@hidden"
> >>  | #define PACKAGE_URL ""
> >>  | #define PACKAGE "netcdf"
> >>  | #define VERSION "4.1.2"
> >>  | #define NCIO_MINBLOCKSIZE 256
> >>  | #define USE_FSYNC 1
> >>  | #define DEFAULT_CHUNK_SIZE 4194304
> >>  | #define MAX_DEFAULT_CACHE_SIZE 67108864
> >>  | #define DEFAULT_CHUNKS_IN_CACHE 10
> >>  | #define CHUNK_CACHE_SIZE 4194304
> >>  | #define CHUNK_CACHE_NELEMS 1009
> >>  | #define CHUNK_CACHE_PREEMPTION 0.75
> >>  | #define USE_DAP 1
> >>  | #define ENABLE_DAP 1
> >>  | #define ENABLE_DAP_REMOTE_TESTS 1
> >>  | #define USE_EXTREME_NUMBERS 1
> >>  | #define TEMP_LARGE "."
> >>  | #define STDC_HEADERS 1
> >>  | #define HAVE_SYS_TYPES_H 1
> >>  | #define HAVE_SYS_STAT_H 1
> >>  | #define HAVE_STDLIB_H 1
> >>  | #define HAVE_STRING_H 1
> >>  | #define HAVE_MEMORY_H 1
> >>  | #define HAVE_STRINGS_H 1
> >>  | #define HAVE_INTTYPES_H 1
> >>  | #define HAVE_STDINT_H 1
> >>  | #define HAVE_UNISTD_H 1
> >>  | #define HAVE_DLFCN_H 1
> >>  | #define LT_OBJDIR ".libs/"
> >>  | #define f2cFortran 1
> >>  | #define NF_INT1_T byte
> >>  | #define NF_INT2_T integer*2
> >>  | #define NF_INT1_IS_C_SIGNED_CHAR 1
> >>  | #define NF_INT2_IS_C_SHORT 1
> >>  | #define NF_INT_IS_C_INT 1
> >>  | #define NF_REAL_IS_C_FLOAT 1
> >>  | #define NF_DOUBLEPRECISION_IS_C_DOUBLE 1
> >>  | #define NCBYTE_T byte
> >>  | #define NCSHORT_T integer*2
> >>  | #define HAVE_LOCALE_H 1
> >>  | #define HAVE_DIRENT_H 1
> >>  | #define STDC_HEADERS 1
> >>  | #define HAVE_SYS_WAIT_H 1
> >>  | #define TIME_WITH_SYS_TIME 1
> >>  | #define HAVE_STDIO_H 1
> >>  | #define HAVE_STDARG_H 1
> >>  | #define HAVE_ERRNO_H 1
> >>  | #define HAVE_CTYPE_H 1
> >>  | #define HAVE_FCNTL_H 1
> >>  | #define HAVE_MALLOC_H 1
> >>  | #define HAVE_STDLIB_H 1
> >>  | #define HAVE_STRING_H 1
> >>  | #define HAVE_STRINGS_H 1
> >>  | #define HAVE_UNISTD_H 1
> >>  | #define HAVE_SYS_STAT_H 1
> >>  | #define HAVE_GETOPT_H 1
> >>  | #define HAVE_SYS_TIME_H 1
> >>  | #define HAVE_SYS_RESOURCE_H 1
> >>  | #define HAVE_VPRINTF 1
> >>  | #define HAVE__BOOL 1
> >>  | #define HAVE_STDBOOL_H 1
> >>  | #define HAVE_STRERROR 1
> >>  | #define HAVE_SNPRINTF 1
> >>  | #define HAVE_STRCHR 1
> >>  | #define HAVE_STRRCHR 1
> >>  | #define HAVE_MKTEMP 1
> >>  | #define HAVE_STRCAT 1
> >>  | #define HAVE_STRCPY 1
> >>  | #define HAVE_STRDUP 1
> >>  | #define HAVE_STRCASECMP 1
> >>  | #define HAVE_STRTOD 1
> >>  | #define HAVE_STRTOLL 1
> >>  | #define HAVE_GETRLIMIT 1
> >>  | #define HAVE_GETTIMEOFDAY 1
> >>  | #define HAVE_FSYNC 1
> >>  | #define HAVE_ALLOCA_H 1
> >>  | #define HAVE_ALLOCA 1
> >>  | #define HAVE_DECL_ISNAN 1
> >>  | #define HAVE_DECL_ISINF 1
> >>  | #define HAVE_DECL_ISFINITE 0
> >>  | #define HAVE_DECL_SIGNBIT 0
> >>  | #define HAVE_STRUCT_STAT_ST_BLKSIZE 1
> >>  | #define HAVE_ST_BLKSIZE 1
> >>  | #define HAVE_SSIZE_T 1
> >>  | #define HAVE_PTRDIFF_T 1
> >>  | #define SIZEOF_SHORT 2
> >>  | #define SIZEOF_INT 4
> >>  | #define SIZEOF_LONG 8
> >>  | #define SIZEOF_FLOAT 4
> >>  | #define SIZEOF_DOUBLE 8
> >>  | #define SIZEOF_OFF_T 8
> >>  | #define SIZEOF_SIZE_T 8
> >>  | #define HAVE_LIBZ 1
> >>  | #define USE_NETCDF4 1
> >>  | #define H5_USE_16_API 1
> >>  | #define HAVE_LIBHDF5 1
> >>  | /* end confdefs.h.  */
> >>  |
> >>  | /* Override any GCC internal prototype to avoid an error.
> >>  |    Use char because int might match the return type of a GCC
> >>  |    builtin and then its argument prototype would still apply.  */
> >>  | #ifdef __cplusplus
> >>  | extern "C"
> >>  | #endif
> >>  | char H5DSis_scale ();
> >>  | int
> >>  | main ()
> >>  | {
> >>  | return H5DSis_scale ();
> >>  |   ;
> >>  |   return 0;
> >>  | }
> >>  configure:26906: result: no
> >>  configure:26916: error: Can't find or link to the hdf5 high-level. 
> >> Configure
> >>  with --with-hdf5, or use       --disable-netcdf-4, or see config.log for
> >>  errors.
> >>
> >>  I have also attached the newly config.log file.
> >>
> >>  Ronald David Leeper
> >>  USCRN Quality Assurance Specialist, NCDC
> >>  Research Associate, CICS-NC
> >>  Global Climate Applications Division
> >>  National Climatic Data Center
> >>  151 Patton Ave.
> >>  Asheville, NC 28801-5001
> >>  address@hidden
> >>  address@hidden
> >>  Office: (828) 257-3185
> >>  Fax: (828) 271-4022
> >>
> >>
> >>
> >>  On 8/23/11 4:11 PM, "Unidata netCDF Support"
> >>  <address@hidden> wrote:
> >>
> >>>  > It could be. Would you mind taking that out and reconfigure / recompile
> >>> netCDF
> >>>  > to see if that works?
> >>>  >
> >>>>  >>  Yes I am.  I have it set as a bash profile variable because of 
> >>>> another
> >>>>  >>  program I am trying to install, which relies of netcdf, requires it.
> Is
> >>>>  >>  this what is causing the error?
> >>>>  >>
> >>>>  >>  Thanks
> >>>>  >>
> >>>>  >>  Ronald David Leeper
> >>>>  >>  USCRN Quality Assurance Specialist, NCDC
> >>>>  >>  Research Associate, CICS-NC
> >>>>  >>  Global Climate Applications Division
> >>>>  >>  National Climatic Data Center
> >>>>  >>  151 Patton Ave.
> >>>>  >>  Asheville, NC 28801-5001
> >>>>  >>  address@hidden
> >>>>  >>  address@hidden
> >>>>  >>  Office: (828) 257-3185
> >>>>  >>  Fax: (828) 271-4022
> >>>>  >>
> >>>>  >>
> >>>>  >>
> >>>>  >>
> >>>>  >>  On 8/23/11 3:57 PM, "Unidata netCDF Support"
> >>>>  >>  <address@hidden> wrote:
> >>>>  >>
> >>>>>>  >>>  >Thanks for passing that along. Are you setting the -Df2cFortran
> flag
> >>>>>>  >>>  >yourself in your $CFLAGS?
> >>>>>>  >>>  >
> >>>>>>>>  >>>>  >> Ok here are the results of the command: "nm
> >>>>>>>>  >>>>  >> /home/ronnieleeper/prgfiles/hdf5/lib64/libhdf5_hl.a | grep
> >>>>>>>> H5DSis" were
> >>>>>>>>  >>>>  >>
> >>>>>>>>  >>>>  >> 0000000000001110 T H5DSis_attached
> >>>>>>>>  >>>>  >> 00000000000002d0 T H5DSis_scale
> >>>>>>>>  >>>>  >>
> >>>>>>>>  >>>>  >>
> >>>>>>>>  >>>>  >> Ronald David Leeper
> >>>>>>>>  >>>>  >> USCRN Quality Assurance Specialist, NCDC
> >>>>>>>>  >>>>  >> Research Associate, CICS-NC
> >>>>>>>>  >>>>  >> Global Climate Applications Division
> >>>>>>>>  >>>>  >> National Climatic Data Center
> >>>>>>>>  >>>>  >> 151 Patton Ave.
> >>>>>>>>  >>>>  >> Asheville, NC 28801-5001
> >>>>>>>>  >>>>  >> address@hidden
> >>>>>>>>  >>>>  >> address@hidden
> >>>>>>>>  >>>>  >> Office: (828) 257-3185
> >>>>>>>>  >>>>  >> Fax: (828) 271-4022
> >>>>>>>>  >>>>  >>
> >>>>>>>>  >>>>  >>
> >>>>>>>>  >>>>  >>
> >>>>>>>>  >>>>  >>
> >>>>>>>>  >>>>  >> On 8/23/11 3:03 PM, "Unidata netCDF Support"
> >>>>>>>>  >>>>  >> <address@hidden> wrote:
> >>>>>>>>  >>>>  >>
> >>>>>>>>>>  >>>>>  >> >nm /path/to/hdf5_hl_library | grep H5DSis
> >>>>>>>>  >>>>  >>
> >>>>>>>>  >>>>  >>
> >>>>>>>>  >>>>  >>
> >>>>>>  >>>  >
> >>>>>>  >>>  >
> >>>>>>  >>>  >Ticket Details
> >>>>>>  >>>  >===================
> >>>>>>  >>>  >Ticket ID: XXN-487077
> >>>>>>  >>>  >Department: Support netCDF
> >>>>>>  >>>  >Priority: Normal
> >>>>>>  >>>  >Status: Open
> >>>>>>  >>>  >
> >>>>  >>
> >>>>  >>
> >>>>  >>
> >>>  >
> >>>  >
> >>>  > Ticket Details
> >>>  > ===================
> >>>  > Ticket ID: XXN-487077
> >>>  > Department: Support netCDF
> >>>  > Priority: Normal
> >>>  > Status: Open
> >>>  >
> >>>  >
> >>
> >>
> >>
> >>
> >
> >
> > Ticket Details
> > ===================
> > Ticket ID: XXN-487077
> > Department: Support netCDF
> > Priority: Normal
> > Status: Open
> >
> >
> 
> 
> 
> 


Ticket Details
===================
Ticket ID: XXN-487077
Department: Support netCDF
Priority: Normal
Status: Open