Buildroot Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
To: buildroot@busybox.net
Subject: [Buildroot] [PATCH] elfutils: fix sparc64 build, -fPIC required
Date: Tue, 3 Nov 2015 18:57:33 +0100	[thread overview]
Message-ID: <20151103185733.364482c2@free-electrons.com> (raw)
In-Reply-To: <20151103171832.GA7668@waldemar-brodkorb.de>

Dear Waldemar Brodkorb,

On Tue, 3 Nov 2015 18:18:32 +0100, Waldemar Brodkorb wrote:
> Fixes following autobuild errors:
> http://autobuild.buildroot.net/results/82cc7766d2c805146e94baf82a24d1002f56593d/
> http://autobuild.buildroot.net/results/ca4ca362581ee0111cba389d1afbff287692c21b/
> 
> Signed-off-by: Waldemar Brodkorb <wbx@openadk.org>
> ---
>  package/elfutils/elfutils.mk |    5 +++++
>  1 file changed, 5 insertions(+)
> 
> diff --git a/package/elfutils/elfutils.mk b/package/elfutils/elfutils.mk
> index 838c3b8..261849a 100644
> --- a/package/elfutils/elfutils.mk
> +++ b/package/elfutils/elfutils.mk
> @@ -21,6 +21,11 @@ ELFUTILS_CONF_ENV += \
>  	CFLAGS="$(filter-out -D_FILE_OFFSET_BITS=64,$(TARGET_CFLAGS))" \
>  	CPPFLAGS="$(filter-out -D_FILE_OFFSET_BITS=64,$(TARGET_CPPFLAGS))"
>  
> +# sparc64 needs -fPIC instead of -fpic
> +ifeq ($(BR2_sparc64),y)
> +ELFUTILS_CONF_ENV += CFLAGS="$(filter-out -D_FILE_OFFSET_BITS=64,$(TARGET_CFLAGS)) -fPIC"

I don't like the duplication of the _FILE_OFFSET_BITS dance. Can you
introduce an ELFUTILS_CFLAGS instead ?

Also, for libpcap, -fPIC is needed instead of -fpic for both microblaze
and sparc64. But for elfutils, -fPIC is only needed for sparc64 ? I
just tested a quick build of elfutils on microblaze, and it indeed
works without any change.

Do you have any clue why?

Thanks,

Thomas
-- 
Thomas Petazzoni, CTO, Free Electrons
Embedded Linux, Kernel and Android engineering
http://free-electrons.com

  reply	other threads:[~2015-11-03 17:57 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-11-03 17:18 [Buildroot] [PATCH] elfutils: fix sparc64 build, -fPIC required Waldemar Brodkorb
2015-11-03 17:57 ` Thomas Petazzoni [this message]
2015-11-03 18:18   ` Waldemar Brodkorb
2015-11-03 19:50     ` Thomas Petazzoni

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=20151103185733.364482c2@free-electrons.com \
    --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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox