Linux ABI documents and powerpc supplements.

Michael Schmitz schmitz at opal.biophys.uni-duesseldorf.de
Wed Jan 5 21:19:30 EST 2000


> > -shared is used to *create* a shared library. You need -Bdynamic in
> > order to force the executable to be linked against shared libraries.
> 
> I think you are confusing the ld arguments and the gcc arguments.  ld uses -Bdynamic and -Bstatic

I think you misread the documentation. It has always been my understanding
that -static explicitly prevents linking to shared libraries (which is
otherwise the default), wheras -shared prepares an object to be used as
part of a shared library later:

> `-shared'
>      Produce a shared object which can then be linked with other
>      objects to form an executable.  Not all systems support this
>      option.  You must also specify `-fpic' or `-fPIC' on some systems
>      when you specify this option.

That pretty much states it makes no sense using -shared in the final
linkage step for a binary.

	Michael


** Sent via the linuxppc-dev mail list. See http://lists.linuxppc.org/





More information about the Linuxppc-dev mailing list