Here is what I did to get pyMPI to build under Cygwin
-- haven't gotten it running yet, tho.
I installed mpich from
http://www-unix.mcs.anl.gov/~ashton/mpich.nt/
I could not get pyMPI to link against the shared
library (libpython2.2.dll.a) -- I got a raft of
messages such as
Warning: resolving __Py_NoneStruct by linking to
__imp___Py_NoneStruct (auto-import)
Apparently we must define -DUSE_DL_IMPORT, but doing so
makes gcc very unhappy:
mpicart.c:284: initializer element is not constant
mpicart.c:284: (near initialization for
`MPI_CartCommType.ob_type')
I dunno what's going on here.
So instead I rebuilt python from sources
(ftp://mirrors.rcn.net/mirrors/sources.redhat.com/cygwin/release/python/python-2.2-1-src.tar.bz2)
and used the static library (libpython2.2.a), which
worked OK. ( I had to hide the shared version:
mv /lib/python2.2/config/libpython2.2.dll.a
/lib/python2.2/config/libpythondll2.2.dll.a
To build pyMPI, I run
MPI_PATH=/c/apps/Applications/MPIch/SDK.gcc
# or wherever you installed it...
./configure --with-libs='-L$MPI_PATH/lib -lmpich'
--with-includes='-I$MPI_PATH/include'
Then, when I run it with
mpirun ./pyMPI examples/fractal.py
I get
Fatal Python error: PyThreadState_Get: no current thread
4 [sig] pyMPI 3652 open_stackdumpfile: Dumping
stack trace to pyMPI.exe.stackdum
The debugger shows it crashing while loading the first
module.