[RFC] Adding libbacktrace

Andrew Burgess andrew.burgess@embecosm.com
Fri Sep 10 14:17:13 GMT 2021


* Nick Clifton <nickc@redhat.com> [2021-09-01 17:11:56 +0100]:

> Hi Andrew,
> 
> > I have a GDB patch series posted here:
> > that imports libbacktrace from the GCC repository into the
> > binutils-gdb repository, this would introduce a new toplevel directory
> > bintuils-gdb/libbacktrace/.
> 
> If you have not done so, you may also want to update the src-release.sh
> script at the toplevel to add libbacktrace to the list of directories.
> (See line 96).

Hi Nick,

Good point about updating src-release.

I had a go, and ran into a few issues.  Not sure if you can offer any
advice...

So I added libbacktrace to GDB_SUPPORT_DIRS (line 330), this seems to
be how stuff like gdbsupport are handled.

However, during the call to do_proto_toplev we at one point do:

  $MAKE configure-host configure-target ....

and this results in us trying to configure a target version of
libbacktrace, which fails as there's no target compiler installed, and
indeed libbacktrace is defined as a target module (as well as a host
module).

Without any of my libbacktrace changes in place the call to
configure-target does nothing, which is slightly odd as zlib is
defined as both a host and target module too, and this is include in
the binutils-gdb repo.  However, in the generated Makefile, for some
reason that I don't understand, the rule to build zlib as a target
module has been disabled.

So, I can see two possible solutions here I think, one would be to
remove the call to configure-target from src-release.sh - surely we
don't expect to be building target libraries for binutils-gdb, right?

Or, I can try to figure out what causes the configure/build rules for
zlib (as a target module) to be disabled, and do the same thing for
libbacktrace.

Sorry if the above is a little vague, I'm not 100% sure I fully
understand everything that's going on with src-release.

Thanks,
Andrew


More information about the Binutils mailing list