mirror of
ssh://git.janware.com/srv/git/janware/proj/jw-pkg
synced 2026-01-15 03:53:32 +01:00
Rename the omnipresent MODDIR variable to JWBDIR, since that's more to the point. Signed-off-by: Jan Lindemann <jan@janware.com>
28 lines
813 B
Makefile
28 lines
813 B
Makefile
DIR_BASENAME = $(notdir $(CWD))
|
|
|
|
ifeq ($(EXE_BASENAME),)
|
|
ifneq ($(DIR_BASENAME),test)
|
|
EXE_BASENAME = $(EXE_BASENAME_PREFIX)$(DIR_BASENAME).elf
|
|
else
|
|
EXE_BASENAME = $(EXE_BASENAME_PREFIX)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))
|
|
|
|
# I think these (or something equivalent) should go somewhere here. Not cleaned
|
|
# up enough in modm builds to do it.
|
|
#include $(JWBDIR)/make/defs.mk
|
|
#include $(JWBDIR)/make/defs-cpp.mk
|
|
|
|
include $(JWBDIR)/make/mcu-defs.mk
|
|
include $(JWBDIR)/make/exe.mk
|
|
include $(JWBDIR)/make/mcu-flash.mk
|
|
|
|
all: $(MCU_FLASH_PUSH_FILE_HEX)
|
|
|
|
clean: mcu-exe.clean
|
|
|
|
mcu-exe.clean:
|
|
rm -f $(EXE_MAP)
|