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

[netCDF #WBE-329560]: Trouble compiling netcdf



Daniel,

> I rebuild zlib, hdf5 and netcdf from scratch using some flags provided by
> my coworkers.  I'm using gnu compilers including gfortran on a 64 bit
> Ubuntu 12.04 Virtual Machine with 8GB of RAM running on top of an Early
> 2011 Mac Book Pro with 16 GB of RAM.  It's working now.

It's great to hear you got everything built and installed on your OSX laptop.
Thanks for providing the details of what worked.

--Russ

> HDF5 libraries
> 
> export FC=gfortran
> ./configure --with-zlib=$HOME/zlib  --prefix=$HOME/hdf5 --enable-fortran
> --enable-fortran2003
> make
> make check install
> 
> NetCDF C Libraries
> 
> export CPPFLAGS='-I'$HOME'/hdf5/include -I'$HOME'/zlib/include'
> export LDFLAGS='-L'$HOME'/hdf5/lib -L'$HOME'/zlib/lib'
> export LD_LIBRARY_PATH=$HOME/hdf5/lib:$HOME/zlib/lib
> export CFLAGS=-g
> ./configure --enable-netcdf-4 --prefix=$HOME/netcdf_gfortran
> make -j4
> make check install
> 
> NetCDF Fortran Libraries
> 
> export CPPFLAGS='-I'$HOME'/hdf5/include -I'$HOME'/zlib/include
> -I'$HOME'/netcdf_gfortran/include'
> export LDFLAGS='-L'$HOME'/hdf5/lib -L'$HOME'/zlib/lib
> -L'$HOME'/netcdf_gfortran/lib'
> export
> LD_LIBRARY_PATH=$HOME/hdf5/lib:$HOME/zlib/lib:$HOME/netcdf_gfortran/lib
> 
> autoreconf -i -f
> 
> ./configure --prefix=$HOME/netcdf_gfortran 2>&1 | tee configure.gfortran.out
> make -j4
> make check install
> 
> address@hidden> wrote:
> 
> > Hi Daniel,
> >
> > Please make sure you were not running "make check" as root, because in
> > that case the LD_LIBRARY_PATH (or DYLD_LIBRARY_PATH for OSX) would not be
> > inherited by a subshell, so would not be used to search for installed
> > libraries.
> >
> > If that's not the problem, please provide the config.log generated when
> > you ran the netCDF-C configure script and also the output from "make
> > check".
> >
> > Thanks,
> > --Russ
> >
> > > I am trying to compile and install netcdf with hd5 support to be used
> > with
> > > ESMF but I'm getting the following error log.  The issue seems to be that
> > > it can't find the libhdf5 shared library but I've linked the libraries in
> > > (see excerpt from config compiling options).  I've tried installing zlib
> > > and hd5 to both /usr/local and /home/dan15lw/local and the files are
> > > there.  I've also tried adding /usr/local/lib to the environment path.
> > > What am I doing wrong?  I've followed the instructions to a t several
> > times.
> > >
> > > # Compiling Options
> > > -----------------
> > > C Compiler: /usr/bin/gcc
> > > CFLAGS: -g -O2
> > > CPPFLAGS: -I/home/dan15lw/local/include
> > > LDFLAGS: -L/home/dan15lw/local/lib
> > >
> > >
> > >
> > > ==============================================
> > > netCDF 4.3.3-rc2: h5_test/test-suite.log
> > > ==============================================
> > >
> > > # TOTAL: 26
> > > # PASS:  2
> > > # SKIP:  0
> > > # XFAIL: 0
> > > # FAIL:  24
> > > # XPASS: 0
> > > # ERROR: 0
> > >
> > > .. contents:: :depth: 2
> > >
> > > FAIL: tst_h_files
> > > =================
> > >
> > > ./tst_h_files: error while loading shared libraries: libhdf5.so.8: cannot
> > > open shared object file: No such file or directory
> > >
> > > FAIL: tst_h_files2
> > > ==================
> > >
> > > ./tst_h_files2: error while loading shared libraries: libhdf5.so.8:
> > cannot
> > > open shared object file: No such file or directory
> > >
> > > FAIL: tst_h_files4
> > > ==================
> > >
> > > ./tst_h_files4: error while loading shared libraries: libhdf5.so.8:
> > cannot
> > > open shared object file: No such file or directory
> > >
> > > FAIL: tst_h_atts
> > > ================
> > >
> > > ./tst_h_atts: error while loading shared libraries: libhdf5_hl.so.8:
> > cannot
> > > open shared object file: No such file or directory
> > >
> > > FAIL: tst_h_vars
> > > ================
> > >
> > > ./tst_h_vars: error while loading shared libraries: libhdf5.so.8: cannot
> > > open shared object file: No such file or directory
> > >
> > > FAIL: tst_h_vars2
> > > =================
> > >
> > > ./tst_h_vars2: error while loading shared libraries: libhdf5_hl.so.8:
> > > cannot open shared object file: No such file or directory
> > >
> > > FAIL: tst_h_vars3
> > > =================
> > >
> > > ./tst_h_vars3: error while loading shared libraries: libhdf5.so.8: cannot
> > > open shared object file: No such file or directory
> > >
> > > FAIL: tst_h_grps
> > > ================
> > >
> > > ./tst_h_grps: error while loading shared libraries: libhdf5.so.8: cannot
> > > open shared object file: No such file or directory
> > >
> > > FAIL: tst_h_compounds
> > > =====================
> > >
> > > ./tst_h_compounds: error while loading shared libraries: libhdf5.so.8:
> > > cannot open shared object file: No such file or directory
> > >
> > > FAIL: tst_h_compounds2
> > > ======================
> > >
> > > ./tst_h_compounds2: error while loading shared libraries: libhdf5.so.8:
> > > cannot open shared object file: No such file or directory
> > >
> > > FAIL: tst_h_wrt_cmp
> > > ===================
> > >
> > > ./tst_h_wrt_cmp: error while loading shared libraries: libhdf5.so.8:
> > cannot
> > > open shared object file: No such file or directory
> > >
> > > FAIL: tst_h_rd_cmp
> > > ==================
> > >
> > > ./tst_h_rd_cmp: error while loading shared libraries: libhdf5.so.8:
> > cannot
> > > open shared object file: No such file or directory
> > >
> > > FAIL: tst_h_vl
> > > ==============
> > >
> > > ./tst_h_vl: error while loading shared libraries: libhdf5.so.8: cannot
> > open
> > > shared object file: No such file or directory
> > >
> > > FAIL: tst_h_opaques
> > > ===================
> > >
> > > ./tst_h_opaques: error while loading shared libraries: libhdf5.so.8:
> > cannot
> > > open shared object file: No such file or directory
> > >
> > > FAIL: tst_h_strings
> > > ===================
> > >
> > > ./tst_h_strings: error while loading shared libraries: libhdf5.so.8:
> > cannot
> > > open shared object file: No such file or directory
> > >
> > > FAIL: tst_h_strings1
> > > ====================
> > >
> > > ./tst_h_strings1: error while loading shared libraries: libhdf5.so.8:
> > > cannot open shared object file: No such file or directory
> > >
> > > FAIL: tst_h_strings2
> > > ====================
> > >
> > > ./tst_h_strings2: error while loading shared libraries: libhdf5.so.8:
> > > cannot open shared object file: No such file or directory
> > >
> > > FAIL: tst_h_ints
> > > ================
> > >
> > > ./tst_h_ints: error while loading shared libraries: libhdf5.so.8: cannot
> > > open shared object file: No such file or directory
> > >
> > > FAIL: tst_h_dimscales
> > > =====================
> > >
> > > ./tst_h_dimscales: error while loading shared libraries: libhdf5_hl.so.8:
> > > cannot open shared object file: No such file or directory
> > >
> > > FAIL: tst_h_dimscales1
> > > ======================
> > >
> > > ./tst_h_dimscales1: error while loading shared libraries:
> > libhdf5_hl.so.8:
> > > cannot open shared object file: No such file or directory
> > >
> > > FAIL: tst_h_dimscales2
> > > ======================
> > >
> > > ./tst_h_dimscales2: error while loading shared libraries:
> > libhdf5_hl.so.8:
> > > cannot open shared object file: No such file or directory
> > >
> > > FAIL: tst_h_dimscales3
> > > ======================
> > >
> > > ./tst_h_dimscales3: error while loading shared libraries:
> > libhdf5_hl.so.8:
> > > cannot open shared object file: No such file or directory
> > >
> > > FAIL: tst_h_enums
> > > =================
> > >
> > > ./tst_h_enums: error while loading shared libraries: libhdf5.so.8: cannot
> > > open shared object file: No such file or directory
> > >
> > > FAIL: tst_h_dimscales4
> > > ======================
> > >
> > > ./tst_h_dimscales4: error while loading shared libraries:
> > libhdf5_hl.so.8:
> > > cannot open shared object file: No such file or directory
> > >
> > >
> >
> > Russ Rew                                         UCAR Unidata Program
> > address@hidden                      http://www.unidata.ucar.edu
> >
> >
> >
> > Ticket Details
> > ===================
> > Ticket ID: WBE-329560
> > Department: Support netCDF
> > Priority: Normal
> > Status: Closed
> >
> >
> 
> 

Russ Rew                                         UCAR Unidata Program
address@hidden                      http://www.unidata.ucar.edu



Ticket Details
===================
Ticket ID: WBE-329560
Department: Support netCDF
Priority: Normal
Status: Closed