comp.lang.ada
 help / color / mirror / Atom feed
From: Ludovic Brenta <ludovic@ludovic-brenta.org>
Subject: Symbolic tracebacks on Debian (Was: About static libraries and Debian policy)
Date: Thu, 20 May 2010 09:20:25 +0200
Date: 2010-05-20T09:20:25+02:00	[thread overview]
Message-ID: <87sk5navk6.fsf_-_@ludovic-brenta.org> (raw)
In-Reply-To: 85j595F1lqU1@mid.individual.net

Björn Persson writes on comp.lang.ada:
> Ludovic Brenta wrote:
>
>> Traceback is always available, either in symbolic or numeric form.  To
>> get the symbolic form, you need the -dbg package installed.
>
> Is that libgnat-4.3-dbg that needs to be installed (on Etch)?

Yes.  More precisely, libgnat-4.1-dbg on Etch, libgnat-4.3-dbg on Lenny
and libgnat-4.4-dbg on Squeeze.  If the code names are too confusing,
version numbers are useful, too :)

> I can't get symbolic traceback to work; I get Storage_Error
> instead. Below is my test program and how I compile and run it. Do you
> have any idea of what's wrong?

I investigated and discovered this is a genuine bug in the patched
convert_addresses which now expects an additional argument; I never
noticed this upstream change:

    2007-04-06  Olivier Hainque  <hainque@adacore.com>
    
    	* adaint.c:
    	(convert_addresses): Adjust prototype and dummy definition to expect an
    	 extra file_name argument.
    
    	* gmem.c (__gnat_convert_addresses): Wrapper to convert_addresses,
    	filling the now expected file_name argument with the appropriate
    	argv[0] expansion.
    	(__gnat_gmem_a2l_initialize, __gnat_gmem_read_next_frame): Use it.
    	(tracebk): Array of void * instead of char *, corresponding to what
    	 convert_addresses expects.
    	(exename): New static global, to hold the executable file name to be
    	used in all convert_addresses invocations.
    	(gmem_read_backtrace, __gnat_gmem_symbolic): Account for tracebk type
    	change.
    	(__gnat_gmem_a2l_initialize): Resolve exename.
    	(__gnat_convert_addresses): Use exename as the convert_addresses
    	file_name argument.
    
    	* g-trasym.adb (Symbolic_Traceback): Adjust signature of imported
    	"convert_addresses", now expecting a filename argument. Import the
    	necessary entities to compute the filename to use and pass it to
    	convert_addresses.

(Subversion revision 123544 on the trunk).  Consequently I never
adjusted convert_addresses.c accordingly.

On the one hand, this is quite embarrassing as it means that both
gnat-4.3 and gnat-4.4 are broken in this respect.  On the other hand,
since nobody noticed or reported this problem before you and gnat-4.3
has been in Debian since 2008-01-30, I'm starting to wonder whether
symbolic tracebacks are all that useful.

Nevertheless, this deserves a bug in the Debian bug tracking system and
a fix before the release of Squeeze.  Thanks for reporting!

-- 
Ludovic Brenta.



  reply	other threads:[~2010-05-20  7:20 UTC|newest]

Thread overview: 37+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-05-14 13:16 About static libraries and Debian policy Dmitry A. Kazakov
2010-05-14 14:57 ` sjw
2010-05-14 15:29   ` Dmitry A. Kazakov
2010-05-14 18:43     ` Ludovic Brenta
2010-05-14 19:54       ` Dmitry A. Kazakov
2010-05-14 20:38         ` Ludovic Brenta
2010-05-15  7:46           ` Dmitry A. Kazakov
2010-05-15 10:07             ` Ludovic Brenta
2010-05-15 11:07       ` Simon Wright
2010-05-15 21:48         ` Ludovic Brenta
2010-05-16 10:13           ` Simon Wright
2010-05-16 10:31             ` Ludovic Brenta
2010-05-19 21:59       ` Björn Persson
2010-05-20  7:20         ` Ludovic Brenta [this message]
2010-05-20  8:38           ` Symbolic tracebacks on Debian (Was: About static libraries and Debian policy) Alex R. Mosteo
2010-05-21 12:26             ` Ludovic Brenta
2010-05-25  8:39               ` Symbolic tracebacks on Debian Ludovic Brenta
2010-05-20 14:04           ` Symbolic tracebacks on Debian (Was: About static libraries and Debian policy) Dmitry A. Kazakov
2010-05-21  8:52           ` Symbolic tracebacks on Debian Stephen Leake
2010-05-22 11:03             ` (see below)
2010-05-22 11:25               ` Simon Wright
2010-05-22 21:37                 ` (see below)
2010-05-23 13:28                 ` Stephen Leake
2010-05-23 15:52                   ` Simon Wright
2010-05-23 18:35                     ` (see below)
2010-05-23 19:46                       ` Simon Wright
2010-05-24  9:04                         ` Stephen Leake
2010-05-24 19:14                           ` Simon Wright
2010-05-25  2:13                             ` Stephen Leake
2010-05-25  9:02                               ` Alex R. Mosteo
2010-05-25 19:16                               ` Simon Wright
2010-05-26  7:30                                 ` Stephen Leake
2010-05-24  9:03                   ` Stephen Leake
2010-05-22 11:30               ` Yannick Duchêne (Hibou57)
2010-05-22 13:20             ` Björn Persson
2010-05-22 13:56               ` Dmitry A. Kazakov
2010-05-22 12:53           ` Symbolic tracebacks on Debian (Was: About static libraries and Debian policy) Björn Persson
replies disabled

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