From 3c8ded4743c09a7b0c7737392d4e4c15e6959852 Mon Sep 17 00:00:00 2001 From: Gregwar Date: Wed, 23 Apr 2014 16:45:23 +0200 Subject: Adding BOOTLOADER option to support Robotis bootloader different ROM MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Grégoire Passault --- Makefile | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'Makefile') diff --git a/Makefile b/Makefile index 1f19f37..80653a7 100644 --- a/Makefile +++ b/Makefile @@ -32,6 +32,9 @@ BOARD_INCLUDE_DIR := $(MAKEDIR)/board-includes BOARD ?= maple MEMORY_TARGET ?= flash +# Chooses the bootloader, available: maple and robotis +BOOTLOADER ?= maple + # $(BOARD)- and $(MEMORY_TARGET)-specific configuration include $(MAKEDIR)/target-config.mk @@ -56,7 +59,8 @@ TARGET_FLAGS += -I$(LIBMAPLE_PATH)/include/libmaple \ TARGET_FLAGS += -I$(LIBRARIES_PATH) # for internal lib. includes, e.g. GLOBAL_CFLAGS := -Os -g3 -gdwarf-2 -nostdlib \ -ffunction-sections -fdata-sections \ - -Wl,--gc-sections $(TARGET_FLAGS) + -Wl,--gc-sections $(TARGET_FLAGS) \ + -DBOOTLOADER_$(BOOTLOADER) GLOBAL_CXXFLAGS := -fno-rtti -fno-exceptions -Wall $(TARGET_FLAGS) GLOBAL_ASFLAGS := -x assembler-with-cpp $(TARGET_FLAGS) LDFLAGS = $(TARGET_LDFLAGS) $(TOOLCHAIN_LDFLAGS) -mcpu=cortex-m3 -mthumb \ -- cgit v1.2.3