fixed
[bootcard] / Makefile
index e07be2c..7b0705b 100644 (file)
--- a/Makefile
+++ b/Makefile
@@ -1,13 +1,17 @@
 bin = bootcard.img
+com = bootcard.com
 
-QEMU_FLAGS = -soundhw pcspk
+QEMU_FLAGS = -soundhw pcspk -device sb16
 
 $(bin): bootcard.asm
        nasm -f bin -o $@ $<
 
+$(com): bootcard.asm
+       nasm -f bin -o $@ $< -DDOS
+
 .PHONY: clean
 clean:
-       rm -f $(bin)
+       rm -f $(bin) $(com)
 
 .PHONY: run
 run: $(bin)
@@ -20,3 +24,21 @@ debug: $(bin)
 .PHONY: disasm
 disasm: $(bin)
        ndisasm -o 0x7c00 $< >dis
+
+.PHONY: qr
+qr: bootcard.asm
+       qrencode -o qr.png -r bootcard.asm
+
+.PHONY: install
+install: $(bin)
+       dd if=$(bin) of=/dev/sdd bs=512
+
+.PHONY: com
+com: $(com)
+
+.PHONY: rundos
+rundos: $(com)
+       dosbox-x $(com)
+
+tools/gentune: tools/gentune.c
+       $(CC) -o $@ $< $(LDFLAGS)