[mpich-discuss] using alternate mpi on osx from xcode

Thomas Blom blomcode at gmail.com
Thu Jan 8 16:45:12 CST 2009


I'm building a test app via makefile on osx that uses mpich2 (which I
compiled from source and whose binaries end up in /usr/local/bin).

It is a trivial mpi app and builds via this trivial makefile:

test : main.cpp
        mpicxx -g  main.cpp -o testmpi

>From a terminal window, I can make and execute it with the expected results,
with one or multiple processes.


If I create an "External Build System" project in Xcode and point to this
makefile and try to build the target, XCode tries to use the mpicxx that is
located in /Developer/usr/bin despite the fact that from a commad prompt,
"which mpicxx" reports /usr/local/bin/mpicxx.

So one can go to /Developer/usr/bin and mv all the mpi* binaries into
mpi_hidden or some such, at which point Xcode will complain that it can't
find mpicxx.  So one can create a link from /Developer/usr/bin that
references the mpich2 binary /usr/local/bin/mpicxx.  Now things will build
and work as desired.

My question, then...  What is the recommended practice to get Xcode to use
the mpicxx I want without all this problematic moving around/hiding of
binaries?  One option would be to cleanly remove the openmpi that comes with
osx; a better option would be a way to spec the path that Xcode will search
for binaries, but I don't know how to do either.

thomas blom,
ut austin
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mcs.anl.gov/pipermail/mpich-discuss/attachments/20090108/fd3cc8d7/attachment.htm>

More information about the mpich-discuss mailing list