[netcdfgroup] Building Fortran NetCDF only ?

Hi,

Is it possible to build the NetCDF fortran *only* ?

-> Plateform info : Mac OS X 10.6.4, gfortran compiler  4.1.2. NetCDF 4.1.1

On my computer, I have a working NetCDF 4.1.1 with C and C++ interface only. 
I've installed it using MacPorts (which put it in /opt/local).

I want to use NetCDF in Fortran 90, so I need to build NetCDF from the source. 
But I want to avoid to have two libnetcf.a on my computer. I try to build ONLY 
the fortran interface, building only libnetcdff (note the 2 f ..). My hope is 
to be able to compile a fortran program using libnetcdf from MacPorts and 
libnetcdff from my own install.

I've tried : ./configure --enable-netcdf-4 --disable-c --disable-cxx 
--disable-v2 --with-netcdf-c=/opt/local --with-netcdf-c-lib=/opt/local 
--enable-separate-fortran --enable-dap --enable-ncgen4 --with-libcf 
--with-hdf5=/opt/local --with-zlib=/opt/local --with-szlib=/opt/local 
--prefix=/usr/softs --enable-docs-install

But when compiling, the makefile want to access to ../libsrc4/libnetcdf.la and 
../../libsrc4/libnetcdf.la where I want to use /opt/local/lib/libnetcdf.la

I've made some progress using : make 
libnetcdff_la_LIBADD=/opt/local/lib/libnetcdf.la
But this library is referenced in some files that it doesn't seem to be a good 
solution

It creates a libnetcff.a library with fortran interface routine (NF_*) but no 
F90 interface.

Any hint ?

Olivier

-- 
Dr. Olivier Marti  - mailto:olivier.marti@xxxxxxxxxxxx
Laboratoire des Sciences du Climat et de l'Environnement
Institut Pierre Simon Laplace
Laboratoire CEA-CNRS-UVSQ  -  UMR 8212
Tel : +33 1 69 08 77 27 - Mob : +33 6 45 36 43 74
Fax: +33 1 69 08 30 73
<http://www.lsce.ipsl.fr/Pisp/56/olivier.marti.html>










  • 2010 messages navigation, sorted by:
    1. Thread
    2. Subject
    3. Author
    4. Date
    5. ↑ Table Of Contents
  • Search the netcdfgroup archives: