2022-04-01 23:10:56 +00:00
|
|
|
|
2023-07-01 18:15:57 +00:00
|
|
|
srcfbfiles = $(wildcard src/*.fb)
|
|
|
|
srcfthfiles = $(patsubst src/%.fb, src/%.fth, $(srcfbfiles))
|
|
|
|
testsfbfiles = $(wildcard tests/*.fb)
|
|
|
|
testsfthfiles = $(patsubst tests/%.fb, tests/%.fth, $(testsfbfiles))
|
|
|
|
fthfiles = $(srcfthfiles) $(testsfthfiles)
|
2022-04-01 23:10:56 +00:00
|
|
|
|
2022-04-30 21:07:46 +00:00
|
|
|
whitch_runcpm = $(shell which RunCPM)
|
|
|
|
runcpmdir = runcpm
|
|
|
|
cpmfilesdir = cpmfiles
|
|
|
|
|
2024-10-08 16:10:53 +00:00
|
|
|
bin: $(cpmfilesdir)/v4th.com
|
|
|
|
|
2022-04-30 21:07:46 +00:00
|
|
|
fth: $(fthfiles)
|
|
|
|
|
|
|
|
clean:
|
2023-07-01 22:11:52 +00:00
|
|
|
rm -f *.log *.golden *.result
|
2022-04-30 21:07:46 +00:00
|
|
|
rm -rf $(runcpmdir)
|
|
|
|
rm -f msdos
|
2024-11-03 12:45:00 +00:00
|
|
|
rm -f $(cpmfilesdir)/empty.f*
|
2022-04-30 21:07:46 +00:00
|
|
|
|
2024-05-10 21:15:02 +00:00
|
|
|
veryclean: clean
|
2024-10-08 16:10:53 +00:00
|
|
|
rm -rf $(cpmfilesdir)
|
2024-05-10 21:15:02 +00:00
|
|
|
|
2024-10-10 20:43:26 +00:00
|
|
|
test: test-min.result test-std.result test-blk.result
|
2024-10-08 20:20:11 +00:00
|
|
|
|
|
|
|
alltests: logtest.result inctest.result test-min.result test-v4th.result
|
2023-07-02 14:43:54 +00:00
|
|
|
|
2022-04-30 21:07:46 +00:00
|
|
|
run-editor: | msdos
|
2023-07-01 18:15:57 +00:00
|
|
|
FORTHPATH="f:\\src;f:\\tests;f:\\msdos" \
|
|
|
|
../../8086/msdos/emulator/run-in-dosbox.sh f:\\msdos\\volks4th.com
|
2022-04-01 23:10:56 +00:00
|
|
|
|
|
|
|
msdos:
|
|
|
|
ln -s ../../8086/msdos msdos
|
|
|
|
|
2023-05-21 20:57:17 +00:00
|
|
|
src/%.fth: src/%.fb ../../tools/fb2fth.py
|
2022-04-01 23:10:56 +00:00
|
|
|
../../tools/fb2fth.py $< $@
|
2022-04-30 21:07:46 +00:00
|
|
|
|
2023-07-01 18:15:57 +00:00
|
|
|
tests/%.fth: tests/%.fb ../../tools/fb2fth.py
|
|
|
|
../../tools/fb2fth.py $< $@
|
|
|
|
|
2023-09-02 19:16:39 +00:00
|
|
|
run-volks4th: \
|
|
|
|
$(patsubst %, $(cpmfilesdir)/%, volks4th.com) \
|
|
|
|
| emu
|
|
|
|
./emulator/run-in-runcpm.sh \
|
|
|
|
"volks4th"
|
|
|
|
|
2023-07-02 21:21:44 +00:00
|
|
|
logtest.log: \
|
2023-09-03 10:56:45 +00:00
|
|
|
$(patsubst %, $(cpmfilesdir)/%, kernel.com fileint.fb log2file.fb) \
|
2023-07-02 21:21:44 +00:00
|
|
|
| emu
|
|
|
|
./emulator/run-in-runcpm.sh \
|
2023-09-03 10:56:45 +00:00
|
|
|
"kernel fileint.fb" \
|
|
|
|
"1 load onlyforth" \
|
2023-07-02 21:21:44 +00:00
|
|
|
"include log2file.fb" \
|
|
|
|
"logopen" \
|
|
|
|
".( hello world) cr" \
|
2023-08-20 19:54:27 +00:00
|
|
|
".( 0123456789abcdef0123456789abcdef) cr" \
|
|
|
|
".( 1123456789abcdef0123456789abcdef) cr" \
|
|
|
|
".( 2123456789abcdef0123456789abcdef) cr" \
|
|
|
|
".( 3123456789abcdef0123456789abcdef) cr" \
|
2023-07-02 21:21:44 +00:00
|
|
|
"logclose" \
|
|
|
|
"bye" \
|
|
|
|
"exit"
|
|
|
|
dos2unix -n $(runcpmdir)/logfile.txt $@
|
|
|
|
|
2023-07-02 09:29:47 +00:00
|
|
|
inctest.log: \
|
2023-09-03 10:56:45 +00:00
|
|
|
$(patsubst %, $(cpmfilesdir)/%, kernel.com fileint.fb \
|
2023-09-02 20:58:20 +00:00
|
|
|
include.fb log2file.fb inctest.fth) \
|
2022-04-30 21:07:46 +00:00
|
|
|
| emu
|
2023-07-02 09:23:26 +00:00
|
|
|
./emulator/run-in-runcpm.sh \
|
2023-09-03 10:56:45 +00:00
|
|
|
"kernel fileint.fb" \
|
|
|
|
"1 load onlyforth" \
|
2023-07-02 09:23:26 +00:00
|
|
|
"include include.fb" \
|
2023-07-02 09:47:08 +00:00
|
|
|
"include log2file.fb" \
|
|
|
|
"logopen" \
|
2023-07-02 09:23:26 +00:00
|
|
|
"include inctest.fth" \
|
2023-07-02 09:47:08 +00:00
|
|
|
"logclose" \
|
2023-09-02 21:10:05 +00:00
|
|
|
"bye" \
|
|
|
|
"exit"
|
|
|
|
dos2unix -n $(runcpmdir)/logfile.txt $@
|
|
|
|
|
2024-11-03 12:45:00 +00:00
|
|
|
$(cpmfilesdir)/tc-base.com: \
|
|
|
|
$(patsubst %, $(cpmfilesdir)/%, kernel.com \
|
2024-11-03 14:11:16 +00:00
|
|
|
fileint.fb ass8080.fb include.fb log2file.fb xinout.fb savesys.fb) \
|
2024-11-03 12:45:00 +00:00
|
|
|
Makefile | emu
|
|
|
|
rm -f $(runcpmdir)/A/0/TC-BASE.COM $@
|
|
|
|
./emulator/run-in-runcpm.sh \
|
|
|
|
"kernel fileint.fb" \
|
|
|
|
"1 load" \
|
2024-11-03 14:11:16 +00:00
|
|
|
"include log2file.fb" \
|
|
|
|
"logopen" \
|
2024-11-03 12:45:00 +00:00
|
|
|
"include ass8080.fb" \
|
2024-11-09 04:50:00 +00:00
|
|
|
".( include xinout.fb) cr" \
|
2024-11-03 12:45:00 +00:00
|
|
|
"include savesys.fb" \
|
2024-11-03 14:11:16 +00:00
|
|
|
"$50 constant /tib" \
|
|
|
|
"include include.fb" \
|
2024-11-03 12:45:00 +00:00
|
|
|
"cr decimal caps on" \
|
|
|
|
"scr off r# off savesystem tc-base.com" \
|
2024-11-03 14:11:16 +00:00
|
|
|
"logclose" \
|
2024-11-03 12:45:00 +00:00
|
|
|
"bye" \
|
|
|
|
"exit"
|
2024-11-03 14:11:16 +00:00
|
|
|
dos2unix -n $(runcpmdir)/logfile.txt $@.log
|
2024-11-03 12:45:00 +00:00
|
|
|
cp -f $(runcpmdir)/A/0/TC-BASE.COM $@
|
|
|
|
|
2024-10-08 16:10:53 +00:00
|
|
|
$(cpmfilesdir)/v4th.com: \
|
2024-11-03 14:14:33 +00:00
|
|
|
$(patsubst %, $(cpmfilesdir)/%, tc-base.com \
|
|
|
|
target.fb v4th.fth vf-core.fth \
|
2024-10-09 02:15:31 +00:00
|
|
|
vf-io.fth vf-bufs.fth vf-sys.fth vf-end.fth vf-bdos.fth) \
|
2024-10-08 20:20:11 +00:00
|
|
|
Makefile | emu
|
2024-11-03 14:14:33 +00:00
|
|
|
rm -f $(runcpmdir)/A/0/V4TH.COM $(runcpmdir)/A/0/LOGFILE.TXT $@
|
2023-09-02 21:10:05 +00:00
|
|
|
./emulator/run-in-runcpm.sh \
|
2024-11-03 14:14:33 +00:00
|
|
|
"tc-base" \
|
2023-09-02 21:10:05 +00:00
|
|
|
"logopen" \
|
|
|
|
"include target.fb" \
|
2024-10-07 20:35:21 +00:00
|
|
|
"include v4th.fth" \
|
2023-09-02 21:10:05 +00:00
|
|
|
"logclose" \
|
2024-11-03 12:45:00 +00:00
|
|
|
"bye" \
|
|
|
|
"exit"
|
|
|
|
dos2unix -n $(runcpmdir)/logfile.txt $@.log
|
|
|
|
cp -f $(runcpmdir)/A/0/V4TH.COM $@
|
|
|
|
|
|
|
|
$(cpmfilesdir)/v4th3.com: \
|
|
|
|
$(patsubst %, $(cpmfilesdir)/%, tc-base.com \
|
2024-11-09 04:50:00 +00:00
|
|
|
target.fb v4th3.fth vf-core.fth vf-io.fth \
|
|
|
|
vf-bufs.fth vf-sys.fth vf-file1.fth vf-end.fth vf-bdos.fth) \
|
2024-11-03 12:45:00 +00:00
|
|
|
Makefile | emu
|
2024-11-03 14:14:33 +00:00
|
|
|
rm -f $(runcpmdir)/A/0/V4TH.COM $(runcpmdir)/A/0/LOGFILE.TXT $@
|
2024-11-03 12:45:00 +00:00
|
|
|
./emulator/run-in-runcpm.sh \
|
|
|
|
"tc-base" \
|
|
|
|
"logopen" \
|
|
|
|
"include target.fb" \
|
2024-11-09 04:50:00 +00:00
|
|
|
"include v4th3.fth" \
|
2024-11-03 12:45:00 +00:00
|
|
|
"logclose" \
|
2023-07-02 09:23:26 +00:00
|
|
|
"bye" \
|
|
|
|
"exit"
|
2024-10-06 20:51:50 +00:00
|
|
|
dos2unix -n $(runcpmdir)/logfile.txt $@.log
|
2024-10-07 20:35:21 +00:00
|
|
|
cp -f $(runcpmdir)/A/0/V4TH.COM $@
|
2023-09-03 11:22:05 +00:00
|
|
|
|
2024-10-07 20:35:21 +00:00
|
|
|
v4th2.com: \
|
2023-11-25 20:07:14 +00:00
|
|
|
$(patsubst %, $(cpmfilesdir)/%, volks4th.com \
|
|
|
|
include.fb log2file.fb target.fb source.fb) \
|
|
|
|
| emu
|
2024-10-08 20:20:11 +00:00
|
|
|
rm -f $(runcpmdir)/A/0/KERNEL.COM $@
|
2023-11-25 20:07:14 +00:00
|
|
|
./emulator/run-in-runcpm.sh \
|
|
|
|
"volks4th" \
|
|
|
|
"include log2file.fb" \
|
|
|
|
"logopen" \
|
|
|
|
"include target.fb" \
|
2023-09-03 11:22:05 +00:00
|
|
|
"include source.fb" \
|
|
|
|
"logclose" \
|
|
|
|
"bye" \
|
|
|
|
"exit"
|
2024-10-07 20:35:21 +00:00
|
|
|
dos2unix -n $(runcpmdir)/logfile.txt $@.log
|
|
|
|
cp $(runcpmdir)/A/0/KERNEL.COM $@
|
2023-11-25 20:07:14 +00:00
|
|
|
|
2024-10-09 19:41:36 +00:00
|
|
|
test-kernel.log: \
|
2023-09-03 10:56:45 +00:00
|
|
|
$(patsubst %, $(cpmfilesdir)/%, kernel.com fileint.fb \
|
2023-09-02 20:58:20 +00:00
|
|
|
include.fb log2file.fb \
|
|
|
|
ans-shim.fth prelim.fth tester.fth core.fr test-min.fth) \
|
2023-09-02 19:16:39 +00:00
|
|
|
| emu
|
|
|
|
./emulator/run-in-runcpm.sh \
|
2023-09-03 10:56:45 +00:00
|
|
|
"kernel fileint.fb" \
|
|
|
|
"1 load onlyforth" \
|
2023-09-02 19:16:39 +00:00
|
|
|
"include include.fb" \
|
|
|
|
"include test-min.fth" \
|
|
|
|
"bye" \
|
|
|
|
"exit"
|
|
|
|
dos2unix -n $(runcpmdir)/logfile.txt $@
|
|
|
|
|
2024-10-09 19:41:36 +00:00
|
|
|
test-min.log: \
|
2024-10-06 20:51:50 +00:00
|
|
|
$(patsubst %, $(cpmfilesdir)/%, v4th.com fileint.fb \
|
|
|
|
include.fb log2file.fb \
|
|
|
|
ans-shim.fth prelim.fth tester.fth core.fr test-min.fth) \
|
|
|
|
| emu
|
|
|
|
./emulator/run-in-runcpm.sh \
|
|
|
|
"v4th fileint.fb" \
|
|
|
|
"1 load onlyforth" \
|
|
|
|
"include include.fb" \
|
|
|
|
"include test-min.fth" \
|
|
|
|
"bye" \
|
|
|
|
"exit"
|
|
|
|
dos2unix -n $(runcpmdir)/logfile.txt $@
|
|
|
|
|
2024-10-09 19:41:36 +00:00
|
|
|
test-std.log: \
|
|
|
|
$(patsubst %, $(cpmfilesdir)/%, v4th.com fileint.fb \
|
|
|
|
include.fb log2file.fb core.fr) \
|
|
|
|
$(patsubst tests/%, $(cpmfilesdir)/%, $(wildcard tests/*.fth)) \
|
|
|
|
| emu
|
|
|
|
./emulator/run-in-runcpm.sh \
|
|
|
|
"v4th fileint.fb" \
|
|
|
|
"1 load onlyforth" \
|
|
|
|
"include include.fb" \
|
|
|
|
"include test-std.fth" \
|
|
|
|
"bye" \
|
|
|
|
"exit"
|
|
|
|
dos2unix -n $(runcpmdir)/logfile.txt $@
|
|
|
|
|
2024-10-10 20:43:26 +00:00
|
|
|
test-blk.log: \
|
|
|
|
$(patsubst %, $(cpmfilesdir)/%, v4th.com fileint.fb \
|
|
|
|
include.fb log2file.fb core.fr) \
|
|
|
|
$(patsubst tests/%, $(cpmfilesdir)/%, $(wildcard tests/*.fth) \
|
|
|
|
tests/empty.fb) | emu
|
|
|
|
./emulator/run-in-runcpm.sh \
|
|
|
|
"v4th fileint.fb" \
|
|
|
|
"1 load onlyforth" \
|
|
|
|
"include include.fb" \
|
|
|
|
"include test-blk.fth" \
|
|
|
|
"bye" \
|
|
|
|
"exit"
|
|
|
|
dos2unix -n $(runcpmdir)/logfile.txt $@
|
|
|
|
|
2024-11-09 04:50:00 +00:00
|
|
|
test3.log: \
|
|
|
|
$(patsubst %, $(cpmfilesdir)/%, v4th3.com fileint.fb \
|
|
|
|
include.fb log2file.fb core.fr) \
|
|
|
|
$(patsubst tests/%, $(cpmfilesdir)/%, $(wildcard tests/*.fth) \
|
|
|
|
tests/empty.fb) | emu
|
|
|
|
./emulator/run-in-runcpm.sh \
|
|
|
|
"v4th3 fileint.fb" \
|
|
|
|
"1 load onlyforth" \
|
|
|
|
"use include.fb" \
|
|
|
|
"onlyforth dos also forth definitions" \
|
2024-11-09 05:15:25 +00:00
|
|
|
"\ ' read-seq alias iread-seq" \
|
|
|
|
"7 8 thru" \
|
2024-11-09 04:50:00 +00:00
|
|
|
"include test-blk.fth" \
|
|
|
|
"bye" \
|
|
|
|
"exit"
|
|
|
|
dos2unix -n $(runcpmdir)/logfile.txt $@
|
|
|
|
|
2022-04-30 21:07:46 +00:00
|
|
|
emu: $(runcpmdir)/RunCPM
|
|
|
|
|
2023-09-02 19:40:10 +00:00
|
|
|
test-min.golden: $(patsubst %, tests/golden/%.golden, prelim core)
|
|
|
|
cat $^ > $@
|
|
|
|
|
2024-10-09 19:41:36 +00:00
|
|
|
test-std.golden: $(patsubst %, tests/golden/%.golden, \
|
|
|
|
prelim core coreplus coreext doubltst report-noblk)
|
|
|
|
cat $^ > $@
|
|
|
|
|
|
|
|
test-blk.golden: $(patsubst %, tests/golden/%.golden, \
|
|
|
|
prelim core coreplus coreext doubltst block report-blk)
|
|
|
|
cat $^ > $@
|
|
|
|
|
2024-11-09 04:50:00 +00:00
|
|
|
test3.golden: $(patsubst %, tests/golden/%.golden, \
|
|
|
|
prelim core coreplus coreext doubltst block report-blk)
|
|
|
|
cat $^ > $@
|
|
|
|
|
2024-10-09 19:41:36 +00:00
|
|
|
test-kernel.golden: $(patsubst %, tests/golden/%.golden, prelim core)
|
2024-10-06 20:51:50 +00:00
|
|
|
cat $^ > $@
|
|
|
|
|
2023-07-01 22:11:52 +00:00
|
|
|
%.golden: tests/golden/%.golden
|
|
|
|
cp -p $< $@
|
|
|
|
|
|
|
|
%.result: %.log %.golden tests/evaluate-test.sh
|
|
|
|
rm -f $@
|
|
|
|
tests/evaluate-test.sh $(basename $@)
|
|
|
|
|
2022-04-30 21:07:46 +00:00
|
|
|
$(runcpmdir)/RunCPM: $(whitch_runcpm)
|
|
|
|
test -d $(runcpmdir) || mkdir -p $(runcpmdir)
|
|
|
|
cp $< $@
|
|
|
|
|
2023-05-21 20:48:35 +00:00
|
|
|
$(cpmfilesdir)/%: src/%
|
|
|
|
test -d $(cpmfilesdir) || mkdir -p $(cpmfilesdir)
|
|
|
|
cp $< $@
|
|
|
|
|
2023-07-01 18:15:57 +00:00
|
|
|
$(cpmfilesdir)/%: tests/%
|
|
|
|
test -d $(cpmfilesdir) || mkdir -p $(cpmfilesdir)
|
|
|
|
cp $< $@
|
|
|
|
|
2022-04-30 21:07:46 +00:00
|
|
|
$(cpmfilesdir)/%: %
|
|
|
|
test -d $(cpmfilesdir) || mkdir -p $(cpmfilesdir)
|
|
|
|
cp $< $@
|