Re: [netcdfgroup] issue compiling netcdf4 with mpi

Howdy Joe,

It looks like something like this has been encountered when trying to compile with the PGI compilers:
http://www.unidata.ucar.edu/support/help/MailArchives/netcdf/msg01641.html

There is some discussion of the thread re. the procedure naming conventions for FORTRAN that may be at the heart of the problem.

Do you know what the underlying compilers are?

What do you get from  "nm  .../libnetcdf.a |grep nf_"



go slugs!

- Richard


At 12:26 AM -0800 2/3/10, Joe Buck wrote:
I've built mpi2 v 1.2.1 with these flags:
CFLAGS="-D_LARGEFILE_SOURCE -D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64 -fPIC" ./configure --enable-f90 --enable-f77 --with-mpe --with-romio --prefix=/install/mpich2-121

I then build hdf5 v1.8 with these flags:
FC=mpif90 F77=mpif77 F90=mpif90 CC=mpicc CFLAGS="-D_LARGEFILE_SOURCE -D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64 -fPIC" LIBS="-lz -lm" ./configure --enable-parallel --enable-fortran --prefix=/install/hdf5-1.8 --disable-shared

and everything with hdf5 checked out with "make check"

Finally I configured netcdf v4.0.1 like so:
buck@bender:/tmp/netcdf-4.0.1$ CPPFLAGS="-I/install/mpich2-121/include -D_LARGEFILE_SOURCE -D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64 -fPIC" CFLAGS="-I/install/mpich2-121/include -D_LARGEFILE_SOURCE -D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64 -fPIC" F77=mpif77 F90=mpif90 FC=mpif90 CC=mpicc CXX=mpicxx LIBS="-lz -lm" ./configure --enable-netcdf-4 --prefix=/install/netcdf-4.0.1 --enable-large-file-tests --with-hdf5=/install/hdf5-1.8 --with-zlib=/usr --enable-separate-fortran


make works just fine but when I run "make check" I get errors when it tries to build fortran files that start like this: /bin/sh ../libtool --tag=F77 --mode=link mpif77 -I../fortran -I/install/hdf5-1.8/include -I/usr/include -I../libsrc4 -I../f90 -g -L/lib -L/install/hdf5-1.8/lib -L/usr/lib -o nf_test test_get.o test_put.o nf_error.o nf_test.o test_read.o test_write.o util.o fortlib.o ../fortran/<http://*libnetcdff.la>libnetcdff.la -lm ../libsrc4/<http://*libnetcdf.la>libnetcdf.la -lhdf5_hl -lhdf5 -lz -lm libtool: link: mpif77 -I../fortran -I/install/hdf5-1.8/include -I/usr/include -I../libsrc4 -I../f90 -g -o nf_test test_get.o test_put.o nf_error.o nf_test.o test_read.o test_write.o util.o fortlib.o -L/lib -L/install/hdf5-1.8/lib -L/usr/lib ../fortran/.libs/libnetcdff.a /tmp/netcdf-4.0.1/libsrc4/.libs/libnetcdf.a ../libsrc4/.libs/libnetcdf.a /install/hdf5-1.8/lib/libhdf5_hl.a /install/hdf5-1.8/lib/libhdf5.a -lz -lm
test_get.o: In function `test_nf_get_var1_text':
/tmp/netcdf-4.0.1/nf_test/test_get.F:25: undefined reference to `nf_open_'
/tmp/netcdf-4.0.1/nf_test/test_get.F:34: undefined reference to `nf_get_var1_text_' /tmp/netcdf-4.0.1/nf_test/test_get.F:38: undefined reference to `nf_get_var1_text_'
....

I'm attaching the entire results.
Any ideas would be appreciated. I've tried playing with flags for a while and can't quite seem to get this ironed out.
Thanks,
-Joe Buck

Content-Type: text/plain; charset=US-ASCII; name="mc2.txt"
Content-Disposition: attachment; filename="mc2.txt"
X-Attachment-Id: f_g57utkpj0

Attachment converted: Macintosh HD:mc2.txt (TEXT/MSWD) (01CF155F)
_______________________________________________
netcdfgroup mailing list
netcdfgroup@xxxxxxxxxxxxxxxx
For list information or to unsubscribe, visit: http://*www.*unidata.ucar.edu/mailing_lists/


--



====================================================

Richard Hedges
Customer Support and Test - File Systems Project
Development Environment Group - Livermore Computing
Lawrence Livermore National Laboratory
7000 East Avenue, MS L-557
Livermore, CA   94551

v:      (925) 423-2699
f:      (925) 423-6961
E:      richard-hedges@xxxxxxxx
  • 2010 messages navigation, sorted by:
    1. Thread
    2. Subject
    3. Author
    4. Date
    5. ↑ Table Of Contents
  • Search the netcdfgroup archives: