summaryrefslogtreecommitdiff
path: root/spl
diff options
context:
space:
mode:
authorMasahiro Yamada <yamada.m@jp.panasonic.com>2014-02-24 11:12:14 +0900
committerTom Rini <trini@ti.com>2014-02-25 11:01:29 -0500
commitf9c235fd9950ca1b150f8d40d358e1a58cbb0ea8 (patch)
tree5f1625ddbcaeb45a104b8dfbb3f9f0ec341d14c2 /spl
parent03c7b3fc0ba9636d3de8db0997f60e96c7494bfc (diff)
downloadu-boot-imx-f9c235fd9950ca1b150f8d40d358e1a58cbb0ea8.zip
u-boot-imx-f9c235fd9950ca1b150f8d40d358e1a58cbb0ea8.tar.gz
u-boot-imx-f9c235fd9950ca1b150f8d40d358e1a58cbb0ea8.tar.bz2
kbuild: use shorten logs objcopy rules
Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
Diffstat (limited to 'spl')
-rw-r--r--spl/Makefile19
1 files changed, 17 insertions, 2 deletions
diff --git a/spl/Makefile b/spl/Makefile
index df4ecfa..94e721f 100644
--- a/spl/Makefile
+++ b/spl/Makefile
@@ -200,8 +200,13 @@ $(obj)/$(BOARD)-spl.bin: $(obj)/u-boot-spl.bin
$(OBJTREE)/tools/mkexynosspl) $(VAR_SIZE_PARAM) $< $@
endif
-$(obj)/$(SPL_BIN).bin: $(obj)/$(SPL_BIN)
- $(OBJCOPY) $(OBJCOPYFLAGS) $(SPL_OBJCFLAGS) -O binary $< $@
+quiet_cmd_objcopy = OBJCOPY $@
+cmd_objcopy = $(OBJCOPY) $(OBJCOPYFLAGS) $(OBJCOPYFLAGS_$(@F)) $< $@
+
+OBJCOPYFLAGS_$(SPL_BIN).bin = $(SPL_OBJCFLAGS) -O binary
+
+$(obj)/$(SPL_BIN).bin: $(obj)/$(SPL_BIN) FORCE
+ $(call if_changed,objcopy)
LDFLAGS_$(SPL_BIN) += -T u-boot-spl.lds $(LDFLAGS_FINAL)
ifneq ($(CONFIG_SPL_TEXT_BASE),)
@@ -229,6 +234,16 @@ cpp_flags := $(KBUILD_CPPFLAGS) $(CPPFLAGS) $(UBOOTINCLUDE) $(NOSTDINC_FLAGS)
$(obj)/u-boot-spl.lds: $(LDSCRIPT) FORCE
$(CPP) $(cpp_flags) $(LDPPFLAGS) -I$(obj). -ansi -D__ASSEMBLY__ -P - < $< > $@
+# read all saved command lines
+
+targets := $(wildcard $(sort $(targets)))
+cmd_files := $(wildcard $(obj)/.*.cmd $(foreach f,$(targets),$(dir $(f)).$(notdir $(f)).cmd))
+
+ifneq ($(cmd_files),)
+ $(cmd_files): ; # Do not try to update included dependency files
+ include $(cmd_files)
+endif
+
PHONY += FORCE
FORCE: