From cf6421f7d65af773c579f6e6e6db842656cac0a2 Mon Sep 17 00:00:00 2001 From: Eugene Krasnikov Date: Wed, 3 Apr 2013 20:40:57 +0200 Subject: [PATCH] Create output directory for bin2hex before compiling If target_firmware/magpie_fw_dev/build/utility/bin is not created before compiling bin2hex build will fail. Signed-off-by: Eugene Krasnikov --- target_firmware/magpie_fw_dev/build/utility/Makefile | 3 +++ target_firmware/magpie_fw_dev/build/utility/bin2hex/Makefile | 3 ++- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/target_firmware/magpie_fw_dev/build/utility/Makefile b/target_firmware/magpie_fw_dev/build/utility/Makefile index 2fdce93..a7f6581 100755 --- a/target_firmware/magpie_fw_dev/build/utility/Makefile +++ b/target_firmware/magpie_fw_dev/build/utility/Makefile @@ -1,7 +1,10 @@ DIRS = bin2hex +TARGET_DIR = ./bin all: + @mkdir -p $(TARGET_DIR) @for i in $(DIRS) ; do $(MAKE) -C $$i || exit $? ; done clean : @for i in $(DIRS) ; do $(MAKE) -C $$i clean; done + @rm -r $(TARGET_DIR) diff --git a/target_firmware/magpie_fw_dev/build/utility/bin2hex/Makefile b/target_firmware/magpie_fw_dev/build/utility/bin2hex/Makefile index 4dacafd..6a33d4e 100755 --- a/target_firmware/magpie_fw_dev/build/utility/bin2hex/Makefile +++ b/target_firmware/magpie_fw_dev/build/utility/bin2hex/Makefile @@ -1,10 +1,11 @@ TARGET = ../bin/bin2hex # for Linux environment - +TARGET_DIR = ../bin E=echo all: $(TARGET) $(TARGET): + @mkdir -p $(TARGET_DIR) gcc -o $(TARGET) bin2hex.c @$(E) " CC " $@ -- 2.31.1