Hi Anthony<br>it gave me this message:<br>The Open MPI wrapper compiler was unable to find the specified compiler<br>gfortran in your PATH.<br><br>Note that this compiler was either specified at configure time or in<br>one of several possible environment variables.<br>
<br>can i change any variable of mpif90 to appoint to ifort rather than gfortran? <br><br><br><div class="gmail_quote">On Wed, Apr 27, 2011 at 8:33 PM, Anthony Chan <span dir="ltr"><<a href="mailto:chan@mcs.anl.gov">chan@mcs.anl.gov</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin: 0pt 0pt 0pt 0.8ex; border-left: 1px solid rgb(204, 204, 204); padding-left: 1ex;"><br>
You should use mpif90 to compile and link your f90 program.<br>
mpif90 will take care of include path and linking of various<br>
MPICH2 internal libraries...<br>
<div><div></div><div class="h5"><br>
----- Original Message -----<br>
> Dear there<br>
><br>
> I have installed MPICH2-1.3.2p1 on ubuntu and the installation was<br>
> ended and<br>
> tested successfully, When i try to compile a parallel program with<br>
> ifort,<br>
> it gives me error. i use this command for compiling:<br>
> ifort heat_mpi.f90 hi.out -o<br>
><br>
> the errors that appear are as follows:<br>
> /tmp/ifortYgvRCy.o: In function `MAIN__':<br>
> heat_mpi.f90:(.text+0x1f8): undefined reference to `mpi_init_'<br>
> heat_mpi.f90:(.text+0x214): undefined reference to `mpi_comm_rank_'<br>
> heat_mpi.f90:(.text+0x230): undefined reference to `mpi_comm_size_'<br>
> heat_mpi.f90:(.text+0x255): undefined reference to `mpi_wtime_'<br>
> heat_mpi.f90:(.text+0x1166): undefined reference to `mpi_send_'<br>
> heat_mpi.f90:(.text+0x11ce): undefined reference to `mpi_recv_'<br>
> heat_mpi.f90:(.text+0x1236): undefined reference to `mpi_send_'<br>
> heat_mpi.f90:(.text+0x1294): undefined reference to `mpi_recv_'<br>
> heat_mpi.f90:(.text+0x149f): undefined reference to `mpi_wtime_'<br>
> heat_mpi.f90:(.text+0x1590): undefined reference to `mpi_finalize_'<br>
> /tmp/ifortYgvRCy.o: In function `update_':<br>
> heat_mpi.f90:(.text+0x27f9): undefined reference to `mpi_send_'<br>
> heat_mpi.f90:(.text+0x2858): undefined reference to `mpi_recv_'<br>
> heat_mpi.f90:(.text+0x28b7): undefined reference to `mpi_send_'<br>
> heat_mpi.f90:(.text+0x2911): undefined reference to `mpi_r<br>
><br>
> i have included the mpif.h file in the same directory and i added the<br>
> paths<br>
> of mpich2/include and mpich2/lib to the PATH variable. should i change<br>
> some<br>
> thing in my command? or do some thing to define the mpich2 to ifort. I<br>
> had<br>
> the ifort installed befor mpich2.<br>
><br>
> thanks,<br>
> Ali.<br>
><br>
</div></div>> _______________________________________________<br>
> mpich-discuss mailing list<br>
> <a href="mailto:mpich-discuss@mcs.anl.gov">mpich-discuss@mcs.anl.gov</a><br>
> <a href="https://lists.mcs.anl.gov/mailman/listinfo/mpich-discuss" target="_blank">https://lists.mcs.anl.gov/mailman/listinfo/mpich-discuss</a><br>
_______________________________________________<br>
mpich-discuss mailing list<br>
<a href="mailto:mpich-discuss@mcs.anl.gov">mpich-discuss@mcs.anl.gov</a><br>
<a href="https://lists.mcs.anl.gov/mailman/listinfo/mpich-discuss" target="_blank">https://lists.mcs.anl.gov/mailman/listinfo/mpich-discuss</a><br>
</blockquote></div><br>