Packaging lapack, blas, etc

James R. Phillips antiskid56-cygwin@yahoo.com
Wed Jan 19 00:46:00 GMT 2005


Hi,

I am looking at packaging numerical libraries such as lapack and blas for use
by a cygwin version of gnu octave.  I would like some guidance on a couple
issues:

1) I anticipate developing the libraries in a dll format, and there may be
multiple versions, optimized for different processor architecture.  What is the
best way to support (ie select from) multiple installed library versions at run
time?  Simply make certain the correct version is copied to /usr/bin, or add
the path to the correct version to the $PATH environmental string?  Or
something else?

2) I know how to use dlltool to generate export libraries, but I'm not certain
that is really necessary.  It is difficult for me to piece together the bits of
information from various web pages and man pages, but the implication is that
it can all be done with gcc and ld.  Is this so?  My script to create the the
blas dll from the static library libblas_static.a is 

dlltool --export-all-symbols -e libblas.exp.o -l libblas.dll.a -D libblas.dll
libblas_static.a
gcc -shared libblas.exp.o libblas_static.a -lg2c -o libblas.dll

This works, but perhaps there is a technically more correct, or efficient, or
elegant way?

Any thoughts on these issues would be appreciated.

James R. Phillips



More information about the Cygwin-apps mailing list