trying to compile fortran code that uses mpi - linking issues?

view full story

http://ubuntuforums.org – Hi, I am trying to compile a fortran code which uses mpich2. I am using gfortran. Since originally I was getting the error Error: Can't open included file 'mpif.h' I have added -I/usr/lib/mpich2/include/ which has gotten rid of that error, and now I have errors such as these: undefined reference to `mpi_send_' undefined reference to `mpi_recv_' . . . As a side note I'm also getting a warning: Warning: Blanket SAVE statement at (1) follows previous SAVE statement But I'm guessing that is unrelated to my undefined reference problem. Does anyone know how to fix this? Thanks. (Hardware)