aboutsummaryrefslogtreecommitdiffstats
path: root/firmware/Makefile
diff options
context:
space:
mode:
authorHarald Welte <laforge@gnumonks.org>2017-05-05 22:29:15 +0200
committerHarald Welte <laforge@gnumonks.org>2017-05-05 23:17:31 +0200
commitcaca0b1e7a2f0a6906267861528a9ff231463f80 (patch)
tree63af078bc4ee1ec745821e3eb873d4e5b8cc323c /firmware/Makefile
parent6d1128e9d138e2077eb113e26ee73c23108f8ad7 (diff)
Makefile: Add new 'combined' target to build combined DFU+APP image
Diffstat (limited to 'firmware/Makefile')
-rw-r--r--firmware/Makefile9
1 files changed, 9 insertions, 0 deletions
diff --git a/firmware/Makefile b/firmware/Makefile
index e3bb418..9634398 100644
--- a/firmware/Makefile
+++ b/firmware/Makefile
@@ -182,6 +182,15 @@ OUTPUT := $(BIN)/$(OUTPUT)
all: apps/$(APP)/usb_strings_generated.h $(BIN) $(OBJ) $(MEMORIES)
+combined: $(OUTPUT)-combined.bin
+
+$(BIN)/$(BOARD)-dfu-flash-padded.bin: $(BIN)/$(BOARD)-dfu-flash.bin
+ dd if=/dev/zero bs=16384 count=1 of=$@
+ dd if=$< conv=notrunc of=$@
+
+$(OUTPUT)-combined.bin: $(BIN)/$(BOARD)-dfu-flash-padded.bin $(OUTPUT)-dfu.bin
+ cat $^ > $@
+
$(BIN) $(OBJ):
mkdir $@