[parisc-linux] Re: hppa-linux libgcc

amodra@one.net.au amodra@one.net.au
Wed, 16 May 2001 21:10:20 +0930


On Wed, May 16, 2001 at 10:50:40AM +0200, Mark Kettenis wrote:
>    When building shared libs, hppa-linux needs to link against the static
>    version of libgcc to pick up millicode routines.  hppa-linux doesn't
>    currently support a shared libgcc because millicode functions cannot
>    be exported from a shared lib due to the ABI (linker and dynamic linker
>    really).  To successfully use a shared libgcc, we'd need to link against
>    _both_ libgcc_s.so and libgcc.a, which is a pain.
> 
> Did you consider using a linker script for libgcc_s.so instead of the
> usual symbolic link to libgcc_s.so.0?

No.  I mainly considered fixing the linker to support calls to millicode
in shared libs, but didn't get one of those round tuits.  :-(

>  The contents of libgcc_s.so
> would be something like:
> 
>   GROUP ( libgcc_s.so.0 libgcc.a )
> 
> Glibc uses a similar trick (take a look at /usr/lib/libc.so), and it
> seems to work fine.

Thanks.  That's a good idea.