forked from TobiasKaiser/ahci_sbe
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathMakefile.own
29 lines (21 loc) · 824 Bytes
/
Makefile.own
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
SRC=main.asm io.asm ahci.asm pmm.asm
do: flash
all: ahci_sbe.qemu.rom ahci_sbe.vbox.rom ahci_sbe.realtek.rom
flash: ahci_sbe.realtek.rom
dd if=/dev/zero of=$< bs=1 count=0 seek=8192
#usbcprog -d /dev/ttyACM0 -t -p 2864 -w $<
minipro -p AT28C64B -w $<
ahci_sbe.qemu.rom: $(SRC) addchecksum
nasm main.asm -fbin -o $@ -dPCI_VENDOR_ID=0x8086 -dPCI_DEVICE_ID=0x100E
./addchecksum $@ || rm $@
ahci_sbe.vbox.rom: $(SRC) addchecksum
nasm main.asm -fbin -o $@ -dPCI_VENDOR_ID=0x1022 -dPCI_DEVICE_ID=0x2000
./addchecksum $@ || rm $@
ahci_sbe.realtek.rom: $(SRC) addchecksum
nasm main.asm -fbin -o $@ -dPCI_VENDOR_ID=0x10EC -dPCI_DEVICE_ID=0x8139
./addchecksum $@ || rm $@
addchecksum: addchecksum.c
gcc -o $@ $< -Wall
.PHONY: clean
clean:
rm -rf addchecksum ahci_sbe.qemu.rom ahci_sbe.vbox.rom ahci_sbe.realtek.rom