comp.lang.ada
 help / color / mirror / Atom feed
From: Martin Krischik <martin@krischik.com>
Subject: Re: Plugins/Dynamic Libraries
Date: Thu, 11 Nov 2004 14:59:50 +0100
Date: 2004-11-11T14:59:50+01:00	[thread overview]
Message-ID: <7054078.maftqStDp2@linux1.krischik.com> (raw)
In-Reply-To: 41934335$0$9740$ba620e4c@news.skynet.be

Adrien Plisson wrote:

> Martin Krischik wrote:
> 
>> A current version of GNAT and GPS can do DLLs out of the box. Just Add
>> the
>> 
>>     for Library_Dir         use  ...;
>>     for Library_Name        use ...;
>>     for Library_Kind        use ...;
>>     for Library_Version     use ....;
> 
> these are static bindings done at compile time. the resulting executable
> contains a segment which tells the system to load the given library and
> relocate symbols in the process space. but if the library is not present
> at application startup, the application does not start: the system is
> responsible for loading and checking the dll. (at least it works this
> way under windows).
> 
> Andrew was talking about dynamic bindings at runtime. that is calling a
> function which loads the dll, whose name is contained in a variable. if
> at application startup the library does not exists, it is not a problem:
> the programmer is responsible for loading and checking the dll.
> 
>> to your project file and all needed steps will be done for you. Why there
>> is no checkbox in GPS I don't know. For Windows you need the
>> "experimental" MinGW GNAT based on GCC 3.4.2. Older GNAT's can do Linux
>> DLLs only.
> 
> it seems GNAT 3.15p for windows is doing DLLs (according to the doc, i
> had no time to test it).

Last time I checked in GNAT 3.15p you had to read 2 pages of documentation
and then call dlltool 3 times with all sorts of wacky options while in GCC
3.4.2 you just tell the project manager you want a DLL and then GNAT does
it all for you (incl. calling dlltool).

With Regards

Martin
-- 
mailto://krischik@users.sourceforge.net
http://www.ada.krischik.com



  parent reply	other threads:[~2004-11-11 13:59 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2004-11-10 20:46 Plugins/Dynamic Libraries Andrew W
2004-11-11  8:28 ` Martin Krischik
2004-11-11 10:49   ` Adrien Plisson
2004-11-11 12:42     ` Frank Piron
2004-11-11 13:59     ` Martin Krischik [this message]
2004-11-11 16:16       ` Pascal Obry
2004-11-12  0:00   ` David Botton
2004-11-12 18:17     ` Pascal Obry
2004-11-11 10:34 ` Adrien Plisson
2004-11-12  0:12   ` David Botton
2004-11-12  9:53     ` Adrien Plisson
2004-11-14  3:38       ` David Botton
2004-12-04 14:27 ` Lionel Draghi
replies disabled

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