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

[netCDF #YZR-242908]: NetCDF Fortran Source Code Beta Release


> I have installed successfully the NetCDF 4.2 C Library.
> Now I want to install Fortran NetCDF Library. I downloaded
> netcdf-fortran-4.4-beta1 from the unidata website.
> I followed the procedure to install as mentioned website, which is as:
> 1. CPPFLAGS=-I/home/include LDFLAGS=-L/home/lib LD_LIBRARY_PATH=/home/lib 
> ./configure --prefix=/home
> This worked well with any error. Then I did:
> 2. make check
> Here is the problem: The output of make check is as:
> make check
> Making check in fortran
> make[1]: Entering directory 
> `/home/netcdf-fortran-4.4-beta1/netcdf-fortran-4.4-beta1/fortran'
> gfortran -DHAVE_CONFIG_H -I. -I.. -I../libsrc    -I/home/include  -g -O2 -c 
> -o module_netcdf_nc_data.o module_netcdf_nc_data.F90
> gfortran  -g -O2 -c -o module_netcdf_nc_interfaces.o  
> module_netcdf_nc_interfaces.f90
> gfortran -DHAVE_CONFIG_H -I. -I.. -I../libsrc    -I/home/include  -g -O2 -c 
> -o module_netcdf_nf_data.o module_netcdf_nf_data.F90
> gfortran -DHAVE_CONFIG_H -I. -I.. -I../libsrc    -I/home/include  -g -O2 -c 
> -o module_netcdf_nf_interfaces.o module_netcdf_nf_interfaces.F90
> gfortran  -g -O2 -c -o module_netcdf_f03.o  module_netcdf_f03.f90
> for lc in netcdf_nc_data.mod netcdf_nc_interfaces.mod netcdf_nf_data.mod  
> netcdf_nf_interfaces.mod netcdf_f03.mod  ; do \
> uc="${lc%%.mod}" ; \
> uc=`echo $uc | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`; 
> \
> uc="${uc}.mod" ; rm -f $uc ; cp $lc $uc ; \
> done
> cp: cannot stat `netcdf_nc_data.mod': No such file or directory
> cp: cannot stat `netcdf_nc_interfaces.mod': No such file or directory
> cp: cannot stat `netcdf_nf_data.mod': No such file or directory
> cp: cannot stat `netcdf_nf_interfaces.mod': No such file or directory
> cp: cannot stat `netcdf_f03.mod': No such file or directory
> Makefile:741: recipe for target `NETCDF_NC_DATA.mod' failed
> make[1]: *** [NETCDF_NC_DATA.mod] Error 1
> make[1]: Leaving directory 
> `/home/netcdf-fortran-4.4-beta1/netcdf-fortran-4.4-beta1/fortran'
> Makefile:429: recipe for target `check-recursive' failed
> make: *** [check-recursive] Error 1
> I will be very grateful to Unidata if you please help me in resolving the 
> above errors and to install Fortran NetCDF Library!

I started working on your reproducing your problem today, and noticed that 
a previously-installed netCDF-Fortran library can interfere with building
the new library with netcdf-fortran-4.4-beta1, because the include path
specified by CPPFLAGS (-I/home/include) gets put on the compiler invocation line
before the include path for the source code directory (-I../fortran), and
this can cause inclusion of the wrong header files or compiled module files.

I don't know if this is a problem in your case, but if you have previous Fortran
.inc or .mod files in /home/include, try deleting those first, before building
from netcdf-fortran-4.4-beta1.

I haven't got a solution for this problem yet and won't get to it again until
the middle of next week, but I hope to be able to reproduce it and diagnose the
cause by then ...


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

Ticket Details
Ticket ID: YZR-242908
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.