From: "Nasser M. Abbasi" <nma@12000.org>
Subject: Re: anyone seen this link error trying to link Ada program with blas and lapack? "cannot find -lgnalasup"
Date: Sat, 16 Oct 2010 00:30:59 -0700
Date: 2010-10-16T00:30:59-07:00 [thread overview]
Message-ID: <i9bkbk$l26$1@speranza.aioe.org> (raw)
In-Reply-To: i9bghg$9bm$1@speranza.aioe.org
On 10/15/2010 11:25 PM, Nasser M. Abbasi wrote:
> But I do not get the above error, but I do not have blas and lapack on
> windows. I need to figure now where to get them for windows and where to
> put them to make gnatmake happy (I think that will be
>
> C:\GNAT\2010\LIB
>
> (wonder why blas and lapack do not come with GNAT GPL distribution since
> there are needed to link against for building the new numeric stuff?
>
> >gnatmake main.adb -gnat05 -largs -L/usr/lib -lgnala -llapack -lblas
>
> gnatbind -x main.ali
> gnatlink main.ali -L/usr/lib -lgnala -llapack -lblas
> c:/gnat/2010/bin/../libexec/gcc/i686-pc-mingw32/4.3.6/ld.exe: cannot
> find -llapack
> collect2: ld returned 1 exit status
> gnatlink: error when calling C:\GNAT\2010\bin\gcc.exe
> gnatmake: *** link failed.
>
DONE !
Got it working, using gnat GPL 2010 with blas and lapack:
---------------
gnatmake main.adb -gnat05 -largs -L/usr/lib -lgnala -L/usr/lib/lapack.a
-L/usr/lib/blas.a
gnatbind -x main.ali
gnatlink main.ali -L/usr/lib -lgnala -L/usr/lib/lapack.a -L/usr/lib/blas.a
----------------------
This is what I did: I downloaded lapack 3.2.2. from
http://www.netlib.org/lapack/
and then build the tree from source under cygwin gcc, this generated 2
static libraries: blas.a and lapack.a, then copied these 2 files to
C:\GNAT\2010\LIB, then did the above gnatmake command. it worked!
I have no idea what the -lgnalasup is, but I think it is just an
internal packaging issue with the old gcc on cygwin with the Ada part.
The gcc that comes with GPL GNAT 2010 is
gcc --version
gcc (GCC) 4.3.6 20100603 for GNAT GPL 2010 (20100603)
while on cygwin, gcc is 4.3.4.
anyway, this whole thing with Ada 2005 and lapack and blas needs to be
sorted out. Since the new Ada 2005 numeric link to lapack, I think then
lapack libraries should be part of the installation of the ada compiler.
May be ask the user an option if they need to have these installed
during the compiler installation?
--Nasser
next prev parent reply other threads:[~2010-10-16 7:30 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-10-16 5:46 anyone seen this link error trying to link Ada program with blas and lapack? "cannot find -lgnalasup" Nasser M. Abbasi
2010-10-16 6:25 ` Nasser M. Abbasi
2010-10-16 7:30 ` Nasser M. Abbasi [this message]
2010-10-16 14:49 ` Simon Wright
2010-10-16 15:45 ` Nasser M. Abbasi
replies disabled
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox