board/csky: fixup gdb instructions in readme.txt
[buildroot-gz.git] / package / uboot-tools / 0004-Pass-empty-CFLAGS-on-invocation-of-libfdt-setup.py.patch
blobae01b33708012750f687c42cd30780585f763122
1 From 7807af13118eff3ac291bbaaf2159c7a441c0902 Mon Sep 17 00:00:00 2001
2 From: Max Filippov <jcmvbkbc@gmail.com>
3 Date: Thu, 16 Mar 2017 11:21:58 -0700
4 Subject: [PATCH] Pass empty CFLAGS on invocation of libfdt/setup.py
6 When building u-boot tools in cross-build environment CFLAGS environment
7 variable set up for target is taken into an account when building code
8 for host. Make it empty on invocation of python.
10 This fixes the following build errors when cross-compiling for xtensa:
12 cc1: error: unrecognized command line option "-mlongcalls"
13 cc1: error: unrecognized command line option "-mauto-litpools"
15 Signed-off-by: Max Filippov <jcmvbkbc@gmail.com>
16 Reviewed-by: Simon Glass <sjg@chromium.org>
17 ---
18 tools/Makefile | 2 +-
19 1 file changed, 1 insertion(+), 1 deletion(-)
21 diff --git a/tools/Makefile b/tools/Makefile
22 index 1c840d7..f3de657 100644
23 --- a/tools/Makefile
24 +++ b/tools/Makefile
25 @@ -120,7 +120,7 @@ _libfdt.so-sharedobjs += $(LIBFDT_OBJS)
26 libfdt:
28 tools/_libfdt.so: $(patsubst %.o,%.c,$(LIBFDT_OBJS)) tools/libfdt_wrap.c
29 - LDFLAGS="$(HOSTLDFLAGS)" python $(srctree)/lib/libfdt/setup.py \
30 + LDFLAGS="$(HOSTLDFLAGS)" CFLAGS= python $(srctree)/lib/libfdt/setup.py \
31 "$(_hostc_flags)" $^
32 mv _libfdt.so $@
34 --
35 2.1.4