jw-pkg/make/mcu-exe.mk
Jan Lindemann 4a5ae9c734 mcu-*.mk: Support arm-none-eabi / modm
This commit adds compiler flags needed for compilation with modm. Cleanup is
needed, most notably should mcu-tags.mk be dissolved into defs-cpp.mk. The good
part is that it works.

Signed-off-by: Jan Lindemann <jan@janware.com>
2019-03-18 17:35:18 +00:00

22 lines
582 B
Makefile

DIR_BASENAME = $(notdir $(CWD))
ifeq ($(EXE_BASENAME),)
ifneq ($(DIR_BASENAME),test)
EXE_BASENAME = $(DIR_BASENAME).elf
else
EXE_BASENAME = test-$(notdir $(shell cd ..; $(PWD))).elf
endif
endif
MCU_FLASH_PUSH_FILE_HEX ?= $(patsubst %.elf,%.hex,$(EXE_BASENAME))
EXE_MAP ?= $(patsubst %.elf,%.map,$(EXE_BASENAME))
include $(MODDIR)/make/mcu-defs.mk
include $(MODDIR)/make/exe.mk
include $(MODDIR)/make/mcu-flash.mk
all: $(MCU_FLASH_PUSH_FILE_HEX)
clean: mcu-exe.clean
mcu-exe.clean:
rm -f $(EXE_MAP)