1. Using BLAS & LAPACK Debian packages



1.A Patch i-forbla.adb

Copy the i-forbla.adb file from the adainclude directory to your application sources directory.
Provided you install GNAT GPL in /opt/gnat2011
cp /opt/gnat2011/lib/gcc/x86_64-pc-linux-gnu/4.5.3/adainclude/i-forbla.adb sources/
Comment the pragma Linker_Options concerning the libgnalasup
package body Interfaces.Fortran.BLAS is
pragma Linker_Options ("-lgnala");
-- pragma Linker_Options ("-lgnalasup");
pragma Linker_Options ("-lm");
end Interfaces.Fortran.BLAS;


1.B Install the corresponding Debian packages

$ su -c "aptitude install liblapack-dev libblas-dev"


1.C Add the necessary switches to your application gpr project file


-a builder switch to force compilation of run time source file
   
package Builder is
for Default_Switches ("ada") use ("-a", [...]);
end Builder;

-llapack switch to link against it
   
package Linker is
for Default_Switches ("ada") use ("-llapack", [...]);
end Linker;

You are done !



2. Using Adacore libgnalasup GPL 2011 src package




2.A Build the libgnalasup GPL 2011 from sources


Download the gnalasup-gpl-2011-src.tgz tarball from http://libre.adacore.com/ using x86-linux 2011 paltform
Build the source
gnalasup-2011-src:$ make all INSTALL=/tmp/

2.A Copy the library to the corresponding directory

Copy the library in the GNAT GPL 2011 (x86_64) install directory.
Provided you install GNAT GPL in /opt/gnat2011
gnalasup-2011-src:$ su -c "cp libgnalasup.a /opt/gnat2011/lib/gcc/x86_64-pc-linux-gnu/4.5.3/libgnalasup.a"

You are done !