gnat_math_extensions_1.1.0_e1f68c35/test/lapack_version.adb

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
with Interfaces.Fortran; use Interfaces.Fortran;
function LAPACK_Version return Natural
is
   Major, Minor, Patch : Fortran_Integer;
   procedure Ilaver (Major : out Fortran_Integer;
                     Minor : out Fortran_Integer;
                     Patch : out Fortran_Integer)
     with
       Import,
       Convention => Fortran,
       External_Name => "ilaver_";
begin
   Ilaver (Major, Minor, Patch);
   return Natural (Major * 10000 + Minor * 100 + Patch);
end LAPACK_Version;