From a576f44ba23888acb971defd43f6f67f2545303b Mon Sep 17 00:00:00 2001 From: dogtopus Date: Sat, 26 May 2018 01:21:06 -0300 Subject: [PATCH] Add binary generation (#310) --- workspace/TS100/Makefile | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/workspace/TS100/Makefile b/workspace/TS100/Makefile index 04c31f0a..f0be4f53 100644 --- a/workspace/TS100/Makefile +++ b/workspace/TS100/Makefile @@ -177,7 +177,7 @@ OUT_OBJS_CPP=$(addprefix $(OUTPUT_DIR)/,$(OBJS_CPP)) OUT_OBJS_S=$(addprefix $(OUTPUT_DIR)/,$(OBJS_S)) OUT_HEXFILE=$(addprefix $(HEXFILE_DIR)/,$(OUTPUT_EXE)) -all: $(OUT_HEXFILE).hex +all: $(OUT_HEXFILE).hex $(OUT_HEXFILE).bin # # The rule to create the target directory @@ -188,6 +188,10 @@ all: $(OUT_HEXFILE).hex $(SIZE) $^ $(OBJCOPY) $^ -O ihex $@ +%.bin : %.elf + $(SIZE) $^ + $(OBJCOPY) $^ -O binary $@ + $(OUT_HEXFILE).elf : $(OUT_OBJS) $(OUT_OBJS_CPP) $(OUT_OBJS_S) Makefile $(LDSCRIPT) @test -d $(@D) || mkdir -p $(@D) @echo Linking $(OUTPUT_EXE).elf