summaryrefslogtreecommitdiffstats
path: root/examples/api
diff options
context:
space:
mode:
Diffstat (limited to 'examples/api')
-rw-r--r--examples/api/Makefile6
1 files changed, 4 insertions, 2 deletions
diff --git a/examples/api/Makefile b/examples/api/Makefile
index 09475f87e4..6c19830d2c 100644
--- a/examples/api/Makefile
+++ b/examples/api/Makefile
@@ -40,8 +40,10 @@ OBJS += $(addprefix $(obj)/,$(notdir $(EXT_SOBJ_FILES-y)))
$(obj)/demo: $(OBJS)
$(LD) --gc-sections -Ttext $(LOAD_ADDR) -o $@ $^ $(PLATFORM_LIBS)
-$(obj)/demo.bin: $(obj)/demo
- $(OBJCOPY) -O binary $< $@ 2>/dev/null
+# demo.bin is never genrated. Is this necessary?
+OBJCOPYFLAGS_demo.bin := -O binary
+$(obj)/demo.bin: $(obj)/demo FORCE
+ $(call if_changed,objcopy)
# Rule to build generic library C files
$(addprefix $(obj)/,$(notdir $(EXT_COBJ_FILES-y))): $(obj)/%.o: $(SRCTREE)/lib/%.c FORCE
OpenPOWER on IntegriCloud