All of lore.kernel.org
 help / color / mirror / Atom feed
From: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
To: buildroot@busybox.net
Subject: [Buildroot] [PATCH] Remove -fPIC on x86_64
Date: Fri, 2 Dec 2011 10:36:53 +0100	[thread overview]
Message-ID: <20111202103653.377df8b4@skate> (raw)
In-Reply-To: <1322816170-27327-1-git-send-email-arnout@mind.be>

Le Fri,  2 Dec 2011 09:56:09 +0100,
"Arnout Vandecappelle (Essensium/Mind)" <arnout@mind.be> a ?crit :

> From: "Arnout Vandecappelle (Essensium/Mind)" <arnout@mind.be>
> 
> The -fPIC breaks the purgatory of kexec (= the code that passes command-line
> arguments to the kernel): kexec doesn't know how to handle the GOT and PLT
> relocation entries.
> 
> There is also no reason at all to pass -fPIC.  Shared libraries that require
> it will add it to their local Makefiles, and normal executables have no
> business with -fPIC (plus it adds overhead...).
> 
> The -fPIC was added by Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
> in commit 8027784c.  That commit adds sysroot parameters to CFLAGS.
> There is no explanation why -fPIC is also added for x86_64.
> 
> Signed-off-by: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be>

This needs some testing, but on the principle, I agree that Buildroot
shouldn't have to add this flag globally to TARGET_CFLAGS.

Thomas
-- 
Thomas Petazzoni, Free Electrons
Kernel, drivers, real-time and embedded Linux
development, consulting, training and support.
http://free-electrons.com

  reply	other threads:[~2011-12-02  9:36 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-12-02  8:56 [Buildroot] [PATCH] Remove -fPIC on x86_64 Arnout Vandecappelle
2011-12-02  9:36 ` Thomas Petazzoni [this message]
2012-01-06  6:49 ` Arnout Vandecappelle

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20111202103653.377df8b4@skate \
    --to=thomas.petazzoni@free-electrons.com \
    --cc=buildroot@busybox.net \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.