2020-05-17 21:12:26 +02:00
|
|
|
#---------------------------------------------------------------------------------
|
|
|
|
.SUFFIXES:
|
|
|
|
#---------------------------------------------------------------------------------
|
|
|
|
|
|
|
|
ifeq ($(strip $(DEVKITPRO)),)
|
|
|
|
$(error "Please set DEVKITPRO in your environment. export DEVKITPRO=<path to>/devkitPro")
|
|
|
|
endif
|
|
|
|
|
|
|
|
ifeq ($(strip $(DEVKITPPC)),)
|
|
|
|
$(error "Please set DEVKITPPC in your environment. export DEVKITPPC=<path to>/devkitPro/devkitPPC")
|
|
|
|
endif
|
|
|
|
|
2020-06-10 12:51:58 +02:00
|
|
|
include $(DEVKITPRO)/wut/share/wut_rules
|
2020-05-17 21:12:26 +02:00
|
|
|
|
|
|
|
WUMS_ROOT ?= $(DEVKITPRO)/wums
|
|
|
|
|
2020-06-10 12:51:58 +02:00
|
|
|
WUMSSPECS := -T$(WUMS_ROOT)/share/wums.ld -specs=$(WUMS_ROOT)/share/wums.specs
|
2020-05-17 21:12:26 +02:00
|
|
|
|
|
|
|
#---------------------------------------------------------------------------------
|
|
|
|
%.wms: %.elf
|
|
|
|
@cp $< $*.strip.elf
|
|
|
|
@$(STRIP) -g $*.strip.elf
|
|
|
|
@elf2rpl $*.strip.elf $@
|
|
|
|
@printf '\xAF\xFE' | dd of=$@ bs=1 seek=9 count=2 conv=notrunc status=none
|
|
|
|
@rm $*.strip.elf
|
2020-06-10 12:51:58 +02:00
|
|
|
@echo built ... $(notdir $@)
|