All of lore.kernel.org
 help / color / mirror / Atom feed
From: Axel Lin <axel.lin@ingics.com>
To: buildroot@busybox.net
Subject: [Buildroot] [noMMU] How to generate FLAT executable for busybox?
Date: Mon, 29 Jul 2013 13:40:35 +0800	[thread overview]
Message-ID: <1375076435.4630.2.camel@phoenix> (raw)

Hi,
I have BR2_BINFMT_FLAT=y in my setting.
However, the build system still generates ELF executable for busybox.

$ file output/target/bin/busybox
output/target/bin/busybox: setuid ELF 32-bit LSB executable, ARM, version 1 (SYSV), statically linked, stripped

I have below customization in my configs to build noMMU for arm7tdmi:
And then I did:
$ make CFLAGS_busybox="-elf2flt"

diff --git a/arch/Config.in b/arch/Config.in
index 0b5b218..a894e17 100644
--- a/arch/Config.in
+++ b/arch/Config.in
@@ -216,7 +216,6 @@ config BR2_GCC_TARGET_MODE
 # Set up target binary format
 choice
 	prompt "Target Binary Format"
-	depends on BR2_bfin || BR2_m68k
 	default BR2_BINFMT_FDPIC
 
 config BR2_BINFMT_ELF
@@ -229,7 +228,6 @@ config BR2_BINFMT_ELF
 
 config BR2_BINFMT_FDPIC
 	bool "FDPIC"
-	depends on BR2_bfin || BR2_m68k
 	help
 	  ELF FDPIC binaries are based on ELF, but allow the individual load
 	  segments of a binary to be located in memory independently of each
@@ -238,7 +236,6 @@ config BR2_BINFMT_FDPIC
 
 config BR2_BINFMT_FLAT
 	bool "FLAT"
-	depends on BR2_bfin || BR2_m68k
 	select BR2_PREFER_STATIC_LIB
 	help
 	  FLAT binary is a relatively simple and lightweight executable format
diff --git a/package/Makefile.in b/package/Makefile.in
index aed28d5..5b89e18 100644
--- a/package/Makefile.in
+++ b/package/Makefile.in
@@ -24,7 +24,7 @@ MAKE:=$(HOSTMAKE) -j$(PARALLEL_JOBS)
 GNU_TARGET_NAME=$(ARCH)-buildroot-$(TARGET_OS)-$(LIBC)$(ABI)
 
 # Blackfin FLAT needs uclinux
-ifeq ($(BR2_bfin)$(BR2_BINFMT_FLAT),yy)
+ifeq ($(BR2_BINFMT_FLAT),y)
 TARGET_OS=uclinux
 else
 TARGET_OS=linux
diff --git a/package/busybox/busybox-1.21.x.config b/package/busybox/busybox-1.21.x.config
index e46b528..4e692fc 100644
--- a/package/busybox/busybox-1.21.x.config
+++ b/package/busybox/busybox-1.21.x.config
@@ -55,9 +55,9 @@ CONFIG_FEATURE_SYSLOG=y
 #
 # Build Options
 #
-# CONFIG_STATIC is not set
+CONFIG_STATIC=y
 # CONFIG_PIE is not set
-# CONFIG_NOMMU is not set
+CONFIG_NOMMU=y
 # CONFIG_BUILD_LIBBUSYBOX is not set
 # CONFIG_FEATURE_INDIVIDUAL is not set
 # CONFIG_FEATURE_SHARED_BUSYBOX is not set
diff --git a/package/uclibc/uClibc-0.9.33.config b/package/uclibc/uClibc-0.9.33.config
index eb39df6..d0a9c0c 100644
--- a/package/uclibc/uClibc-0.9.33.config
+++ b/package/uclibc/uClibc-0.9.33.config
@@ -65,10 +65,10 @@ FORCE_OPTIONS_FOR_ARCH=y
 # ARCH_BIG_ENDIAN is not set
 # ARCH_WANTS_LITTLE_ENDIAN is not set
 # ARCH_WANTS_BIG_ENDIAN is not set
-ARCH_HAS_MMU=y
-ARCH_USE_MMU=y
+# ARCH_HAS_MMU is not set
+# ARCH_USE_MMU is not set
 UCLIBC_HAS_FLOATS=y
-UCLIBC_HAS_FPU=y
+# UCLIBC_HAS_FPU is not set
 DO_C99_MATH=y
 # DO_XSI_MATH is not set
 # UCLIBC_HAS_FENV is not set

             reply	other threads:[~2013-07-29  5:40 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-07-29  5:40 Axel Lin [this message]
2013-07-29  9:27 ` [Buildroot] [noMMU] How to generate FLAT executable for busybox? Axel Lin
2013-07-31 13:05   ` Axel Lin
2013-07-31 13:11     ` 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=1375076435.4630.2.camel@phoenix \
    --to=axel.lin@ingics.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.