works nicely from the floppy
[bootsplash] / Makefile
1 bin = bootsplash.bin
2 img = bootsplash.img
3
4 $(img): $(bin)
5         dd if=/dev/zero of=$@ bs=512 count=2880
6         dd if=$< of=$@ bs=512 conv=notrunc
7
8 $(bin): bootsplash.asm nuclear.rle fire.pal
9         nasm -f bin -o $@ $<
10
11 nuclear.rle: nuclear.img rle/rle
12         cat $< | rle/rle >$@ 2>rle.log
13
14 nuclear.img: nuclear.pgm
15         dd if=$< of=$@ bs=1 skip=61
16
17 fire.pal: fire.ppm
18         dd if=$< of=$@ bs=1 skip=59
19
20 rle/rle:
21         $(MAKE) -C rle
22
23 .PHONY: clean
24 clean:
25         rm -f $(bin)
26
27 .PHONY: run
28 run: $(img)
29         qemu-system-i386 -fda $<
30
31 .PHONY: debug
32 debug: $(img)
33         qemu-system-i386 -S -s -fda $<
34
35 .PHONY: disasm
36 disasm: $(bin)
37         ndisasm -o 0x7c00 $< >dis