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

[netCDF #FTZ-975139]: Help NetCDF compilation or installation



Hello Gabor,

It appears that you need to tell the GOTM build to link against zlib.  I'm
not sure how you will do this easily; since they are not using autotools, I
don't believe you can just specify LIBS on the compile line.  You may need
to edit the makefiles individually, or inquire to the GOTM folk if there is
an easy way in their system to specify dependencies to link against.

-Ward

address@hidden> wrote:

> New Client Reply: Help NetCDF compilation or installation
>
> Hi!
>
> I'm sorry to bother you, but I think I'm already done, but couldn't figure
> out the error.
>
> I installed the zlib like mentioned below; then the HDF5 and then the
> NETCDF.
>
> The error is like shown in the attachement. I haven't installed the curl,
> and neither installed the szlib, although i tried with szlib where the
> LIBS='-lnetcdf -lhdf5_hl -lhdf5 -lz' did not work. Any suggestions?
>
> Best regards, and thanks,
> Gabor
>
>
>
>  On Sa, 20.09.2014, 15:09, Unidata netCDF Support wrote:
> > HI Gabor,
> >
> >> I think I'm almost done, as I installed NetCDF and hdf5 into the
> >> usr/local
> >> the building of GOTM also got one step further, but now I get an error
> >> for
> >> something with the libhdf5.a and the libhdf5_hl.a
> >> I again send you an image with the error warning.
> >>
> >> Do you have any idea what this is, how to solve?
> >
> > It looks like zlib is not being linked.  The HDF5 library must be built
> > with zlib.
> > Also it might help to explictly link to the the zlib library, using
> >
> >   LIBS='-lnetcdf -lhdf5_hl -lhdf5 -lz'
> >
> > --Russ
> >
> >> On Fr, 19.09.2014, 18:05, Unidata netCDF Support wrote:
> >> > Hi Gabor,
> >> >
> >> > Since GOTM does not use autotools to configure the project (that I can
> >> > see), you would need to edit the makefiles yourself to change
> >> > -I/usr/local.
> >> > This is one of the drawbacks of having a hard coded Makefile
> >> containing
> >> > paths, unfortunately. The GOTM support might be able to provide more
> >> > direct
> >> > guidance regarding how to specify non-standard directories; if there
> >> is
> >> > such a mechanism in place, I could not find it, however.
> >> >
> >> > -Ward
> >> >
> >> > address@hidden> wrote:
> >> >
> >> > New Client Reply: Help NetCDF compilation or installation
> >> >>
> >> >> Hey Ward,
> >> >>
> >> >> The netcdf.mod is in the right directory, it seems to me more like
> >> the
> >> >> problem ist at the compilation, that it tries gfortran ...
> >> >> -I/usr/local/include; and it says Warning: the Include-Directory
> >> >> "-I/usr/local" cannot be found, because I don't have one. Is it maybe
> >> >> looking for NetCDF in that directory? Do you have any idea how to
> >> change
> >> >> that? Is this explicitly a problem of GOTM?
> >> >>
> >> >> Best,
> >> >> Gabor
> >> >>
> >> >>
> >> >> On Fr, 19.09.2014, 00:13, Unidata netCDF Support wrote:
> >> >> > Hi Gabor,
> >> >> >
> >> >> > I agree with you that at this point it appears to be an issue with
> >> >> GOTM
> >> >> > and
> >> >> > not with netcdf. GOTM is complaining about the lack of the file
> >> >> > netcdf.mod;
> >> >> > can you confirm that netcdf.mod is in the appropriate directory?
> >> >> >
> >> >> > -Ward
> >> >> >
> >> >> > address@hidden> wrote:
> >> >> >
> >> >> > New Client Reply: Help NetCDF compilation or installation
> >> >> >>
> >> >> >> Hi Ward,
> >> >> >>
> >> >> >> I rebuilt everything with CPPFALGS and again for NETCDF it worked,
> >> >> make
> >> >> >> check was successfull but the error for the GOTM built is still
> >> there
> >> >> >> (in
> >> >> >> the attachment).
> >> >> >>
> >> >> >> I just don't get rid of the feeling that there is something maybe
> >> >> wrong
> >> >> >> with the PATH, but I'm not much into this type of installations,
> >> I'm
> >> >> >> just
> >> >> >> guessing, but I also already tried different PATHS.
> >> >> >>
> >> >> >> Do you maybe have another idea? As it seems that NETCDF is OK.
> >> >> >>
> >> >> >> Best,
> >> >> >> Gabor
> >> >> >>
> >> >> >>
> >> >> >>  On Do, 18.09.2014, 23:08, Unidata netCDF Support wrote:
> >> >> >> > Hi Gabor,
> >> >> >> >
> >> >> >> > Russ pointed out an oversight to me; in my code below, we should
> >> >> use
> >> >> >> > CPPFLAGS instead of CFLAGS; my mistake!
> >> >> >> >
> >> >> >> > -Ward
> >> >> >> >
> >> >> >> > On Thu, Sep 18, 2014 at 1:23 PM, Ward Fisher
> >> >> >> <address@hidden>
> >> >> >> > wrote:
> >> >> >> >
> >> >> >> > Hi Gabor,
> >> >> >> >>
> >> >> >> >> Installing hdf5 will be pretty straightforward, once you have
> >> zlib
> >> >> >> >> installed.  The zlib that comes with cygwin should work just
> >> fine.
> >> >> >> >>
> >> >> >> >> When compiling hdf5 by hand, I use the following commands:
> >> >> >> >>
> >> >> >> >> $ ./configure --enable-hl --prefix=/home/WardF/local
> >> >> >> >> $ make
> >> >> >> >> $ make install
> >> >> >> >>
> >> >> >> >> At this point, you will configure netcdf as follows:
> >> >> >> >>
> >> >> >> >> $ CFLAGS="-I/home/WardF/local/include"
> >> >> >> LDFLAGS="-L/home/WardF/local/lib"
> >> >> >> >> ./configure --prefix=/home/WardF/local --disable-dap
> >> >> >> >> $ make
> >> >> >> >> $ make install
> >> >> >> >>
> >> >> >> >> I would then build netcdf-fortran as follows:
> >> >> >> >>
> >> >> >> >> $ CFLAGS="-I/home/WardF/local/include"
> >> >> >> LDFLAGS="-L/home/WardF/local/lib"
> >> >> >> >> LIBS="-lhdf5 -lhdf5_hl -lnetcdf" ./configure
> >> >> >> --prefix=/home/WardF/local
> >> >> >> >> $ make
> >> >> >> >> $ make install
> >> >> >> >>
> >> >> >> >> At this point, I would expect to have hdf5, netcdf, and
> >> >> >> netcdf-fortran
> >> >> >> >> all
> >> >> >> >> installed in the '/home/WardF/local' directory.  You will need
> >> to
> >> >> >> change
> >> >> >> >> the directory name for your system, but the rest should work.
> >> >> >> >>
> >> >> >> >> Once you have these libraries installed, GOTM should have
> >> >> everything
> >> >> >> it
> >> >> >> >> needs to build.  Let me know if this works for you,
> >> >> >> >>
> >> >> >> >> -Ward
> >> >> >> >>
> >> >> >> >> address@hidden> wrote:
> >> >> >> >>
> >> >> >> >>> New Client Reply: Help NetCDF compilation or installation
> >> >> >> >>>
> >> >> >> >>> Hi,
> >> >> >> >>>
> >> >> >> >>> NETCDF3 did not work, I guess I need your help to rebuild
> >> netcdf
> >> >> >> with
> >> >> >> >>> hdf5/netcdf-4 support. As mentioned i know I have to install
> >> zlib
> >> >> >> first
> >> >> >> >>> and after that hdf5, but before I'll do that I wait for
> >> further
> >> >> >> >>> instructions from you.
> >> >> >> >>>
> >> >> >> >>> Thanks,
> >> >> >> >>> Gabor
> >> >> >> >>>
> >> >> >> >>>
> >> >> >> >>> On Do, 18.09.2014, 19:11, Unidata netCDF Support wrote:
> >> >> >> >>> > Hi Gabor,
> >> >> >> >>> >
> >> >> >> >>> > I suspect that NETCDF_VERSION=NETCDF4 is incorrect, assuming
> >> >> you
> >> >> >> have
> >> >> >> >>> > disabled netcdf4 support when you built the netcdf library.
> >> >> This
> >> >> >> is a
> >> >> >> >>> > result of disabling hdf5, which is required for netcdf-4. I
> >> >> don't
> >> >> >> >>> know
> >> >> >> >>> > what
> >> >> >> >>> > other options GOTM supports, but I suspect you might want to
> >> >> use
> >> >> >> >>> NETCDF3
> >> >> >> >>> > instead.  If this does not work, it sounds like we might
> >> need
> >> >> to
> >> >> >> >>> build
> >> >> >> >>> > netcdf with netcdf-4 support.
> >> >> >> >>> >
> >> >> >> >>> > Let me know if specifying a different netcdf_version for
> >> GOTM
> >> >> >> works,
> >> >> >> >>> or
> >> >> >> >>> if
> >> >> >> >>> > we need to rebuild netcdf with hdf5/netcdf-4 support.
> >> >> >> >>> >
> >> >> >> >>> > Thanks!
> >> >> >> >>> >
> >> >> >> >>> > -Ward
> >> >> >> >>> >
> >> >> >> >>> > address@hidden> wrote:
> >> >> >> >>> >
> >> >> >> >>> >> New Client Reply: Help NetCDF compilation or installation
> >> >> >> >>> >>
> >> >> >> >>> >> Hello Ward!
> >> >> >> >>> >>
> >> >> >> >>> >> Thank you very much, the NetCDF installation worked fine. I
> >> >> did
> >> >> >> as
> >> >> >> >>> you
> >> >> >> >>> >> wrote and run afterwards also the make check and everything
> >> >> was
> >> >> >> >>> alright.
> >> >> >> >>> >>
> >> >> >> >>> >> Then I basically did the GOTM installation, but again it
> >> did
> >> >> not
> >> >> >> >>> work
> >> >> >> >>> >> and
> >> >> >> >>> >> just gave me the same error. I did the installation as
> >> >> following:
> >> >> >> >>> >> So I have a Path of /home/NETCDFT/GOTM/gotm-git
> >> >> >> >>> >> my NetCDF stuff is in NETCDF with the lib, include and
> >> other
> >> >> >> stuff .
> >> >> >> >>> >> So after getting the git clone I got to gotm-git/src and
> >> >> >> basically
> >> >> >> >>> type
> >> >> >> >>> >> the commands from
> >> >> >> >>> >>
> http://www.gotm.net/index.php?go=software&page=installation
> >> .
> >> >> >> >>> >>
> >> >> >> >>> >> As the GOTM people told me not to setup any export
> >> >> >> NETCDFINC=/../..,
> >> >> >> >>> I
> >> >> >> >>> >> should instead only type export NETCDF_VERSION=NETCDF4,
> >> that
> >> >> >> should
> >> >> >> >>> be
> >> >> >> >>> >> enough.
> >> >> >> >>> >>
> >> >> >> >>> >> So then I do
> >> >> >> >>> >> export GOTMDIR=/home/NETCDFT/GOTM/gotm-git
> >> >> >> >>> >> export FORTRAN_COMPILER=GFORTRAN
> >> >> >> >>> >> then i got to the gotm-git/src and type make
> >> >> >> >>> >>
> >> >> >> >>> >> I also attached an image of my Cygwin showing the error.
> >> >> >> >>> >>
> >> >> >> >>> >> Best regards,
> >> >> >> >>> >> Gabor
> >> >> >> >>> >>
> >> >> >> >>> >>
> >> >> >> >>> >>
> >> >> >> >>> >> On Do, 18.09.2014, 01:06, Unidata netCDF Support wrote:
> >> >> >> >>> >> > Hello,
> >> >> >> >>> >> >
> >> >> >> >>> >> >> Hello!
> >> >> >> >>> >> >>
> >> >> >> >>> >> >> I'm sorry to bother with some installation/compilation
> >> >> >> problems,
> >> >> >> >>> but
> >> >> >> >>> >> I
> >> >> >> >>> >> >> came to a point where I think I need some help.
> >> >> >> >>> >> >
> >> >> >> >>> >> > Not a problem; I will try to help as best I can.
> >> >> >> >>> >> >
> >> >> >> >>> >> >> I actually use Cygwin on Windows 7 and installed with
> >> the
> >> >> >> Cygwin
> >> >> >> >>> >> >> packages
> >> >> >> >>> >> >> the NetCDF and also the HDF5 files. I updated also my
> >> gcc
> >> >> and
> >> >> >> >>> fortran
> >> >> >> >>> >> >> compiler (Have now Gfortran 4.8.3).
> >> >> >> >>> >> >>
> >> >> >> >>> >> >
> >> >> >> >>> >> >> After that I wanted to install a program called 'GOTM'
> >> >> >> >>> >> >> (http://www.gotm.net/) but got always an error which I
> >> >> already
> >> >> >> >>> >> discussed
> >> >> >> >>> >> >> with the creators of the code. The error that occured is
> >> >> >> thought
> >> >> >> >>> that
> >> >> >> >>> >> >> the
> >> >> >> >>> >> >> gfortran compiler and the NetCDF are not working
> >> correctly
> >> >> >> >>> together.
> >> >> >> >>> >> >> They
> >> >> >> >>> >> >> said that I would have to compile the whole source code
> >> >> with
> >> >> >> my
> >> >> >> >>> >> >> installed
> >> >> >> >>> >> >> compiler so that it works. The error was (translated
> >> from
> >> >> >> >>> german):
> >> >> >> >>> >> "The
> >> >> >> >>> >> >> MODULE 'netcdf.mod' can not be read as it was created by
> >> a
> >> >> >> >>> different
> >> >> >> >>> >> >> Version of GNU Fortran".
> >> >> >> >>> >> >
> >> >> >> >>> >> > I am surprised that the netcdf-c and netcdf-fortran
> >> >> libraries
> >> >> >> >>> >> installed
> >> >> >> >>> >> > from the cygwin package manager did not work.  We should
> >> be
> >> >> >> able
> >> >> >> >>> to
> >> >> >> >>> >> work
> >> >> >> >>> >> > around it however.
> >> >> >> >>> >> >
> >> >> >> >>> >> >>
> >> >> >> >>> >> >> So I installed NetCDF manually on Cygwin (as i thought
> >> than
> >> >> it
> >> >> >> >>> would
> >> >> >> >>> >> be
> >> >> >> >>> >> >> compiled automatically with my actual compiler), but it
> >> >> still
> >> >> >> >>> doesn't
> >> >> >> >>> >> >> work. I've installed NetCDF without the HDF5, because
> >> HDF5
> >> >> >> >>> crashes
> >> >> >> >>> >> when
> >> >> >> >>> >> >> it's installed at the line of: Testing big.exe, when I
> >> do
> >> >> the
> >> >> >> >>> make
> >> >> >> >>> >> >> check.
> >> >> >> >>> >> >> I also don't know how to install netcdf-fortran without
> >> >> HDF5 .
> >> >> >> >>> >> >>
> >> >> >> >>> >> >
> >> >> >> >>> >> > I assume you are installing netcdf-c without either hdf5
> >> or
> >> >> >> dap;
> >> >> >> >>> >> assuming
> >> >> >> >>> >> > this is true, you would use the following options. Note
> >> that
> >> >> I
> >> >> >> am
> >> >> >> >>> >> using a
> >> >> >> >>> >> > directory specific to my environment; you will need to
> >> >> change
> >> >> >> the
> >> >> >> >>> >> paths
> >> >> >> >>> >> > appropriately for yours.
> >> >> >> >>> >> >
> >> >> >> >>> >> > $ ./configure --disable-netcdf-4 --disable-dap
> >> >> >> >>> >> --prefix=/home/WardF/local
> >> >> >> >>> >> > $ make
> >> >> >> >>> >> > $ make install
> >> >> >> >>> >> >
> >> >> >> >>> >> > For netcdf-fortran, you would then compile and install it
> >> as
> >> >> >> >>> follows:
> >> >> >> >>> >> >
> >> >> >> >>> >> > $ CFLAGS="-I/home/WardF/local/include"
> >> >> >> >>> >> LDFLAGS="-L/home/WardF/local/lib"
> >> >> >> >>> >> > ./configure --prefix=/home/WardF/local
> >> >> >> >>> >> > $ make
> >> >> >> >>> >> > $ make install
> >> >> >> >>> >> >
> >> >> >> >>> >> > I've set up a test cygwin system and, at this point, have
> >> >> >> >>> downloaded
> >> >> >> >>> >> and
> >> >> >> >>> >> > have tried to build GOTM, with no luck.  I know that my
> >> >> >> libnetcdf
> >> >> >> >>> and
> >> >> >> >>> >> > libnetcdff (C and fortran libraries, respectively) built
> >> >> >> properly
> >> >> >> >>> >> because
> >> >> >> >>> >> > they each passed 'make check'.
> >> >> >> >>> >> >
> >> >> >> >>> >> > If you attempt to repeat the steps as I've outlined
> >> above,
> >> >> does
> >> >> >> >>> >> everything
> >> >> >> >>> >> > work and install properly for you?
> >> >> >> >>> >> >
> >> >> >> >>> >> > Can you provide information re: how you are trying to
> >> build
> >> >> >> GOTM,
> >> >> >> >>> >> after
> >> >> >> >>> >> > installing netcdf C and Fortran? I can try to replicate
> >> that
> >> >> on
> >> >> >> my
> >> >> >> >>> >> system
> >> >> >> >>> >> > to further diagnose this.
> >> >> >> >>> >> >
> >> >> >> >>> >> > Thanks, have a good day,
> >> >> >> >>> >> >
> >> >> >> >>> >> > -Ward
> >> >> >> >>> >> >
> >> >> >> >>> >> >> How can I compile the source code with my actual
> >> Gfortran
> >> >> >> >>> compiler
> >> >> >> >>> so
> >> >> >> >>> >> >> that
> >> >> >> >>> >> >> it works (on Cygwin)? Or should I install an older
> >> gfortran
> >> >> >> >>> compiler,
> >> >> >> >>> >> if
> >> >> >> >>> >> >> yes which version? Is there another way maybe to fix
> >> this,
> >> >> or
> >> >> >> do
> >> >> >> >>> I
> >> >> >> >>> >> >> something wrong or miss a point. I followed the
> >> >> >> >>> netcdf-install.txt
> >> >> >> >>> >> and
> >> >> >> >>> >> >> also the
> >> >> >> >>> >> >>
> >> >> >>
> http://www.unidata.ucar.edu/software/netcdf/docs/build_default.html
> >> >> >> >>> >> >>
> >> >> >> >>> >> >> I also send you my test-suite log attached to this mail.
> >> So
> >> >> I
> >> >> >> had
> >> >> >> >>> >> HDF5
> >> >> >> >>> >> >> on
> >> >> >> >>> >> >> Cygwin, as you can download and install it on Cygwin via
> >> >> >> package,
> >> >> >> >>> but
> >> >> >> >>> >> as
> >> >> >> >>> >> >> I
> >> >> >> >>> >> >> tried to install HDF5 1.8.12, it crashed always at make
> >> >> check.
> >> >> >> >>> >> >>
> >> >> >> >>> >> >> I appreciate any help or suggestions!
> >> >> >> >>> >> >>
> >> >> >> >>> >> >> Best regards,
> >> >> >> >>> >> >> Gabor Kiss
> >> >> >> >>> >> >>
> >> >> >> >>> >> >
> >> >> >> >>> >> > Ticket Details
> >> >> >> >>> >> > ===================
> >> >> >> >>> >> > Ticket ID: FTZ-975139
> >> >> >> >>> >> > Department: Support netCDF
> >> >> >> >>> >> > Priority: Normal
> >> >> >> >>> >> > Status: Closed
> >> >> >> >>> >> >
> >> >> >> >>> >> >
> >> >> >> >>> >>
> >> >> >> >>> >>
> >> >> >> >>> >>
> >> >> >> >>> >> Ticket Details
> >> >> >> >>> >> ===================
> >> >> >> >>> >> Ticket ID: FTZ-975139
> >> >> >> >>> >> Department: Support netCDF
> >> >> >> >>> >> Priority: Normal
> >> >> >> >>> >> Status: Open
> >> >> >> >>> >> Link:
> >> >> >> >>> >>
> >> >> >> >>>
> >> >> >>
> >> >>
> https://www.unidata.ucar.edu/esupport/staff/index.php?_m=tickets&_a=viewticket&ticketid=24469
> >> >> >> >>> >
> >> >> >> >>> >
> >> >> >> >>> >
> >> >> >> >>> > Ticket Details
> >> >> >> >>> > ===================
> >> >> >> >>> > Ticket ID: FTZ-975139
> >> >> >> >>> > Department: Support netCDF
> >> >> >> >>> > Priority: Normal
> >> >> >> >>> > Status: Open
> >> >> >> >>> >
> >> >> >> >>> >
> >> >> >> >>>
> >> >> >> >>>
> >> >> >> >>>
> >> >> >> >>>
> >> >> >> >>> Ticket Details
> >> >> >> >>> ===================
> >> >> >> >>> Ticket ID: FTZ-975139
> >> >> >> >>> Department: Support netCDF
> >> >> >> >>> Priority: Normal
> >> >> >> >>> Status: Open
> >> >> >> >>> Link:
> >> >> >> >>>
> >> >> >>
> >> >>
> https://www.unidata.ucar.edu/esupport/staff/index.php?_m=tickets&_a=viewticket&ticketid=24469
> >> >> >> >>>
> >> >> >> >>>
> >> >> >> >>  ?
> >> >> >> >
> >> >> >> >
> >> >> >> >
> >> >> >> > Ticket Details
> >> >> >> > ===================
> >> >> >> > Ticket ID: FTZ-975139
> >> >> >> > Department: Support netCDF
> >> >> >> > Priority: Normal
> >> >> >> > Status: Open
> >> >> >> >
> >> >> >> >
> >> >> >>
> >> >> >>
> >> >> >>
> >> >> >> Ticket Details
> >> >> >> ===================
> >> >> >> Ticket ID: FTZ-975139
> >> >> >> Department: Support netCDF
> >> >> >> Priority: Normal
> >> >> >> Status: Open
> >> >> >> Link:
> >> >> >>
> >> >>
> https://www.unidata.ucar.edu/esupport/staff/index.php?_m=tickets&_a=viewticket&ticketid=24469
> >> >> >>
> >> >> > ?
> >> >> >
> >> >> >
> >> >> >
> >> >> > Ticket Details
> >> >> > ===================
> >> >> > Ticket ID: FTZ-975139
> >> >> > Department: Support netCDF
> >> >> > Priority: Normal
> >> >> > Status: Open
> >> >> >
> >> >> >
> >> >>
> >> >>
> >> >>
> >> >>
> >> >> Ticket Details
> >> >> ===================
> >> >> Ticket ID: FTZ-975139
> >> >> Department: Support netCDF
> >> >> Priority: Normal
> >> >> Status: Open
> >> >> Link:
> >> >>
> https://www.unidata.ucar.edu/esupport/staff/index.php?_m=tickets&_a=viewticket&ticketid=24469
> >> >>
> >> >>  ?
> >> >
> >> >
> >> >
> >> > Ticket Details
> >> > ===================
> >> > Ticket ID: FTZ-975139
> >> > Department: Support netCDF
> >> > Priority: Normal
> >> > Status: Open
> >> >
> >> >
> >>
> >>
> >
> > Russ Rew                                         UCAR Unidata Program
> > address@hidden                      http://www.unidata.ucar.edu
> >
> >
> >
> > Ticket Details
> > ===================
> > Ticket ID: FTZ-975139
> > Department: Support netCDF
> > Priority: Normal
> > Status: Closed
> >
> >
>
>
>
> Ticket Details
> ===================
> Ticket ID: FTZ-975139
> Department: Support netCDF
> Priority: Normal
> Status: Open
> Link:
> https://www.unidata.ucar.edu/esupport/staff/index.php?_m=tickets&_a=viewticket&ticketid=24469



Ticket Details
===================
Ticket ID: FTZ-975139
Department: Support netCDF
Priority: Normal
Status: Open