I am having a problem linking MPI C++ programs on an x86_64 system:
cat lamTest.cpp:
#include "mpi.h"
main(int argc, char** argv){
MPI_Init(&argc, &argv);
MPI_Finalize();
return 0;
}
mpiCC -o lamTest lamTest.cpp:
/tmp/ccYTWBTc.o(.gnu.linkonce.t._ZNK4PMPI9Intracomm6ExscanEPKvPviRKNS_8DatatypeERKNS_2OpE+0x5d):
In function `PMPI::Intracomm::Exscan(void const*, void*, int,
PMPI::Datatype const&, PMPI::Op const&) const':
: undefined reference to `MPI_Exscan'
/tmp/ccYTWBTc.o(.gnu.linkonce.t._ZNK4PMPI9Intracomm9AlltoallwEPKvPKiS4_PKNS_8DatatypeEPvS4_S4_S7_+0x63):
In function `PMPI::Intracomm::Alltoallw(void const*, int const*, int
const*, PMPI::Datatype const*, void*, int const*, int const*,
PMPI::Datatype const*) const':
: undefined reference to `MPI_Alltoallw'
collect2: ld returned 1 exit status
mpiCC: No such file or directory
I have tried lam-7.1.2 and lam-7.1.3b1, compiling from source code each
time with default options to configure.
My operating system is Red Hat Enterprise Linux WS release 4 (Nahant
Update 3), using the redhat kernel version
Linux dev4-01 2.6.9-34.0.2.ELsmp #1 SMPl
Any ideas?
|