From: Peter Korsgaard <jacmet@uclibc.org>
To: buildroot@busybox.net
Subject: [Buildroot] mtd-utils fails to build
Date: Mon, 08 Mar 2010 22:46:56 +0100 [thread overview]
Message-ID: <877hpmv63z.fsf@macbook.be.48ers.dk> (raw)
In-Reply-To: <BD79186B4FD85F4B8E60E381CAEE190902242788@mi8nycmail19.Mi8.com> (H. Hartley Sweeten's message of "Mon, 8 Mar 2010 16:04:46 -0500")
>>>>> "H" == H Hartley Sweeten <hartleys@visionengravers.com> writes:
H> Hello all,
H> I am trying to do a clean build using the current git pull of buildroot.
H> Everything goes as expected until trying to build mtd-utils. When trying
H> to build mkfs.jffs2 the build cannot find zlib.h and errors out.
H> It appears that a compile and assemble, but do not link (option -c), happens
H> first for each file followed by compile and place output into <file>
H> (option -o).
H> The problem appears to be that the -c option happens without passing the
H> --sysroot configuration so the compiler cannot locate the external headers.
H> Following is a snip of the last part of the build:
Thanks, fixed in git:
commit d5bf5f967009733da99c55febacb3fb0be686cad
Author: Peter Korsgaard <jacmet@sunsite.dk>
Date: Mon Mar 8 22:44:28 2010 +0100
mtd-utils: fix build with external toolchain
Reported by H Hartley Sweeten.
Make sure we pass proper CFLAGS to mtd-utils, so builds needing --sysroot
works (E.G. external toolchains).
Signed-off-by: Peter Korsgaard <jacmet@sunsite.dk>
diff --git a/package/mtd/mtd.mk b/package/mtd/mtd.mk
index 244fd8e..3e0fcaf 100644
--- a/package/mtd/mtd.mk
+++ b/package/mtd/mtd.mk
@@ -111,14 +111,14 @@ MTD_BUILD_TARGETS := $(MTD_TARGETS) $(MTD_UBI_TARGETS)
$(MTD_BUILD_TARGETS): $(MTD_DIR)/.unpacked
ifneq ($(MTD_TARGETS),)
- $(MAKE) LDFLAGS="$(TARGET_LDFLAGS)" \
+ $(MAKE) $(TARGET_CONFIGURE_ENV) \
BUILDDIR=$(MTD_DIR) \
CROSS=$(TARGET_CROSS) CC=$(TARGET_CC) \
WITHOUT_XATTR=1 WITHOUT_LARGEFILE=1 \
-C $(MTD_DIR) $(MTD_TARGETS)
endif
ifneq ($(MTD_UBI_TARGETS),)
- $(MAKE) LDFLAGS="$(TARGET_LDFLAGS)" \
+ $(MAKE) $(TARGET_CONFIGURE_ENV) \
BUILDDIR=$(MTD_DIR)/ubi-utils \
CROSS=$(TARGET_CROSS) CC=$(TARGET_CC) \
WITHOUT_XATTR=1 WITHOUT_LARGEFILE=1 \
--
Bye, Peter Korsgaard
next prev parent reply other threads:[~2010-03-08 21:46 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-03-08 21:04 [Buildroot] mtd-utils fails to build H Hartley Sweeten
2010-03-08 21:27 ` H Hartley Sweeten
2010-03-08 21:46 ` Peter Korsgaard [this message]
2010-03-08 21:51 ` H Hartley Sweeten
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=877hpmv63z.fsf@macbook.be.48ers.dk \
--to=jacmet@uclibc.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox