a couple of issues: - Looks like you've installed petsc at --prefix=/usr/local/petsc-3.1-p8-dbg - but using from -I/usr/local/petsc-3.1-p8-opt
- Should avoid pointing to std locations as configure will always look there. --with-blas-lapack-dir=/usr/lib --with-mpi-dir=/usr - when reinstalling - make sure the prefix location does not have any old install files. And to track the duplicate location of MPI_FILE_NULL - suggest compiling the code with '-E' preprocessor directive - and then locate MPI_FILE_NULL there.. i.e mpif90 -c -g -ffree-line-length-none -fcray-pointer -DMOAB -fPIC -Wall -Wno-unused-variable -O -I/usr/local/petsc-3.1-p8-opt/include -I/usr/local/petsc-3.1-p8-opt/include -I/usr/include/scotch -I/usr/lib/openmpi/include -I/usr/lib/openmpi/lib -I/usr/include/spooles -I/usr/include/suitesparse -I/usr/local/petsc-3.1-p8-opt/include -I/usr/include/scotch -I/usr/lib/openmpi/include -I/usr/lib/openmpi/lib -I/usr/include/spooles -I/usr/include/suitesparse -I. -I./MeshLibrary/RTelements -I/usr/local/hdf5-1.8.8-par-openmpi-gcc/include -I/home/tautges/code/MOABpar/include MeshLibrary/PNTmesh_Import.F90 -E > out.f Satish On Wed, 21 Mar 2012, Tim Tautges wrote: > Hi all, > I'm almost embarrassed to be asking this, but haven't found anything that > looks similar in the archives... > > I'm compiling fortran code and get: > > mpif90 -c -g -ffree-line-length-none -fcray-pointer -DMOAB -fPIC -Wall > -Wno-unused-variable -O -I/usr/local/petsc-3.1-p8-opt/include > -I/usr/local/petsc-3.1-p8-opt/include -I/usr/include/scotch > -I/usr/lib/openmpi/include -I/usr/lib/openmpi/lib -I/usr/include/spooles > -I/usr/include/suitesparse -I/usr/local/petsc-3.1-p8-opt/include > -I/usr/include/scotch -I/usr/lib/openmpi/include -I/usr/lib/openmpi/lib > -I/usr/include/spooles -I/usr/include/suitesparse -I. > -I./MeshLibrary/RTelements -I/usr/local/hdf5-1.8.8-par-openmpi-gcc/include > -I/home/tautges/code/MOABpar/include -o MeshLibrary/PNTmesh_Import.o > MeshLibrary/PNTmesh_Import.F90 > mpif-mpi-io.h:64.27: > Included at mpif-config.h:65: > Included at mpif-common.h:70: > Included at /usr/lib/openmpi/include/mpif.h:59: > Included at /usr/local/petsc-3.1-p8-opt/include/finclude/petscsys.h:11: > Included at /usr/local/petsc-3.1-p8-opt/include/finclude/petsc.h:6: > Included at MeshLibrary/PNTmesh_Import.F90:16: > > integer MPI_FILE_NULL > 1 > Error: Symbol 'mpi_file_null' at (1) already has basic type of INTEGER > > > My petsc configure options (as reported in arch/configure.log) are: > > Configure Options: --configModules=PETSc.Configure > --optionsModule=PETSc.compilerOptions --with-clanguage=C++ > --with-blas-lapack-dir=/usr/lib --with-mpi-dir=/usr --with-debugging=1 > --prefix=/usr/local/petsc-3.1-p8-dbg > Working directory: /home/tautges/linux/petsc-3.1-p8 > > This is an Ubuntu 10.04 system, synaptic-installed openmpi, gfortran 4.4.3, > all pretty standard stuff. I think the problem started showing up when I > inserted the "--with-clanguage=C++" in the configure line, expecting that > would take care of finding the C++ std libs for me (which it did). Clues? > > Thanks. > > - tim > >
