This is the mail archive of the
binutils@sourceware.org
mailing list for the binutils project.
Re: [PATCH] PR gold/19177: gold doesn't handle R_386_GOT32X relocation without base register
- From: "H.J. Lu" <hjl dot tools at gmail dot com>
- To: Cary Coutant <ccoutant at gmail dot com>
- Cc: Binutils <binutils at sourceware dot org>
- Date: Wed, 28 Oct 2015 12:43:53 -0700
- Subject: Re: [PATCH] PR gold/19177: gold doesn't handle R_386_GOT32X relocation without base register
- Authentication-results: sourceware.org; auth=none
- References: <20151028114242 dot GA27290 at gmail dot com> <CAJimCsGkg74J5uCzkn=EDguo_3rCkQH254PbOCsHkk3Nxx2_rQ at mail dot gmail dot com>
On Wed, Oct 28, 2015 at 8:40 AM, Cary Coutant <ccoutant@gmail.com> wrote:
>> + if(gsym)
>> + gold_error_at_location(relinfo, relnum, rel.get_r_offset(),
>> + _("unexpected reloc %u against global symbol %s without base register in object file when making a PIC output"),
>> + r_type, gsym->demangled_name().c_str());
>> + else
>> + gold_error_at_location(relinfo, relnum, rel.get_r_offset(),
>> + _("unexpected reloc %u against local symbol without base register in object file when making a PIC output"),
>> + r_type);
>
> s/making a PIC output/generating a position-independent output file/
>
> (This could also be PIE, right?)
>
That is correct. We can't use R_386_GOT32 and R_386_GOT32X
relocations without base register in PIE since we don't know what
GOT address is.
--
H.J.