This is the mail archive of the
binutils@sourceware.org
mailing list for the binutils project.
Re: RFC: binutils PATCH: Set e_type to ET_EXEC for -pie -Ttext-segment=0xXXX
- From: Michael Matz <matz at suse dot de>
- To: "H. Peter Anvin" <hpa at zytor dot com>
- Cc: "H.J. Lu" <hjl dot tools at gmail dot com>, Binutils <binutils at sourceware dot org>, Jiri Kosina <jkosina at suse dot cz>, LKML <linux-kernel at vger dot kernel dot org>, Josh Boyer <jwboyer at redhat dot com>
- Date: Tue, 10 Dec 2013 14:28:48 +0100 (CET)
- Subject: Re: RFC: binutils PATCH: Set e_type to ET_EXEC for -pie -Ttext-segment=0xXXX
- Authentication-results: sourceware.org; auth=none
- References: <CAMe9rOqLzLkRM5J7s22fOob-nui3Lx67TMAswCtmSu+2QdhZrw at mail dot gmail dot com> <52A68922 dot 6020800 at zytor dot com> <CAMe9rOpaTd_owNvBdDWTpUZT3LQkAozYdXGG9PnGT-Dp3Nk1Og at mail dot gmail dot com> <bacb408c-acb7-4c4f-937f-2288e4d9ec04 at email dot android dot com>
Hi,
On Mon, 9 Dec 2013, H. Peter Anvin wrote:
> Where do the _32 and _32S relocations come from? Are we mixing multiple
> things inside -pie?
Without -pie it uses the non-shared (and non-PIE) crt startup files, and
they expect the (absolute) addresses they care about to fit into 32bit :-/
You need the shared startup files to put the executable above 4G.
Ciao,
Michael.