UW AMath High Performance Scientific Computing
AMath 483/583 Class Notes
Spring Quarter, 2011

Previous topic

MPI with subroutine calls

Next topic


This Page

Installing MPI on a MacΒΆ

On a Mac you might get the following error:

$ mpif90 pisum1.f90
Unfortunately, this installation of Open MPI was not compiled with
Fortran 90 support.  As such, the mpif90 compiler is non-functional.

This indicates that the Mac has a version of MPI, but not one that works with Fortran 90.

To fix this, see http://www.macresearch.org/compiling-mpi-f90-support-snow-leopard.

Kyle Mandli suggests the following modifications to what’s there:

  1. All of the compilers in the flags are intel compilers, you need to switch them to the corresponding gcc compilers such as

    CXX=g++ CC=gcc F77=gfortran F90=gfortran FC=gfortran

    although I would be surprised if the configure script does not figure this out for itself.

  2. I might also suggest using a different prefix than /opt/openmpi (something more sensible would be /usr/local). If you use the /usr/local prefix you should not have to set all the paths.

  3. The –with-xgrid flag is not installed by default with OpenMPI so you can skip that flag as well.