This is the mail archive of the libc-hacker@sourceware.cygnus.com mailing list for the glibc project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: A patch for PIC default


> > 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)


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]