All of lore.kernel.org
 help / color / mirror / Atom feed
From: Waldemar Brodkorb <wbx@openadk.org>
To: buildroot@busybox.net
Subject: [Buildroot] [PATCH] libnss: workaround for microblaze ld bug
Date: Sat, 18 Feb 2017 22:40:02 +0100	[thread overview]
Message-ID: <20170218214001.GA342@waldemar-brodkorb.de> (raw)

Add a workaround for a microblaze specific ld bug to avoid
segfault.

Fixes:
  http://autobuild.buildroot.net/results/638a65453879777a0d5bdb29231034cd261b41c0

Signed-off-by: Waldemar Brodkorb <wbx@openadk.org>
---
 package/libnss/libnss.mk | 10 ++++++++++
 1 file changed, 10 insertions(+)

diff --git a/package/libnss/libnss.mk b/package/libnss/libnss.mk
index 4a40b0a..5683ffc 100644
--- a/package/libnss/libnss.mk
+++ b/package/libnss/libnss.mk
@@ -13,6 +13,16 @@ LIBNSS_DEPENDENCIES = libnspr sqlite zlib
 LIBNSS_LICENSE = MPLv2.0
 LIBNSS_LICENSE_FILES = nss/COPYING
 
+# --gc-sections triggers binutils ld segfault
+# https://sourceware.org/bugzilla/show_bug.cgi?id=21180
+ifeq ($(BR2_microblaze),y)
+define LIBNSS_PRECONFIGURE
+	sed -i 's:-Wl,--gc-sections::g' $(@D)/nss/coreconf/Linux.mk
+endef
+
+LIBNSS_PRE_CONFIGURE_HOOKS += LIBNSS_PRECONFIGURE
+endif
+
 LIBNSS_BUILD_VARS = \
 	MOZILLA_CLIENT=1 \
 	NSPR_INCLUDE_DIR=$(STAGING_DIR)/usr/include/nspr \
-- 
2.1.4

             reply	other threads:[~2017-02-18 21:40 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-02-18 21:40 Waldemar Brodkorb [this message]
2017-02-19 21:15 ` [Buildroot] [PATCH] libnss: workaround for microblaze ld bug Peter Korsgaard

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=20170218214001.GA342@waldemar-brodkorb.de \
    --to=wbx@openadk.org \
    --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.