When running valgrind to detect errors in an mpi application, I get the following error:
libmpi.so.0: cannot open shared object file: No such file or directory
I found out the following: Valgrind documentation (section 4.9.1) states that "The MPI functions to be wrapped are assumed to be in an ELF shared object with soname matching libmpi.so*. This is known to be correct at least for Open MPI and Quadrics MPI, and can easily be changed if required."
So since I'm using mpich2, it should actually use libmpich.so.1.0.
This can be seen in libmpiwrap.c:
#include "mpi.h"
/* Where are API symbols?
Open MPI lib/libmpi.so, soname = libmpi.so.0
Quadrics MPI lib/libmpi.so, soname = libmpi.so.0
MPICH libmpich.so.1.0, soname = libmpich.so.1.0
A suitable soname to match with is therefore "libmpi*.so*".
My questions is: where and how do I configure this?