Extending Python with C: Cannot find MPI library

Jeroen Ruigrok van der Werven asmodai at in-nomine.org
Thu Jun 19 14:10:06 CEST 2008

-On [20080619 13:53], Spectrum (spectrumdt at gmail.com) wrote:
>  ImportError: /big/School/Cluster/Opgave03/ctest.so: undefined
>symbol: ompi_mpi_comm_world
>  [ore at localhost Opgave03]$
>  Can anyone suggest anything? Can I get MPI to work in Python?

Sounds like a typical case of not specifying any -L and/or -l options. In
this case the ctest.so module has an undefined reference to the symbol
ompi_mpi_comm_world and cannot resolve it. So either it was not linked
properly or the loader cannot find the required library.

Apply nm -D and ldd to the .so and see what ails.

Jeroen Ruigrok van der Werven <asmodai(-at-)in-nomine.org> / asmodai
イェルーン ラウフロック ヴァン デル ウェルヴェン
http://www.in-nomine.org/ | http://www.rangaku.org/ | GPG: 2EAC625B
Under this standard shalt thou conquer...

More information about the Python-list mailing list