dcf16c716fcd914f4b9b3215af571bf856a900f5
[openwrt/staging/chunkeey.git] / package / boot / uboot-sunxi / patches / 210-Revert-fdt-Makefile-Build-python-libfdt-library-if-n.patch
1 From eed65e5c25cbc4b6e893f140e9d7898f4624c114 Mon Sep 17 00:00:00 2001
2 From: Hauke Mehrtens <hauke@hauke-m.de>
3 Date: Wed, 19 Jul 2017 23:12:38 +0200
4 Subject: [PATCH 210/213] Revert "fdt: Makefile: Build python libfdt library if
5 needed"
6
7 This reverts commit e38ffc42674fedc750ca895046be0bd983b56dd5.
8 ---
9 Makefile | 17 ++---------------
10 scripts/Makefile.spl | 17 ++++-------------
11 2 files changed, 6 insertions(+), 28 deletions(-)
12
13 diff --git a/Makefile b/Makefile
14 index 119ad49eec..071efa8926 100644
15 --- a/Makefile
16 +++ b/Makefile
17 @@ -1116,7 +1116,7 @@ cmd_ldr = $(LD) $(LDFLAGS_$(@F)) \
18
19 u-boot.rom: u-boot-x86-16bit.bin u-boot.bin \
20 $(if $(CONFIG_SPL_X86_16BIT_INIT),spl/u-boot-spl.bin) \
21 - $(if $(CONFIG_HAVE_REFCODE),refcode.bin) checkbinman FORCE
22 + $(if $(CONFIG_HAVE_REFCODE),refcode.bin) FORCE
23 $(call if_changed,binman)
24
25 OBJCOPYFLAGS_u-boot-x86-16bit.bin := -O binary -j .start16 -j .resetvec
26 @@ -1125,8 +1125,7 @@ u-boot-x86-16bit.bin: u-boot FORCE
27 endif
28
29 ifneq ($(CONFIG_ARCH_SUNXI),)
30 -u-boot-sunxi-with-spl.bin: spl/sunxi-spl.bin u-boot.img u-boot.dtb \
31 - checkbinman FORCE
32 +u-boot-sunxi-with-spl.bin: spl/sunxi-spl.bin u-boot.img u-boot.dtb FORCE
33 $(call if_changed,binman)
34 endif
35
36 @@ -1355,18 +1354,6 @@ $(version_h): include/config/uboot.release FORCE
37 $(timestamp_h): $(srctree)/Makefile FORCE
38 $(call filechk,timestamp.h)
39
40 -checkbinman: tools
41 - @if ! ( echo 'import libfdt' | ( PYTHONPATH=tools python )); then \
42 - echo >&2; \
43 - echo >&2 '*** binman needs the Python libfdt library.'; \
44 - echo >&2 '*** Either install it on your system, or try:'; \
45 - echo >&2 '***'; \
46 - echo >&2 '*** sudo apt-get install swig libpython-dev'; \
47 - echo >&2 '***'; \
48 - echo >&2 '*** to have U-Boot build its own version.'; \
49 - false; \
50 - fi
51 -
52 # ---------------------------------------------------------------------------
53 quiet_cmd_cpp_lds = LDS $@
54 cmd_cpp_lds = $(CPP) -Wp,-MD,$(depfile) $(cpp_flags) $(LDPPFLAGS) \
55 diff --git a/scripts/Makefile.spl b/scripts/Makefile.spl
56 index ac3c2c7f13..135706f21d 100644
57 --- a/scripts/Makefile.spl
58 +++ b/scripts/Makefile.spl
59 @@ -257,12 +257,14 @@ PHONY += dts_dir
60 dts_dir:
61 $(shell [ -d $(obj)/dts ] || mkdir -p $(obj)/dts)
62
63 -include/generated/dt-structs.h: $(obj)/$(SPL_BIN).dtb dts_dir checkdtoc
64 +include/generated/dt-structs.h: $(obj)/$(SPL_BIN).dtb dts_dir dtoc
65 $(call if_changed,dtoch)
66
67 -$(obj)/dts/dt-platdata.c: $(obj)/$(SPL_BIN).dtb dts_dir checkdtoc
68 +$(obj)/dts/dt-platdata.c: $(obj)/$(SPL_BIN).dtb dts_dir dtoc
69 $(call if_changed,dtocc)
70
71 +dtoc: #$(objtree)/tools/_libfdt.so
72 +
73 ifdef CONFIG_SAMSUNG
74 ifdef CONFIG_VAR_SIZE_SPL
75 VAR_SIZE_PARAM = --vs
76 @@ -355,17 +357,6 @@ ifneq ($(cmd_files),)
77 include $(cmd_files)
78 endif
79
80 -checkdtoc: tools
81 - @if ! ( echo 'import libfdt' | ( PYTHONPATH=tools python )); then \
82 - echo '*** dtoc needs the Python libfdt library. Either '; \
83 - echo '*** install it on your system, or try:'; \
84 - echo '***'; \
85 - echo '*** sudo apt-get install swig libpython-dev'; \
86 - echo '***'; \
87 - echo '*** to have U-Boot build its own version.'; \
88 - false; \
89 - fi
90 -
91 PHONY += FORCE
92 FORCE:
93
94 --
95 2.11.0
96