Serial Petsc .... But undefined reference to MPI_Init()?

#DOMINIC DENVER JOHN CHANDAR# DOMI0002 at ntu.edu.sg
Fri Jan 19 10:49:54 CST 2007


Hi,
 
     Ive installed the serial version of petsc couple of months back
sucessfully. I did it again just now on Itanium-64 with the compiler
options
mpi=0. Just wondering, although libmpiuni.a is getting linked, i still
get undefined ref to MPI_Init()? Any clues ?
 
gcc -c -Wall -g3 -I/home/pdominic/petsc-2.2.1
-I/home/pdominic/petsc-2.2.1/bmake/linux-gnu-ia64-intel
-I/home/pdominic/petsc-2.2.1/include
-I/home/pdominic/petsc-2.2.1/include/mpiuni -DPETSC_USE_BOPT_g
-DPETSC_USE_EXTERN_CXX -D__SDIR__="src/ksp/examples/tests/" ex2.c

gcc  -Wall -g3
-Wl,-rpath,/home/pdominic/petsc-2.2.1/lib/libg/linux-gnu-ia64-intel  -o
ex2 ex2.o  -L/home/pdominic/petsc-2.2.1/lib/libg/linux-gnu-ia64-intel
-lpetscksp -lpetscdm -lpetscmat -lpetscvec -lpetsc
-L/usr/X11R6/lib -lX11
-Wl,-rpath,/usr/lib -L/usr/lib -llapack -Wl,-rpath,/usr/lib -L/usr/lib
-lblas
-Wl,-rpath,/usr/src/gcc-3.0.4-build2/lib/gcc-lib/ia64-unknown-linux/3.0.
4 -L/usr/src/gcc-3.0.4-build2/lib/gcc-lib/ia64-unknown-linux/3.0.4 -lg2c
-L/home/pdominic/petsc-2.2.1/lib/libg/linux-gnu-ia64-intel -lmpiuni -ldl
-ldl -ldl -ldl -lm  -lg2c -lm
-L/usr/local/lib/gcc-lib/ia64-unknown-linux/3.0.4
-L/usr/local/lib/gcc-lib/ia64-unknown-linux/3.0.4/../../.. -lm
ex2.o: In function `main':

/home/pdominic/petsc-2.2.1/src/ksp/examples/tests/ex2.c:31: undefined
reference to `MPI_Init'
/home/pdominic/petsc-2.2.1/src/ksp/examples/tests/ex2.c:33: undefined
reference to `MPI_Finalize'
collect2: ld returned 1 exit status
make: [ex2] Error 1 (ignored)
rm -f ex2.o

 
Regards,
Dominic
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mcs.anl.gov/pipermail/petsc-users/attachments/20070120/a611562e/attachment.htm>


More information about the petsc-users mailing list