[Aboriginal] PIE

David Halls dahalls at gmail.com
Mon May 18 23:43:34 PDT 2015


-pie
           Produce a position independent executable on targets that support
           it.  For predictable results, you must also specify the same set of
           options used for compilation (-fpie, -fPIE, or model suboptions)
           when you specify this linker option.

Also, it's what QEMU's configure step does to detect whether PIE is
available :-)

On 19 May 2015 at 07:38, Rob Landley <rob at landley.net> wrote:
> On Mon, May 18, 2015 at 3:35 PM, David Halls <dahalls at gmail.com> wrote:
>> ~ # cat wup.c
>> int main(int argc, char **argv) { return 0; }
>> ~ # gcc -fPIE -pie wup.c
>
> Why does it need both -fPIE and -pie ?
>
> (Trying to figure out what changes I need to make to ccwrap parsing.)
>
> Rob



More information about the Aboriginal mailing list