[netcdf-hdf] script to compile parallel hdf5

I have been trying for the longest time to compile the hdf5 library with the 
--enable-parallel option so that I can then compile netCDF with HDF on my 
MacBook Pro using Lion (10.7.4). I have been in touch with the hdf-forum 
mailing list but I have not gotten any response. I assume that some of you must 
have gone through the same steps to install hdf5 parallel. May be one of you 
can help me figure out what I am doing wrong?

Here are my settings:
sudo ./configure --prefix=/usr/local/hdf5-1.8.9-gfortran --enable-parallel 
--enable-fortran --with-zlib=/usr/local/zlib-1.2.7-gfortran/

I have tested my mpich2 implementation and know that to works. I am getting the 
following error message:

checking for API tracing... no
checking for instrumented library... no
checking whether to clear file buffers... yes
checking whether a memory checking tool will be used... no
checking for parallel support files... provided by compiler
checking for MPI_Init in -lmpi... no
checking for MPI_Init in -lmpich... no
checking for
            include 'mpif.h'
            integer:: ierr
            call mpi_file_open( ierr ) in -lmpi... ./configure: line 27480: 
${ac_cv_lib_mpi_ ____________include__mpif_h_ ____________integer___ierr 
____________call_mpi_file_open__ierr__+:}: bad substitution
./configure: line 27496: ac_cv_lib_mpi_: command not found
./configure: line 27497: ____________include__mpif_h_: command not found
./configure: line 27498: ____________integer___ierr: command not found
./configure: line 27502: ____________include__mpif_h_: command not found
checking prefix for running on one processor... 
checking prefix for running in parallel... 
checking whether a simple MPI-IO program can be linked... no
configure: error: unable to link a simple MPI-IO application

I checked my mpi implementation. The subroutine mpi_file_open is in mpio.h and 
not in mpif.h. So I am not sure why configure points to mpif.h and not mpio.h. 
I do not know how to proceed from there from folks on the netcdf side. Any 


!  Laura D. Fowler
!  e-mail:  ldfowler58@xxxxxx
!  Phone:  970-215-0516