Python events.new_objfile with "set auto-solib-add off"

Srinath Avadhanula via Gdb <[email protected]>
Newsgroups gmane.comp.gdb.devel
Message-ID <CAKMNpPHmaVy+tQYZK6J0-SdRF6k020S69Tq7qKYa8YEHDEA7Yw@mail.gmail.com>
Hi,

We have an application which (unfortunately) loads a ton of shared
libraries. Typically, we are only interested in debugging a small subset of
these libraries. We use a combination of "set auto-solib-add off" and
"sharedlibrary" commands to only load a selected set of symbols.

However, the "sharedlibrary" command can only be issued after the
executable actually loads the shared library. This is a bit of an annoyance.

I was hoping that I could therefore use the Python events.new_objfile
listener to issue a sharedlibrary command if we detect that a library of
interest is loaded. However, it looks like this particular event just does
not fire if "set auto-solib-add off" is set.

Is there a Python API which I can use to get notified that a new shared
library is loaded by the inferior (even if no symbols have been loaded for
that shared library)?

Regards,
Srinath
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.