You don't really _need_ wrappers to call these libraries, Sean;
that's the whole point of having compiled libraries.
For example, to call any of the LAPACK routines, just call them as
you always have. To link them into your code using, for example, xlf:
xlf90 -qextname myfort.f90 -Wl,-framework -Wl,vecLib
The -qextname tells xlf to add an underscore to external object names;
this lets it match the subroutine names in vecLib. The -W stuff tells
the linker to add the vecLib framework, which provides BLAS and
LAPACK. The *only* problem I had with this was using 4 specific
complex functions that return complex values; this has to do with how
gcc returns complex numbers vs. how xlf expects them. In this case,
you *do* need to write 4 short wrappers. Steve Powers posted how to
do this a few months back.
Yes, you'll need to do a little snooping around to figure out how to
get the names in fortran to match in C, etc. As Joe Koski mentioned,
you can find more info here:
http://developer.apple.com/hardware/ve/fortran.html
From Sean C. Garrick:
> I know I'm lazy. I'm sure someone will say its easy. However, I wish
> that Apple would provide libraries/subroutines (DSP, veclib, etc)
> that one could call from Fortran. This is scientific computing after
> all and a lot of people still use Fortran. The last time I looked at
> C/C++ was the summer of 92 when I was bored and wanted to learn a
> new language.
> Are there any efforts in this direction?
+-----------------------------------+
| Dallas Trinkle ph: 614.292.2887 |
| OSU Physics fax: 614.688.3871 |
+-----------------------------------+---------------------------+
| Q: How many IBM CPU's does it take to execute a job? |
| A: Four; three to hold it down, and one to rip its head off. |
+---------------------------------------------------------------+
_______________________________________________
scitech mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/scitech
Do not post admin requests to the list. They will be ignored.