On Sep 28, 2007, at 4:56 AM, Massimo Cafaro wrote:

Dear all,

when I try to compile my MPI code on 64 bits intel Mac OS X the build fails since the Open MPI library has been compiled using 32 bits. Can you please provide in the next version the ability at configure time to choose between 32 and 64 bits or even better compile by defaults using both modes?

To reproduce the problem, simply compile on 64 bits intel Mac OS X an MPI application using mpicc -arch x86_64. The 64 bits linker complains as follows:

ld64 warning: in /usr/local/mpi/lib/libmpi.dylib, file is not of required architecture ld64 warning: in /usr/local/mpi/lib/libopen-rte.dylib, file is not of required architecture ld64 warning: in /usr/local/mpi/lib/libopen-pal.dylib, file is not of required architecture

and a number of undefined symbols is shown, one for each MPI function used in the application.

This is already possible.  Simply use the configure options:

./configure ... CFLAGS="-arch x86_64" CXXFLAGS="-arch x86_64" OBJCFLAGS="-arch x86_64"

also set FFLAGS and FCFLAGS to "-m64" if you have gfortran/g95 compiler installed. The common installs of either don't speak the - arch option, so you have to use the more traditional -m64.

Hope this helps,

Brian

Reply via email to