comp.lang.ada
 help / color / mirror / Atom feed
From: sk <sk@noname.com>
To: "comp.lang.ada mail to news gateway" <comp.lang.ada@ada.eu.org>
Subject: Re: C code
Date: Fri, 07 Feb 2003 22:59:20 -0600
Date: 2003-02-07T22:59:20-06:00	[thread overview]
Message-ID: <mailman.9.1044680088.8221.comp.lang.ada@ada.eu.org> (raw)
In-Reply-To: OOV0a.2270$VQ4.19694@newsfep4-gui.server.ntli.net

Hi,

 > So all I need to do is to detect whether the library is an Ada lib or
 > not and if it is call Adainit upon load and adafinal upon close?

I guess you could, but I wouldn't.

For the DLLI interface, leave it to the called library user to know
whether the library containes "adainit" and "adafinal" because it
was developed in Ada with GNAT.

For an Ada library (GNAT developed since other compilers probably
do things differently) to be useful and transparent to C callers,
then one would try to associate the "adainit" and "adafinal" to the
automatic "init" and "fini" functions. These functions are called
by the dynamic-loader when you do a "dlopen()"

In general, I would not try to put "adainit" and "adafinal" in the
dlli package, let the user worry about it.

-- 
--
-- Merge vertically for real address
--
------------------------------------
-- s n p @ t . o
--  k i e k c c m
------------------------------------




  reply	other threads:[~2003-02-08  4:59 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2003-02-07 21:48 C code chris.danx
2003-02-08  4:59 ` sk [this message]
2003-02-08 16:08   ` Robert A Duff
  -- strict thread matches above, loose matches on Subject: below --
1996-06-30  0:00 Henry the mild mannered janitor
1996-06-30  0:00 ` Robert Dewar
1996-07-01  0:00 ` Pascal Obry
replies disabled

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