comp.lang.ada
 help / color / mirror / Atom feed
From: "Nasser Abbasi" <nma@12000.org>
Subject: Re: GNAT2007: Link error on windows when using Ada.Numerics.Generic_Real_Arrays, SOLVE.
Date: Fri, 10 Aug 2007 16:02:25 -0700
Date: 2007-08-10T16:02:25-07:00	[thread overview]
Message-ID: <786vi.101619$zz2.23441@newsfe12.phx> (raw)
In-Reply-To: V3Xui.85757$zz2.14818@newsfe12.phx


"Nasser Abbasi" <nma@12000.org> wrote in message 
news:V3Xui.85757$zz2.14818@newsfe12.phx...
> This in windows XP. I get this link error when gnatmake on this file: (ps. 
> I use cygwin bash shell to invoke commands, easier than DOS, but 
> otherwise, this is windows installation of GNAT2007.)
>
> GNATMAKE GPL 2007 (20070405-41)
> Copyright 1995-2007, Free Software Foundation, Inc.
>
> ----- error.adb---------
> with Ada.Numerics.Generic_Real_Arrays;
>
> procedure error is
>
>   package myReals is new Ada.Numerics.Generic_Real_Arrays(Float);
>   use myReals;
>
>   nElements: constant integer:=6;
>   A: Real_Matrix(1..nElements,1..nElements):=(others => (others => 0.0));
>   b: Real_Vector(1..nElements):=(Others=>0.0);
>
>   begin
>       b:=solve(A,b);
>
> end error;
> ------------------ end error.adb--------------
>
> $ which gnatmake
> /cygdrive/c/GNAT/2007/bin/gnatmake
>
> $ gnatmake error.adb
> gnatbind -x error.ali
> gnatlink error.ali
> .\error.o:error.adb:(.text+0x47c6): undefined reference to `sgetri_'
> .\error.o:error.adb:(.text+0x4dd5): undefined reference to `sgetrf_'
> .\error.o:error.adb:(.text+0x647b): undefined reference to `sgemv_'
> collect2: ld returned 1 exit status
> gnatlink: error when calling c:\GNAT\2007\bin\gcc.exe
> gnatmake: *** link failed.
>
> Nasser
>

Ok, I needed to link explicitly with blas and lapack.  Which I did, and the 
program linked ok.

But I have a question on the link using gnatmake, which I will ask in a new 
post.

Nasser 





      reply	other threads:[~2007-08-10 23:02 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-08-10 10:27 GNAT2007: Link error on windows when using Ada.Numerics.Generic_Real_Arrays, SOLVE Nasser Abbasi
2007-08-10 23:02 ` Nasser Abbasi [this message]
replies disabled

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox