mirror of
https://github.com/hsoft/collapseos.git
synced 2024-11-30 20:28:05 +11:00
0d172cc2c4
Running a ROM on an everdrive is one thing, but running a ROM directly is another: my hacked up sega.bin didn't have a proper checksum, so the ROM didn't run. This new tool transforms a binary into a properly-headered ROM. Has been tested on an actual SMS.
33 lines
545 B
Makefile
33 lines
545 B
Makefile
TARGET = os.bin
|
|
BASE = ../../
|
|
STAGE = $(BASE)/cvm/stage
|
|
BLKPACK = $(BASE)/tools/blkpack
|
|
SMSROM = $(BASE)/tools/smsrom
|
|
EMUL = $(BASE)/emul/hw/sms/sms
|
|
|
|
.PHONY: all
|
|
all: $(TARGET)
|
|
$(TARGET): xcomp.fs $(STAGE) blkfs
|
|
cat xcomp.fs | $(STAGE) blkfs > $@
|
|
|
|
$(SMSROM):
|
|
$(BLKPACK):
|
|
$(MAKE) -C ../tools
|
|
|
|
blkfs: $(BLKPACK)
|
|
$(BLKPACK) $(BASE)/blk blk > $@
|
|
|
|
$(STAGE):
|
|
$(MAKE) -C $(BASE)/cvm stage
|
|
|
|
os.sms: $(TARGET) $(STAGE) $(SMSROM)
|
|
$(SMSROM) $(TARGET) > $@
|
|
|
|
$(EMUL):
|
|
$(MAKE) -C ${@:%/sms=%}
|
|
|
|
.PHONY: emul
|
|
emul: $(EMUL) $(TARGET)
|
|
$(EMUL) $(TARGET)
|
|
|