mirror of
https://github.com/hsoft/collapseos.git
synced 2024-12-04 04:48:06 +11:00
tools/emul: make shell's cfsin always have all apps compiled in it
This commit is contained in:
parent
04bf2117b2
commit
f511289a3a
3
tools/emul/.gitignore
vendored
3
tools/emul/.gitignore
vendored
@ -2,5 +2,4 @@
|
||||
/zasm/zasm
|
||||
/runbin/runbin
|
||||
/*/*-bin.h
|
||||
/cfsin
|
||||
/cfsout
|
||||
/cfsin/zasm
|
||||
|
@ -4,9 +4,10 @@ KERNEL = ../../kernel
|
||||
APPS = ../../apps
|
||||
ZASMBIN = zasm/zasm
|
||||
ZASMSH = ../zasm.sh
|
||||
SHELLAPPS = $(addprefix cfsin/, zasm)
|
||||
|
||||
.PHONY: all
|
||||
all: $(TARGETS)
|
||||
all: $(TARGETS) $(SHELLAPPS)
|
||||
|
||||
shell/kernel-bin.h: shell/shell_.asm $(ZASMBIN)
|
||||
$(ZASMSH) $(KERNEL) < $< | ./bin2c.sh KERNEL | tee $@ > /dev/null
|
||||
@ -30,6 +31,9 @@ libz80/libz80.o: libz80/z80.c
|
||||
$(CFSPACK):
|
||||
make -C ../cfspack
|
||||
|
||||
$(SHELLAPPS): $(ZASMBIN)
|
||||
$(ZASMSH) $(KERNEL) $(APPS) shell/user.h < $(APPS)/$(notdir $@)/glue.asm > $@
|
||||
|
||||
.PHONY: updatebootstrap
|
||||
updatebootstrap: $(ZASMBIN) $(INCCFS)
|
||||
$(ZASMSH) $(KERNEL) < zasm/glue.asm > zasm/kernel.bin
|
||||
@ -46,4 +50,4 @@ rescue:
|
||||
|
||||
.PHONY: clean
|
||||
clean:
|
||||
rm -f $(TARGETS) {zasm,shell}/*-bin.h
|
||||
rm -f $(TARGETS) $(SHELLAPPS) {zasm,shell}/*-bin.h
|
||||
|
3
tools/emul/cfsin/readme.txt
Normal file
3
tools/emul/cfsin/readme.txt
Normal file
@ -0,0 +1,3 @@
|
||||
The contents of this folder ends up in the emulated shell's fake block device,
|
||||
mounted as a CFS. The goal of the emulated shell being to tests apps, we compile
|
||||
all apps into this folder for use in the emulated shell.
|
@ -11,6 +11,25 @@
|
||||
jp init
|
||||
|
||||
; *** JUMP TABLE ***
|
||||
jp strncmp
|
||||
jp addDE
|
||||
jp addHL
|
||||
jp upcase
|
||||
jp unsetZ
|
||||
jp intoDE
|
||||
jp intoHL
|
||||
jp writeHLinDE
|
||||
jp findchar
|
||||
jp parseHex
|
||||
jp parseHexPair
|
||||
jp blkSel
|
||||
jp fsFindFN
|
||||
jp fsOpen
|
||||
jp fsGetC
|
||||
jp fsSeek
|
||||
jp fsTell
|
||||
jp cpHLDE
|
||||
jp parseArgs
|
||||
jp printstr
|
||||
|
||||
#include "core.asm"
|
||||
|
25
tools/emul/shell/user.h
Normal file
25
tools/emul/shell/user.h
Normal file
@ -0,0 +1,25 @@
|
||||
.equ USER_CODE 0x9000
|
||||
.equ USER_RAMSTART 0xa800
|
||||
.equ FS_HANDLE_SIZE 8
|
||||
|
||||
; *** JUMP TABLE ***
|
||||
.equ strncmp 0x03
|
||||
.equ addDE 0x06
|
||||
.equ addHL 0x09
|
||||
.equ upcase 0x0c
|
||||
.equ unsetZ 0x0f
|
||||
.equ intoDE 0x12
|
||||
.equ intoHL 0x15
|
||||
.equ writeHLinDE 0x18
|
||||
.equ findchar 0x1b
|
||||
.equ parseHex 0x1e
|
||||
.equ parseHexPair 0x21
|
||||
.equ blkSel 0x24
|
||||
.equ fsFindFN 0x27
|
||||
.equ fsOpen 0x2a
|
||||
.equ fsGetC 0x2d
|
||||
.equ fsSeek 0x30
|
||||
.equ fsTell 0x33
|
||||
.equ cpHLDE 0x36
|
||||
.equ parseArgs 0x39
|
||||
.equ printstr 0x3c
|
Loading…
Reference in New Issue
Block a user