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

[netCDF #SEL-204074]: NetCDF-4



Hi Carlos,

The first problem is the way you have specified the LDFLAGS environment 
variable:

  
LDFLAGS='-L/data/users/carlos/software/netCDF/installation/lib/lib/:/data/users/carlos/software/netCDF/installation/src/netcdf-cxx/lib/:/data/users/carlos/software/hdf5-1.8.13/installation/src/lib/'

Instead of specifying all your library directories as one string with ":" 
separators, 
compilers require that each library directory must be specified separately, as 
in

  LDFLAGS='-L/data/users/carlos/software/netCDF/installation/lib/lib 
-L/data/users/carlos/software/netCDF/installation/src/netcdf-cxx/lib 
-L/data/users/carlos/software/hdf5-1.8.13/installation/src/lib'

Also, if that doesn't fix the problem and you still need to define a LIBS 
envoronment
variable, the order must be changed to correspond to which libraries depend on 
other
libraries.  So instead of

  LIBS='-lhdf5 -lhdf5_hl -lnetcdf'

you would need to use 

  LIBS='-lnetcdf -lhdf5_hl -lhdf5 '

but you may not even need to specify LIBS if getting the right syntax for 
LDFLAGS is the real problem.

--Russ

> It does not work (you will see below these lines all the inputs and
> output from the terminal and the config.log file). I have exported the
> library (netcdf-c-4.3.3-rc1) and still I can't compile.
> 
> Thank you for your support,
> Carlos
> 
> $ export
> LD_LIBRARY_PATH=$/data/users/carlos/software/netCDF/installation/lib/lib:${LD_LIBRARY_PAT}
> 
> $
> CPPFLAGS="-I/data/users/carlos/software/netCDF/installation/lib/include/" 
> LDFLAGS="-L/data/users/carlos/software/netCDF/installation/lib/lib/:/data/users/carlos/software/netCDF/installation/src/netcdf-cxx/lib/:/data/users/carlos/software/hdf5-1.8.13/installation/src/lib/"
> LIBS="-lhdf5 -lhdf5_hl -lnetcdf" ./configure
> --prefix=/data/users/carlos/software/netCDF/installation/src/netcdf-fortran/
> configure: netCDF-Fortran 4.4.1
> checking build system type... x86_64-unknown-linux-gnu
> checking host system type... x86_64-unknown-linux-gnu
> checking target system type... x86_64-unknown-linux-gnu
> checking for a BSD-compatible install... /usr/bin/install -c
> checking whether build environment is sane... yes
> checking for a thread-safe mkdir -p... /bin/mkdir -p
> checking for gawk... gawk
> checking whether make sets $(MAKE)... yes
> checking whether make supports nested variables... yes
> checking whether to enable maintainer-specific portions of Makefiles... no
> configure: checking user options
> checking whether extra valgrind tests should be run... no
> checking whether parallel IO tests should be run... no
> checking whether netCDF extra tests should be run (developers only)... no
> checking for doxygen... no
> configure: WARNING: Doxygen not found - documentation will not be built
> checking for dot... dot
> configure: finding C compiler
> checking for gcc... gcc
> checking whether the C compiler works... no
> configure: error: in
> `/data/users/carlos/software/netCDF/netcdf-fortran-4.4.1':
> configure: error: C compiler cannot create executables
> See `config.log' for more details
> 
> 
> 
> 
> 
> 
Russ Rew                                         UCAR Unidata Program
address@hidden                      http://www.unidata.ucar.edu



Ticket Details
===================
Ticket ID: SEL-204074
Department: Support netCDF
Priority: Normal
Status: Closed