annotate Makefile @ 80:bb50ac9fdf37

Checkpoint with very basic integer and floating point arithmetic, untested This commit has implementations for floating point add, subtract, multiply, and divide, along with 32 bit signed integer equivalents. These can probably be optimized and they are untested.
author William Astle <lost@l-w.ca>
date Sat, 07 Oct 2023 02:56:59 -0600
parents eb2681108660
children f1d847f69c0d
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
2
19eac734a518 Makefile to actually build something with initial start to ROM init code
William Astle <lost@l-w.ca>
parents:
diff changeset
1 .PHONY: all
19eac734a518 Makefile to actually build something with initial start to ROM init code
William Astle <lost@l-w.ca>
parents:
diff changeset
2 all: bin/lwbasic.rom bin/lwbasic-coco2b.rom bin/lwbasic-coco3.rom bin/coco2.zip bin/coco2b.zip bin/coco3.zip
19eac734a518 Makefile to actually build something with initial start to ROM init code
William Astle <lost@l-w.ca>
parents:
diff changeset
3
80
bb50ac9fdf37 Checkpoint with very basic integer and floating point arithmetic, untested
William Astle <lost@l-w.ca>
parents: 76
diff changeset
4 lwb_srcs := consscr.s defs.s error.s expr.s fps.s genio.s init.s int.s interp.s irq.s keyb.s keywords.s miscdata.s number.s print.s progctrl.s token.s vars.s
74
e74d00ac6b79 Split some code into separate files for easier management (2)
William Astle <lost@l-w.ca>
parents: 67
diff changeset
5 lwb_srcs := $(addprefix src/,$(lwb_srcs))
e74d00ac6b79 Split some code into separate files for easier management (2)
William Astle <lost@l-w.ca>
parents: 67
diff changeset
6
e74d00ac6b79 Split some code into separate files for easier management (2)
William Astle <lost@l-w.ca>
parents: 67
diff changeset
7 bin/lwbasic.rom: src/lwbasic.s $(lwb_srcs)
80
bb50ac9fdf37 Checkpoint with very basic integer and floating point arithmetic, untested
William Astle <lost@l-w.ca>
parents: 76
diff changeset
8 lwasm --6809 --tabs=16 --raw --list=src/lwbasic-coco2.list --symbols --output=bin/lwbasic.rom src/lwbasic.s
74
e74d00ac6b79 Split some code into separate files for easier management (2)
William Astle <lost@l-w.ca>
parents: 67
diff changeset
9 bin/lwbasic-coco2b.rom: src/lwbasic.s $(lwb_srcs)
80
bb50ac9fdf37 Checkpoint with very basic integer and floating point arithmetic, untested
William Astle <lost@l-w.ca>
parents: 76
diff changeset
10 lwasm --6809 --tabs=16 --raw --list=src/lwbasic-coco2b.list --symbols --output=bin/lwbasic-coco2b.rom -DCOCO2B=1 src/lwbasic.s
74
e74d00ac6b79 Split some code into separate files for easier management (2)
William Astle <lost@l-w.ca>
parents: 67
diff changeset
11 bin/lwbasic-coco3.rom: src/lwbasic.s $(lwb_srcs)
80
bb50ac9fdf37 Checkpoint with very basic integer and floating point arithmetic, untested
William Astle <lost@l-w.ca>
parents: 76
diff changeset
12 lwasm --6809 --tabs=16 --raw --list=src/lwbasic-coco3.list --symbols --output=bin/lwbasic-coco3.rom -DCOCO3=1 src/lwbasic.s
2
19eac734a518 Makefile to actually build something with initial start to ROM init code
William Astle <lost@l-w.ca>
parents:
diff changeset
13
19eac734a518 Makefile to actually build something with initial start to ROM init code
William Astle <lost@l-w.ca>
parents:
diff changeset
14 .PHONY: clean
19eac734a518 Makefile to actually build something with initial start to ROM init code
William Astle <lost@l-w.ca>
parents:
diff changeset
15 clean:
19eac734a518 Makefile to actually build something with initial start to ROM init code
William Astle <lost@l-w.ca>
parents:
diff changeset
16 rm -f bin/*.rom bin/*.zip
19eac734a518 Makefile to actually build something with initial start to ROM init code
William Astle <lost@l-w.ca>
parents:
diff changeset
17 rm -f src/*.list
19eac734a518 Makefile to actually build something with initial start to ROM init code
William Astle <lost@l-w.ca>
parents:
diff changeset
18 rm -f */*~ *~
19eac734a518 Makefile to actually build something with initial start to ROM init code
William Astle <lost@l-w.ca>
parents:
diff changeset
19
19eac734a518 Makefile to actually build something with initial start to ROM init code
William Astle <lost@l-w.ca>
parents:
diff changeset
20 bin/coco2.zip: bin/lwbasic.rom
19eac734a518 Makefile to actually build something with initial start to ROM init code
William Astle <lost@l-w.ca>
parents:
diff changeset
21 mkdir -p coco2
19eac734a518 Makefile to actually build something with initial start to ROM init code
William Astle <lost@l-w.ca>
parents:
diff changeset
22 rm -f coco2/* coco2.zip
19eac734a518 Makefile to actually build something with initial start to ROM init code
William Astle <lost@l-w.ca>
parents:
diff changeset
23 dd if=bin/lwbasic.rom of=coco2/extbas11.rom bs=1024 count=8
19eac734a518 Makefile to actually build something with initial start to ROM init code
William Astle <lost@l-w.ca>
parents:
diff changeset
24 dd if=bin/lwbasic.rom of=coco2/bas12.rom bs=1024 count=8 skip=8
19eac734a518 Makefile to actually build something with initial start to ROM init code
William Astle <lost@l-w.ca>
parents:
diff changeset
25 dd if=bin/lwbasic.rom of=coco2/disk11.rom bs=1024 count=16 skip=16
19eac734a518 Makefile to actually build something with initial start to ROM init code
William Astle <lost@l-w.ca>
parents:
diff changeset
26 zip bin/coco2.zip coco2/extbas11.rom coco2/bas12.rom coco2/disk11.rom
19eac734a518 Makefile to actually build something with initial start to ROM init code
William Astle <lost@l-w.ca>
parents:
diff changeset
27 rm -rf coco2
19eac734a518 Makefile to actually build something with initial start to ROM init code
William Astle <lost@l-w.ca>
parents:
diff changeset
28
19eac734a518 Makefile to actually build something with initial start to ROM init code
William Astle <lost@l-w.ca>
parents:
diff changeset
29 bin/coco2b.zip: bin/lwbasic-coco2b.rom
19eac734a518 Makefile to actually build something with initial start to ROM init code
William Astle <lost@l-w.ca>
parents:
diff changeset
30 mkdir -p coco2b
19eac734a518 Makefile to actually build something with initial start to ROM init code
William Astle <lost@l-w.ca>
parents:
diff changeset
31 rm -f coco2b/* coco2b.zip
19eac734a518 Makefile to actually build something with initial start to ROM init code
William Astle <lost@l-w.ca>
parents:
diff changeset
32 dd if=bin/lwbasic-coco2b.rom of=coco2b/extbas11.rom bs=1024 count=8
19eac734a518 Makefile to actually build something with initial start to ROM init code
William Astle <lost@l-w.ca>
parents:
diff changeset
33 dd if=bin/lwbasic-coco2b.rom of=coco2b/bas13.rom bs=1024 count=8 skip=8
19eac734a518 Makefile to actually build something with initial start to ROM init code
William Astle <lost@l-w.ca>
parents:
diff changeset
34 dd if=bin/lwbasic-coco2b.rom of=coco2b/disk11.rom bs=1024 count=16 skip=16
19eac734a518 Makefile to actually build something with initial start to ROM init code
William Astle <lost@l-w.ca>
parents:
diff changeset
35 zip bin/coco2b.zip coco2b/extbas11.rom coco2b/bas13.rom coco2b/disk11.rom
19eac734a518 Makefile to actually build something with initial start to ROM init code
William Astle <lost@l-w.ca>
parents:
diff changeset
36 rm -rf coco2b
19eac734a518 Makefile to actually build something with initial start to ROM init code
William Astle <lost@l-w.ca>
parents:
diff changeset
37
19eac734a518 Makefile to actually build something with initial start to ROM init code
William Astle <lost@l-w.ca>
parents:
diff changeset
38 bin/coco3.zip: bin/lwbasic-coco3.rom
19eac734a518 Makefile to actually build something with initial start to ROM init code
William Astle <lost@l-w.ca>
parents:
diff changeset
39 mkdir -p coco3
19eac734a518 Makefile to actually build something with initial start to ROM init code
William Astle <lost@l-w.ca>
parents:
diff changeset
40 rm -f coco3/* coco3.zip
19eac734a518 Makefile to actually build something with initial start to ROM init code
William Astle <lost@l-w.ca>
parents:
diff changeset
41 dd if=bin/lwbasic-coco3.rom of=coco3/coco3.rom bs=1024 count=32
19eac734a518 Makefile to actually build something with initial start to ROM init code
William Astle <lost@l-w.ca>
parents:
diff changeset
42 dd if=/dev/null of=coco3/disk11.rom bs=1024 count=8
19eac734a518 Makefile to actually build something with initial start to ROM init code
William Astle <lost@l-w.ca>
parents:
diff changeset
43 zip bin/coco3.zip coco3/coco3.rom coco3/disk11.rom
19eac734a518 Makefile to actually build something with initial start to ROM init code
William Astle <lost@l-w.ca>
parents:
diff changeset
44 rm -rf coco3
19eac734a518 Makefile to actually build something with initial start to ROM init code
William Astle <lost@l-w.ca>
parents:
diff changeset
45
9
f9ec351dd82b Add Makefile rules for running the Coco 3 ROM in MAME
William Astle <lost@l-w.ca>
parents: 2
diff changeset
46 .PHONY: mame2 mame2d
2
19eac734a518 Makefile to actually build something with initial start to ROM init code
William Astle <lost@l-w.ca>
parents:
diff changeset
47 mame2: bin/coco2.zip
19eac734a518 Makefile to actually build something with initial start to ROM init code
William Astle <lost@l-w.ca>
parents:
diff changeset
48 mame coco2 -skip_gameinfo -rompath ./bin
19eac734a518 Makefile to actually build something with initial start to ROM init code
William Astle <lost@l-w.ca>
parents:
diff changeset
49 mame2d: bin/coco2.zip
19eac734a518 Makefile to actually build something with initial start to ROM init code
William Astle <lost@l-w.ca>
parents:
diff changeset
50 mame coco2 -skip_gameinfo -rompath ./bin -debug
9
f9ec351dd82b Add Makefile rules for running the Coco 3 ROM in MAME
William Astle <lost@l-w.ca>
parents: 2
diff changeset
51
f9ec351dd82b Add Makefile rules for running the Coco 3 ROM in MAME
William Astle <lost@l-w.ca>
parents: 2
diff changeset
52 .PHONY: mame3 mame3d
f9ec351dd82b Add Makefile rules for running the Coco 3 ROM in MAME
William Astle <lost@l-w.ca>
parents: 2
diff changeset
53 mame3: bin/coco3.zip
f9ec351dd82b Add Makefile rules for running the Coco 3 ROM in MAME
William Astle <lost@l-w.ca>
parents: 2
diff changeset
54 mame coco3 -skip_gameinfo -rompath ./bin
f9ec351dd82b Add Makefile rules for running the Coco 3 ROM in MAME
William Astle <lost@l-w.ca>
parents: 2
diff changeset
55 mame3d: bin/coco3.zip
f9ec351dd82b Add Makefile rules for running the Coco 3 ROM in MAME
William Astle <lost@l-w.ca>
parents: 2
diff changeset
56 mame coco3 -skip_gameinfo -rompath ./bin -debug
67
9c2e66ef5fa1 Clean up weirdness in coco2/2b targets
William Astle <lost@l-w.ca>
parents: 28
diff changeset
57
9c2e66ef5fa1 Clean up weirdness in coco2/2b targets
William Astle <lost@l-w.ca>
parents: 28
diff changeset
58 .PHONY: mame2b mame2bd
9c2e66ef5fa1 Clean up weirdness in coco2/2b targets
William Astle <lost@l-w.ca>
parents: 28
diff changeset
59 mame2b: bin/coco2b.zip
9c2e66ef5fa1 Clean up weirdness in coco2/2b targets
William Astle <lost@l-w.ca>
parents: 28
diff changeset
60 mame coco2b -skip_gameinfo -rompath ./bin
9c2e66ef5fa1 Clean up weirdness in coco2/2b targets
William Astle <lost@l-w.ca>
parents: 28
diff changeset
61 mame2bd: bin/coco2b.zip
9c2e66ef5fa1 Clean up weirdness in coco2/2b targets
William Astle <lost@l-w.ca>
parents: 28
diff changeset
62 mame coco2b -skip_gameinfo -rompath ./bin -debug