From: Ludovic Brenta on
Erik J Pessers writes:
> Dear all,
>
> Trying GNAT2007 iso the GCC GNAT compiler poses one issue: the Ada
> code I'm using relies on the ADACL library, and in particular the CG
> (garbage collection) modules. These seem to depend on a routine
> "Deep_Tag_Finalize" which is available in the Debian distro
> gcc-gnat compiler, but does not seem to be available in Gnat2007
> (scanned the adainclude directory but found no match).

Deep_Tag_Finalize was removed during the First Giant Merge of AdaCore
to the GCC sources on October 21, 2003 (Subversion commit 72751).

Therefore I infer that the Debian distro you speak of is Debian 3.1
"Sarge" where the compiler is gnat 3.15p. All versions after that
(i.e. gnat-4.1 in Debian 4.0 "Etch") lack Deep_Tag_Finalize.

Unfortunately you are probably not going to like my advice: rewrite
the GC part of AdaCL to match the more recent versions of GCC and GNAT
GPL Edition.

--
Ludovic Brenta.
From: Ludovic Brenta on
Erik J Pessers writes:
> Re Debian: I'm using Debian Lenny, with gnat-4.1 (4.1.2-8) and this
> *is* (still?) providing Deep_Tag_Finalize; I suppose that will soon
> change then.

Ah, I was wrong then. The procedures were removed much more recently
than I initially thought. The culprit is:

2007-04-06 Robert Dewar <dewar(a)adacore.com>
Thomas Quinot <quinot(a)adacore.com>
Ed Schonberg <schonberg(a)adacore.com>
Bob Duff <duff(a)adacore.com>
[...]
* s-finimp.ads, s-finimp.adb (Move_Final_List): New procedure to move
a return statement's finalization list to the caller's list, used for
build-in-place functions with result type with controlled parts.
Remove no longer used entities.
[...]

This is revision 123558 in Subversion. The next version of GCC
without these procedures will be 4.3.0 (not released yet).

> I'll follow up on the advise to delve into it: the situation may
> change apparently. Not the most easy part of Ada to delve into
> though. We'll see.

Since the procedures you need were removed because they were "unused",
it may be possible to reintroduce them into the compiler. However the
risk is that they do not work with Ada 2005's interfaces.

--
Ludovic Brenta.
From: Stephen Leake on
Erik J Pessers <vt6145886(a)tele2allin.be> writes:

> Trying GNAT2007 iso the GCC GNAT compiler poses one issue: the Ada
> code I'm using relies on the ADACL library, and in particular the CG
> (garbage collection) modules. These seem to depend on a routine
> "Deep_Tag_Finalize" which is available in the Debian distro
> gcc-gnat compiler, but does not seem to be available in Gnat2007
> (scanned the adainclude directory but found no match).
>
> Compiling using Gnat2007 results in:
>
> bash-3.1$ gnatmake utils-booleans-dsc
> gcc -c -gnato -fstack-check -O2 utils-booleans-dsc.adb
> ...
> gcc -c -gnato -fstack-check -O2 adacl.ads
> gcc -c -gnato -fstack-check -O2 adacl-gc.adb
> adacl-gc.adb:105:13: "Deep_Tag_Finalize" not declared in \
> "Finalization_Implementation"
> gnatmake: "adacl-gc.adb" compilation error

Since "Finalization_Implementation" is _not_ a standard Ada package,
but is a compiler-specific package, the best solution is for ADACL to
stop using it.

Why does ADACL need it?

Alternately, you may be able to simply copy the source for
Deep_Tag_Finalize, and put it in an ADACL package.

--
-- Stephe
From: Simon Wright on
Stephen Leake <stephen_leake(a)stephe-leake.org> writes:

> Since "Finalization_Implementation" is _not_ a standard Ada package,
> but is a compiler-specific package, the best solution is for ADACL
> to stop using it.
>
> Why does ADACL need it?

I suppose because hooking in to garbage collection is pretty
compiler-specific?
From: Martin Krischik on
Simon Wright wrote:

> Stephen Leake <stephen_leake(a)stephe-leake.org> writes:
>
>> Since "Finalization_Implementation" is _not_ a standard Ada package,
>> but is a compiler-specific package, the best solution is for ADACL
>> to stop using it.
>>
>> Why does ADACL need it?
>
> I suppose because hooking in to garbage collection is pretty
> compiler-specific?

Indeed - that's why you can switch off garbage collection ;-) . The next
AdaCL version won't use Finalization_Implementation when GC has been
switched of.

As for GCC 4.3 - I have to see how I fix that.

Martin
--
mailto://krischik(a)users.sourceforge.net
Ada programming at: http://ada.krischik.com