Adrian Victor Crisciu acrisciu at
Sat Aug 23 22:45:48 UTC 2014

After 3 days of frustrating trials and errors, I managed to install the new
hmatrix package on Slackware 13.1. I post this message in case anyone else
hits the same problem, as the process requires some alteration of the
standard build process of ATLAS, LAPACK, hmatrix and hmatrix-gsl. The
following steps assume that LAPACK is built against an optimized ATLAS

1.) By default, ATLAS builds only static libraries. However, hmatrix needs
shared objects, so ATLAS should be configured with the --share option and,
after the build is complete, the commands "make shared" and/ore "make
ptshared" need to be issued in BUILDDIR/lib

2.) LAPACK also buils by default only static libraries and, for the same
reason as above, we need position independent conde in ALL the objects in
liblapack. In order to do this we need to
      2.1.) Add -fPIC to OPTS, NOOPT and LOADOPT in LAPACKROOT/
       2.2.) Change the BLASLIB macro in the same file to point to the
optimized tatlas (os satlas) library
      2.3.) Add the target to SRC/Makefile:
              ../ $(ALLOBJ)
                        gfortran -shared -W1 -o $@ $(ALLOBJ)
(This step is a corected version of

3.) Change the extra-libraries line in hmatrix.cabal to read:
      extra-libraries: tatlas lapack

4.) Change the extra-library line in hmatrix-gsl to read:
       extra-libraries: gslcblas gsl

Again, this procedure worked for may Slackware 13.1 linux box, but I think
it will work on any decent linux machine.

Thanks everyone for your time and useful comments!
Adrian Victor.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <>

More information about the Glasgow-haskell-users mailing list