mirror of
https://github.com/garrettsworkshop/MacIIROMDiskDriver.git
synced 2024-12-27 03:32:24 +00:00
Build older bbraun ROM and concatenate with disk image, just to prove it works
This commit is contained in:
parent
0fc75fbbac
commit
0193167e6b
52
Makefile
52
Makefile
@ -7,7 +7,7 @@ LD=$(RETRO68)/bin/m68k-apple-macos-ld
|
||||
OBJCOPY=$(RETRO68)/bin/m68k-apple-macos-objcopy
|
||||
OBJDUMP=$(RETRO68)/bin/m68k-apple-macos-objdump
|
||||
|
||||
all: bin/rom.bin obj/rdisk.s obj/rdisk_reloc.s obj/rdisk_rel.sym obj/rdisk_abs.sym bin/rdisk_nonreloc.bin bin/rom_braun.bin obj/rdisk_braun.s obj/rdisk_braun_reloc.s obj/rdisk_braun_rel.sym obj/rdisk_braun_abs.sym bin/rdisk_braun_nonreloc.bin
|
||||
all: bin/rom.bin obj/rdisk.s obj/rdisk_reloc.s obj/rdisk_rel.sym obj/rdisk_abs.sym bin/rdisk_nonreloc.bin bin/rom_braun.bin obj/rdisk_braun.s obj/rdisk_braun_reloc.s obj/rdisk_braun_rel.sym obj/rdisk_braun_abs.sym bin/rdisk_braun_nonreloc.bin bin/rom_braun_oldbin.bin
|
||||
|
||||
obj:
|
||||
mkdir obj
|
||||
@ -65,33 +65,33 @@ bin/rdisk_braun_nonreloc.bin: bin obj/rdisk_braun.o
|
||||
$(OBJCOPY) -O binary obj/rdisk_braun.o $@
|
||||
|
||||
|
||||
bin/rom.bin: bin bin/rdisk.bin obj/rdisk_rel.sym
|
||||
cp baserom_braun_2m_0.9.bin bin/rom.bin
|
||||
cat bin/rdisk.bin | dd of=bin/rom.bin bs=1 seek=335266 skip=50 conv=notrunc # Copy driver code
|
||||
printf '\x78' | dd of=bin/rom.bin bs=1 seek=335168 count=1 conv=notrunc # Set resource flags
|
||||
printf '\x4F' | dd of=bin/rom.bin bs=1 seek=335216 count=1 conv=notrunc # Set driver flags
|
||||
# Copy entry points
|
||||
cat obj/rdisk_rel.sym | grep "Open" | cut -c5-8 | xxd -r -p - | dd of=bin/rom.bin bs=1 seek=335224 count=2 conv=notrunc
|
||||
cat obj/rdisk_rel.sym | grep "Prime" | cut -c5-8 | xxd -r -p - | dd of=bin/rom.bin bs=1 seek=335226 count=2 conv=notrunc
|
||||
cat obj/rdisk_rel.sym | grep "Control" | cut -c5-8 | xxd -r -p - | dd of=bin/rom.bin bs=1 seek=335228 count=2 conv=notrunc
|
||||
cat obj/rdisk_rel.sym | grep "Status" | cut -c5-8 | xxd -r -p - | dd of=bin/rom.bin bs=1 seek=335230 count=2 conv=notrunc
|
||||
cat obj/rdisk_rel.sym | grep "Close" | cut -c5-8 | xxd -r -p - | dd of=bin/rom.bin bs=1 seek=335232 count=2 conv=notrunc
|
||||
# Copy ROM disk
|
||||
dd if=RDisk1M5 of=bin/rom.bin bs=1024 seek=512 count=1536 conv=notrunc
|
||||
bin/rom.bin: baserom.bin bin bin/rdisk.bin obj/rdisk_rel.sym
|
||||
cp baserom.bin $@ # copy base rom
|
||||
cat bin/rdisk.bin | dd of=$@ bs=1 seek=335266 skip=50 conv=notrunc # Copy driver code
|
||||
printf '\x78' | dd of=$@ bs=1 seek=335168 count=1 conv=notrunc # Set resource flags
|
||||
printf '\x4F' | dd of=$@ bs=1 seek=335216 count=1 conv=notrunc # Set driver flags
|
||||
cat obj/rdisk_rel.sym | grep "Open" | cut -c5-8 | xxd -r -p - | dd of=$@ bs=1 seek=335224 count=2 conv=notrunc
|
||||
cat obj/rdisk_rel.sym | grep "Prime" | cut -c5-8 | xxd -r -p - | dd of=$@ bs=1 seek=335226 count=2 conv=notrunc
|
||||
cat obj/rdisk_rel.sym | grep "Control" | cut -c5-8 | xxd -r -p - | dd of=$@ bs=1 seek=335228 count=2 conv=notrunc
|
||||
cat obj/rdisk_rel.sym | grep "Status" | cut -c5-8 | xxd -r -p - | dd of=$@ bs=1 seek=335230 count=2 conv=notrunc
|
||||
cat obj/rdisk_rel.sym | grep "Close" | cut -c5-8 | xxd -r -p - | dd of=$@ bs=1 seek=335232 count=2 conv=notrunc
|
||||
dd if=RDisk1M5 of=$@ bs=1024 seek=512 count=1536 conv=notrunc # copy disk image
|
||||
|
||||
bin/rom_braun.bin: bin bin/rdisk_braun.bin obj/rdisk_braun_rel.sym
|
||||
cp baserom_braun_2m_0.9.bin bin/rom_braun.bin
|
||||
cat bin/rdisk_braun.bin | dd of=bin/rom_braun.bin bs=1 seek=335266 skip=50 conv=notrunc # Copy driver code
|
||||
printf '\x78' | dd of=bin/rom_braun.bin bs=1 seek=335168 count=1 conv=notrunc # Set resource flags
|
||||
printf '\x4F' | dd of=bin/rom_braun.bin bs=1 seek=335216 count=1 conv=notrunc # Set driver flags
|
||||
# Copy entry points
|
||||
cat obj/rdisk_braun_rel.sym | grep "Open" | cut -c5-8 | xxd -r -p - | dd of=bin/rom_braun.bin bs=1 seek=335224 count=2 conv=notrunc
|
||||
cat obj/rdisk_braun_rel.sym | grep "Prime" | cut -c5-8 | xxd -r -p - | dd of=bin/rom_braun.bin bs=1 seek=335226 count=2 conv=notrunc
|
||||
cat obj/rdisk_braun_rel.sym | grep "Control" | cut -c5-8 | xxd -r -p - | dd of=bin/rom_braun.bin bs=1 seek=335228 count=2 conv=notrunc
|
||||
cat obj/rdisk_braun_rel.sym | grep "Status" | cut -c5-8 | xxd -r -p - | dd of=bin/rom_braun.bin bs=1 seek=335230 count=2 conv=notrunc
|
||||
cat obj/rdisk_braun_rel.sym | grep "Close" | cut -c5-8 | xxd -r -p - | dd of=bin/rom_braun.bin bs=1 seek=335232 count=2 conv=notrunc
|
||||
# Copy ROM disk
|
||||
dd if=RDisk1M5 of=bin/rom_braun.bin bs=1024 seek=512 count=1536 conv=notrunc
|
||||
cp baserom_braun_2m_0.9.bin $@ # copy base rom
|
||||
cat bin/rdisk_braun.bin | dd of=$@ bs=1 seek=335266 skip=50 conv=notrunc # Copy driver code
|
||||
printf '\x78' | dd of=$@ bs=1 seek=335168 count=1 conv=notrunc # Set resource flags
|
||||
printf '\x4F' | dd of=$@ bs=1 seek=335216 count=1 conv=notrunc # Set driver flags
|
||||
cat obj/rdisk_braun_rel.sym | grep "Open" | cut -c5-8 | xxd -r -p - | dd of=$@ bs=1 seek=335224 count=2 conv=notrunc
|
||||
cat obj/rdisk_braun_rel.sym | grep "Prime" | cut -c5-8 | xxd -r -p - | dd of=$@ bs=1 seek=335226 count=2 conv=notrunc
|
||||
cat obj/rdisk_braun_rel.sym | grep "Control" | cut -c5-8 | xxd -r -p - | dd of=$@ bs=1 seek=335228 count=2 conv=notrunc
|
||||
cat obj/rdisk_braun_rel.sym | grep "Status" | cut -c5-8 | xxd -r -p - | dd of=$@ bs=1 seek=335230 count=2 conv=notrunc
|
||||
cat obj/rdisk_braun_rel.sym | grep "Close" | cut -c5-8 | xxd -r -p - | dd of=$@ bs=1 seek=335232 count=2 conv=notrunc
|
||||
dd if=RDisk1M5 of=$@ bs=1024 seek=512 count=1536 conv=notrunc # copy disk image
|
||||
|
||||
bin/rom_braun_oldbin.bin: bin bin/rdisk_braun.bin obj/rdisk_braun_rel.sym
|
||||
cp baserom_braun_2m_0.9.bin $@ # copy base rom
|
||||
dd if=RDisk1M5 of=$@ bs=1024 seek=512 count=1536 conv=notrunc # copy disk image
|
||||
|
||||
.PHONY: clean
|
||||
clean:
|
||||
|
Loading…
Reference in New Issue
Block a user