This is the mail archive of the
fortran@gcc.gnu.org
mailing list for the GNU Fortran project.
Re: Help requested from a user
- From: Paul Thomas <paulthomas2 at wanadoo dot fr>
- To: yunlei at uwm dot edu
- Cc: fortran at gcc dot gnu dot org
- Date: Tue, 05 Dec 2006 00:23:26 +0100
- Subject: Re: Help requested from a user
- References: <1165264193.45748541b9592@panthermail.uwm.edu>
yunlei@uwm.edu wrote:
I am not entirely sure what you mean:
To whom it may help:
I am wondering if the Gfortran can be interfaced with MATLAB? In other words,
how can I invoke Gfortran compiler in MATLAB to compile f90 fortran codes in
MATLAB?
If you mean, can I use gfortran to make mex files:
Yes, I think so; at very least for Linux and probably for Windows too.
The mex function allows you to link object files into a mex file, as
long as you specify that they are fortran - look in the online help for
'mex'. I do not know of any reason why this should not work for
gfortran. I'll give it a try myself tomorrow.
If you just want to invoke the compiler:
Yes, no problem - use the 'system' function.
Cheers
Paul