Sentinel65X-Kernel/Makefile

38 lines
565 B
Makefile

AS := 64tass
MP := minipro
ASFLAGS := -I include \
-I src \
--m65816 \
--nostart \
--long-branch \
--long-address \
-Walign \
-Wno-wrap-pc
MPFLAGS := -p SST39LF040@PLCC32
SOURCES := $(wildcard src/*.s)
INCLUDES := $(wildcard include/*.i)
TARGET := sentinel65x-firmware-512k
LIST := $(TARGET).lst
.PHONY: all
all: $(TARGET).bin
@du -h $(TARGET).bin
$(TARGET).bin: $(SOURCES)
$(AS) $(ASFLAGS) -l $(LIST) -o $@ $^
.PHONY: flash
flash: $(TARGET).bin
$(MP) $(MPFLAGS) -w $<
.PHONY: clean
clean:
rm -f $(TARGET).bin $(LIST)
.PREFIXES: