[Lazarus] Debugging shared libraries

Mark Morgan Lloyd markMLl.lazarus at telemetry.co.uk
Wed Sep 19 13:04:58 CEST 2012

ik wrote:
> On Wed, Sep 19, 2012 at 10:39 AM, Mark Morgan Lloyd
> <markMLl.lazarus at telemetry.co.uk> wrote:
>> Mark Morgan Lloyd wrote:
>>> I've developed a useful convention which allows me to either load a
>>> library on demand (via Dynlibs) or to link it statically. This combination
>>> allows me to use standard Lazarus debugging techniques to sort out most
>>> problems.
>>> However, yesterday's discussion about calling /from/ a dynamically-loaded
>>> library /into/ a program binary (other than the main program) raises an
>>> interesting question: can Lazarus+gdb be persuaded to trace into a shared
>>> library?
>> Does anybody have any thoughts on this? Martin?
> I haven't tried to do it with gdb, however, I'm a big "fan" of
> printing stuff into log files with much verbose as possible to figure
> out things.
> I hardly use a debugger, and usually use this technique.

When all else fails... :-)

OK, subsidiary question: is using a logfile or forcing a hypothetical 
dump (I don't even know what facilities are available these days), is 
there an easy way of making sense of an arbitrary variable without 
spending ages finding where its elements are declared in the LCL/FCL/RTL 

Mark Morgan Lloyd
markMLl .AT. telemetry.co .DOT. uk

[Opinions above are the author's, not those of his employers or colleagues]

More information about the Lazarus mailing list