catastrophic error: cannot open source file "mpi.h"

catastrophic error: cannot open source file "mpi.h"


We have SGI altix cluster running SUSE SLES 11 sp 2.

Installed -  Intel_Cluster_Studio_2013.0.028  .

I try to compile the software "LAMMPS"  ang get the error :    "catastrophic error: cannot open source file "mpi.h"  "  for many files.

Any suggestions how to proceed ?





4 post / 0 nuovi
Ultimo contenuto
Per informazioni complete sulle ottimizzazioni del compilatore, consultare l'Avviso sull'ottimizzazione

If you use the mpi wrappers such as mpiicc for Intel C, mpicpc for Intel C++, mpiifort for Fortran, the mpi.h include path is set for you.  If not, you must specify it in your command line or Makefile, but the MPI wrapper method is preferred.

Thank you Tim.

Could you write an example of the "mpi" lines in the Makefile ?

It's done with the usual linux style Include path option added to the compiler options string, e.g.


(supposing you are building for 64-bit/Intel64 mode).

but a correct Makefile would allow you to set mpiifort, mpiicpc, mpiicc as the compiler tools, so you don't need to change -I options.

Some customers prefer to remove mpif90, mpif77, mpicc, mpiCC from the Intel MPI installation and set those as symlinks so they don't need  to set the name of the compiler tools when changing MPI.  This will work only if you have correctly set up your system so that there is no conflicting MPI installation, such as you normally get when installing the MPI which comes with a linux distribution.

Accedere per lasciare un commento.