Shared library annoyance with gcc-3_0-branch

Richard Henderson rth@redhat.com
Tue Feb 20 01:53:00 GMT 2001


On Tue, Feb 20, 2001 at 12:45:49AM -0500, Daniel Jacobowitz wrote:
> Could we somehow get away with not linking shared libraries to the
> shared libgcc unless they used C++, and requiring dynamic libgcc in
> applications which wished to have correct exception handling and use
> C++ shared libraries?

Yes, we could.  The problem is identifying these situations automatically.
It wouldn't be too bad if we could just presume ELF, but coming up with a
solution that works everywhere has eluded me.

Do recall that you can *always* use --static-libgcc to override the default.

> Also, my understanding is that this entire issue arises from portions
> of libgcc for which there must only be one copy.  But that doesn't
> include all of libgcc, does it?  Could we somehow divide those two -
> use a static libgcc for things which can be private?

*shrug* We could, but what would be the point?  You don't have
to actually use any symbol from a shared library to generate a
dependance on it.  The dependance it added by its mere presence
on the link line.


r~



More information about the Gcc mailing list