]> git.proxmox.com Git - mirror_qemu.git/blame - roms/Makefile
linux-user: Handle SOCK_CLOEXEC/NONBLOCK if unavailable on host
[mirror_qemu.git] / roms / Makefile
CommitLineData
b1c0d031 1
b4566776 2vgabios_variants := stdvga cirrus vmware qxl
2397edd7
GH
3pxerom_variants := e1000 eepro100 ne2k_pci pcnet rtl8139 virtio
4
2f3f430d
GH
5pxe-rom-e1000 efi-rom-e1000 : VID := 8086
6pxe-rom-e1000 efi-rom-e1000 : DID := 100e
7pxe-rom-eepro100 efi-rom-eepro100 : VID := 8086
8pxe-rom-eepro100 efi-rom-eepro100 : DID := 1209
9pxe-rom-ne2k_pci efi-rom-ne2k_pci : VID := 1050
10pxe-rom-ne2k_pci efi-rom-ne2k_pci : DID := 0940
11pxe-rom-pcnet efi-rom-pcnet : VID := 1022
12pxe-rom-pcnet efi-rom-pcnet : DID := 2000
13pxe-rom-rtl8139 efi-rom-rtl8139 : VID := 10ec
14pxe-rom-rtl8139 efi-rom-rtl8139 : DID := 8139
15pxe-rom-virtio efi-rom-virtio : VID := 1af4
16pxe-rom-virtio efi-rom-virtio : DID := 1000
17
18#
19# EfiRom utility is shipped with edk2 / tianocore, in BaseTools/
20#
21# We need that to combine multiple images (legacy bios,
22# efi ia32, efi x64) into a single rom binary.
23#
24# We try to find it in the path. You can also pass the location on
25# the command line, i.e. "make EFIROM=/path/to/EfiRom efirom"
26#
27EFIROM ?= $(shell which EfiRom 2>/dev/null)
b4566776 28
b1c0d031
GH
29default:
30 @echo "nothing is build by default"
31 @echo "available build targets:"
32 @echo " bios -- update bios.bin (seabios)"
b4566776
GH
33 @echo " seavgabios -- update vgabios binaries (seabios)"
34 @echo " lgplvgabios -- update vgabios binaries (lgpl)"
2397edd7 35 @echo " pxerom -- update nic roms (bios only)"
2f3f430d
GH
36 @echo " efirom -- update nic roms (bios+efi, this needs"
37 @echo " the EfiRom utility from edk2 / tianocore)"
b1c0d031
GH
38
39bios: config.seabios
40 sh configure-seabios.sh $<
41 make -C seabios out/bios.bin
42 cp seabios/out/bios.bin ../pc-bios/bios.bin
7527bd85 43 cp seabios/out/*dsdt.aml ../pc-bios/
b4566776
GH
44
45seavgabios: $(patsubst %,seavgabios-%,$(vgabios_variants))
46
47seavgabios-%: config.vga.%
48 sh configure-seabios.sh $<
49 make -C seabios out/vgabios.bin
50 cp seabios/out/vgabios.bin ../pc-bios/vgabios-$*.bin
51
52lgplvgabios: $(patsubst %,lgplvgabios-%,$(vgabios_variants))
53
54lgplvgabios-%:
55 make -C vgabios vgabios-$*.bin
56 cp vgabios/VGABIOS-lgpl-latest.$*.bin ../pc-bios/vgabios-$*.bin
2397edd7
GH
57
58pxerom: $(patsubst %,pxe-rom-%,$(pxerom_variants))
59
95ca557d 60pxe-rom-%: ipxe/src/config/local/general.h
2397edd7
GH
61 make -C ipxe/src bin/$(VID)$(DID).rom
62 cp ipxe/src/bin/$(VID)$(DID).rom ../pc-bios/pxe-$*.rom
2f3f430d
GH
63
64efirom: $(patsubst %,efi-rom-%,$(pxerom_variants))
65
95ca557d 66efi-rom-%: ipxe/src/config/local/general.h
2f3f430d
GH
67 make -C ipxe/src bin/$(VID)$(DID).rom
68 make -C ipxe/src bin-i386-efi/$(VID)$(DID).efidrv
69 make -C ipxe/src bin-x86_64-efi/$(VID)$(DID).efidrv
70 $(EFIROM) -f "0x$(VID)" -i "0x$(DID)" -l 0x02 \
71 -b ipxe/src/bin/$(VID)$(DID).rom \
72 -ec ipxe/src/bin-i386-efi/$(VID)$(DID).efidrv \
73 -ec ipxe/src/bin-x86_64-efi/$(VID)$(DID).efidrv \
74 -o ../pc-bios/efi-$*.rom
95ca557d
GH
75
76ipxe/src/config/local/%: config.ipxe.%
77 cp $< $@