mirror of
ssh://git.janware.com/srv/git/janware/proj/jw-pkg
synced 2026-01-15 12:03:31 +01:00
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>
22 lines
582 B
Makefile
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)
|