Next: , Previous: , Up: Distributed-memory FFTW with MPI   [Contents][Index]


6.1 FFTW MPI Installation

All of the FFTW MPI code is located in the mpi subdirectory of the FFTW package. On Unix systems, the FFTW MPI libraries and header files are automatically configured, compiled, and installed along with the uniprocessor FFTW libraries simply by including --enable-mpi in the flags to the configure script (see Installation on Unix).

Any implementation of the MPI standard, version 1 or later, should work with FFTW. The configure script will attempt to automatically detect how to compile and link code using your MPI implementation. In some cases, especially if you have multiple different MPI implementations installed or have an unusual MPI software package, you may need to provide this information explicitly.

Most commonly, one compiles MPI code by invoking a special compiler command, typically mpicc for C code. The configure script knows the most common names for this command, but you can specify the MPI compilation command explicitly by setting the MPICC variable, as in ‘./configure MPICC=mpicc ...’.

If, instead of a special compiler command, you need to link a certain library, you can specify the link command via the MPILIBS variable, as in ‘./configure MPILIBS=-lmpi ...’. Note that if your MPI library is installed in a non-standard location (one the compiler does not know about by default), you may also have to specify the location of the library and header files via LDFLAGS and CPPFLAGS variables, respectively, as in ‘./configure LDFLAGS=-L/path/to/mpi/libs CPPFLAGS=-I/path/to/mpi/include ...’.