A patch for PIC default

H.J. Lu hjl@lucon.org
Tue Nov 17 20:03:00 GMT 1998


> > PIC is more a calling convention. It is possible for different
> > OSes for the same CPU not to use PIC in the static binary. Depending
> > on the calling convention, you have to add -DPIC when compiling the
> > static binary for one OS and not to add it for the other. I believe
> > MIPS is such an example.
> 
> This will only have an effect for assembler files.  There are not many
> of them.  For those which are there one could create separate version,
> maybe in a subdir named after this calling convention:
> 

Glibc assumes PIC means for shared libraries. It is not always correct.
PIC is a calling convention. It can be used for shared libraries as
well as static libraries. That is what Ralf tried to fix. He used
SHARED for shared libraries. Otherwise, you will get confused yourself.



-- 
H.J. Lu (hjl@gnu.org)



More information about the Libc-hacker mailing list