mirror of
https://github.com/ksherlock/hfs-boot.git
synced 2025-01-02 18:29:59 +00:00
copy the loader onto the disk.
This commit is contained in:
parent
5c21bd0790
commit
c485c299a5
10
Makefile
10
Makefile
@ -1,12 +1,14 @@
|
|||||||
|
|
||||||
|
.PHONY: all
|
||||||
|
all : bootblock loader
|
||||||
|
|
||||||
bootblock : bootblock.omf hfs.po
|
bootblock : bootblock.omf | hfs.po
|
||||||
mpw makebiniigs -s -org 2048 bootblock.omf -o bootblock
|
mpw makebiniigs -s -org 2048 bootblock.omf -o bootblock
|
||||||
dd bs=512 if=bootblock of=hfs.po conv=notrunc oseek=0
|
dd bs=512 if=bootblock of=hfs.po conv=notrunc oseek=0
|
||||||
|
|
||||||
loader : loader.omf
|
loader : loader.omf | hfs.po
|
||||||
mpw makebiniigs -s -org 8192 loader.omf -o loader
|
mpw makebiniigs -s -org 8192 loader.omf -o loader
|
||||||
|
sh cp-loader.sh
|
||||||
|
|
||||||
# bootblock.omf : bootblock.obj
|
# bootblock.omf : bootblock.obj
|
||||||
# mpw linkiigs bootblock.obj -o bootblock.omf
|
# mpw linkiigs bootblock.obj -o bootblock.omf
|
||||||
@ -20,7 +22,7 @@ loader.obj : loader.aii hfs.aii macros.aii
|
|||||||
|
|
||||||
.PHONY: clean
|
.PHONY: clean
|
||||||
clean:
|
clean:
|
||||||
$(RM) bootblock bootblock.omf bootblock.obj
|
$(RM) bootblock bootblock.omf bootblock.obj loader loader.omf loader.obj
|
||||||
|
|
||||||
hfs.po:
|
hfs.po:
|
||||||
mkfs-profuse --fst=hfs --size=800k --name="hfs boot" hfs.po
|
mkfs-profuse --fst=hfs --size=800k --name="hfs boot" hfs.po
|
||||||
|
5
cp-loader.sh
Normal file
5
cp-loader.sh
Normal file
@ -0,0 +1,5 @@
|
|||||||
|
|
||||||
|
export dir=`mktemp -d`
|
||||||
|
profuse -orw --fst=hfs hfs.po "$dir"
|
||||||
|
cp loader "$dir/"\!
|
||||||
|
umount "$dir"
|
12
loader.aii
12
loader.aii
@ -2,6 +2,9 @@
|
|||||||
;
|
;
|
||||||
; loader
|
; loader
|
||||||
;
|
;
|
||||||
|
; currently limited to 512-byte blocks (64MB max filesystem)
|
||||||
|
; need to use smartport protocol to use > 65535 blocks anyhow.
|
||||||
|
;
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
@ -29,7 +32,7 @@ r3 ds.w 1
|
|||||||
|
|
||||||
; readfile
|
; readfile
|
||||||
eof ds.l 1
|
eof ds.l 1
|
||||||
blocks ds.w 1 ; shouldn't exceed...
|
blocks ds.w 1 ; shouldn't exceed $ffff blocks
|
||||||
ft ds.w 1
|
ft ds.w 1
|
||||||
at ds.w 1
|
at ds.w 1
|
||||||
st ds.w 1
|
st ds.w 1
|
||||||
@ -907,6 +910,13 @@ startup proc
|
|||||||
txs
|
txs
|
||||||
|
|
||||||
|
|
||||||
|
lda #buffer
|
||||||
|
sta pro.buffer
|
||||||
|
short m
|
||||||
|
lda #1
|
||||||
|
sta pro.cmd
|
||||||
|
long m
|
||||||
|
|
||||||
with HFSMasterDirectoryBlock
|
with HFSMasterDirectoryBlock
|
||||||
lda #2
|
lda #2
|
||||||
jsr read_block_abs
|
jsr read_block_abs
|
||||||
|
Loading…
Reference in New Issue
Block a user