This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: detecting non-PIC in shared lib on Darwin?
- From: "Richard Guenther" <richard dot guenther at gmail dot com>
- To: "Jack Howarth" <howarth at bromo dot msbb dot uc dot edu>
- Cc: pinskia at physics dot uc dot edu, gcc at gcc dot gnu dot org
- Date: Thu, 27 Apr 2006 10:22:34 +0200
- Subject: Re: detecting non-PIC in shared lib on Darwin?
- References: <20060427014543.139DE11003D@bromo.msbb.uc.edu>
On 4/27/06, Jack Howarth <howarth@bromo.msbb.uc.edu> wrote:
> Andrew,
> What on earth would make you think that the linker on Darwin would
> reject non-PIC code in linking a shared library. The linker on Linux
> doesn't do any such thing
It does (at least on some archs):
/usr/lib64/gcc/x86_64-suse-linux/4.1.0/../../../../x86_64-suse-linux/bin/ld:
/usr/lib64/gcc/x86_64-suse-linux/4.1.0/../../../../lib64/libadns.a(event.o):
relocation R_X86_64_32 against `a local symbol' can not be used when
making a shared object; recompile with -fPIC
/usr/lib64/gcc/x86_64-suse-linux/4.1.0/../../../../lib64/libadns.a:
could not read symbols: Bad value
collect2: ld returned 1 exit
status
Richard.