Sentinel65X-Kernel/Makefile

40 lines
594 B
Makefile

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