All of lore.kernel.org
 help / color / mirror / Atom feed
From: Mike Frysinger <vapier@gentoo.org>
To: buildroot@busybox.net
Subject: [Buildroot] [PATCH 2/2] busybox: respect strip settings
Date: Wed, 17 Nov 2010 01:47:12 -0500	[thread overview]
Message-ID: <1289976432-22684-2-git-send-email-vapier@gentoo.org> (raw)
In-Reply-To: <1289976432-22684-1-git-send-email-vapier@gentoo.org>

For some ABI's (like FLAT), we cannot strip busybox as the file format
does not support it and strip will abort with errors like 'File format
not recognized'.

Signed-off-by: Mike Frysinger <vapier@gentoo.org>
---
 package/busybox/busybox.mk |    8 +++++++-
 1 files changed, 7 insertions(+), 1 deletions(-)

diff --git a/package/busybox/busybox.mk b/package/busybox/busybox.mk
index 5ef1622..323dad8 100644
--- a/package/busybox/busybox.mk
+++ b/package/busybox/busybox.mk
@@ -16,6 +16,12 @@ BUSYBOX_BUILD_CONFIG = $(BUSYBOX_DIR)/.config
 # Allows the build system to tweak CFLAGS
 BUSYBOX_MAKE_ENV = $(TARGET_MAKE_ENV) CFLAGS="$(TARGET_CFLAGS) -I$(LINUX_HEADERS_DIR)/include"
 
+ifeq ($(TARGET_STRIP),true)
+BUSYBOX_STRIP = cp $$< $$@; :
+else
+BUSYBOX_STRIP = $(TARGET_STRIP)
+endif
+
 ifndef BUSYBOX_CONFIG_FILE
 	BUSYBOX_CONFIG_FILE = $(call qstrip,$(BR2_PACKAGE_BUSYBOX_CONFIG))
 endif
@@ -124,7 +130,7 @@ define BUSYBOX_BUILD_CMDS
 	$(BUSYBOX_MAKE_ENV) $(MAKE) CC="$(TARGET_CC)" ARCH=$(KERNEL_ARCH) \
 		PREFIX="$(TARGET_DIR)" EXTRA_LDFLAGS="$(TARGET_LDFLAGS)" \
 		CROSS_COMPILE="$(TARGET_CROSS)" CONFIG_PREFIX="$(TARGET_DIR)" \
-		-C $(BUSYBOX_DIR)
+		STRIP='$(BUSYBOX_STRIP)' -C $(BUSYBOX_DIR)
 endef
 
 ifeq ($(BR2_PACKAGE_BUSYBOX_FULLINSTALL),y)
-- 
1.7.3.2

  reply	other threads:[~2010-11-17  6:47 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-11-17  6:47 [Buildroot] [PATCH 1/2] busybox: unify duplicated build steps Mike Frysinger
2010-11-17  6:47 ` Mike Frysinger [this message]
2010-11-18  4:00   ` [Buildroot] [PATCH 2/2 v2] busybox: let buildroot handle stripping Mike Frysinger
2010-11-18 10:24     ` Mike Frysinger

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=1289976432-22684-2-git-send-email-vapier@gentoo.org \
    --to=vapier@gentoo.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.