Newsgroups: comp.lang.fortran,comp.parallel.mpi
From: henry@twinpeaks.torolab.ibm.com (Henry Zongaro)
Reply-To: zongaro@vnet.ibm.com
Subject: Re: How to use F77 library in Fortran90 ?
Organization: IBM Toronto Laboratory
Date: 21 Jun 1996 15:33:27 GMT
Message-ID: <4qefc7$ddk@tornews.torolab.ibm.com>

In article <4qe5oo$t4k@tornews.torolab.ibm.com>, henry@twinpeaks.torolab.ibm.com (Henry Zongaro) writes:
|> In article <4qcsqv$bd0@hkusuc.hku.hk>, cmwoo@hkusu8.hku.hk (Woo Chat Ming) writes:
|> |>     I have written a Fortran 90 program in IBM RS6000. Now, I want to
|> |> use a library called MPI and make some calls to it. 
|> |>     However, the header file "mpif.h" of the library is written in Fortran 77. 
|> |> After I "include" it into my program, my compiler(xlf90) generates a lot
|> |> of errors. 
|> |>        
|> |>     Do anyone know how to use fortran 77 libraries in fortran 90 ? And
|> |> how to include F77 header files in Fortran 90 ?
|> 
|> I just responded to this one in comp.parallel.mpi, but in case you're more
|> likely to read comp.lang.fortran, here it is again:
|> 
|> mpif.h is written using fixed source form, but the default source form for the
|> xlf90 command is free source form; try compiling using the -qfixed option.
|> 
|> Hope this helps,

One other thing I should have recommended is using the 'mpxlf' command, which
is provided with the Parallel Environment.  This invokes xlf and binds in the
right libraries, etc. that are needed to use MPI.

Thanks,

Henry
-------------------------------------------------------------------------------
Henry Zongaro      XL Fortran/XL HPF Compiler Development
IBM SWS Toronto Lab   Tie Line 778-6044  Phone (416) 448-6044
Internet id: zongaro@vnet.ibm.com

