1366f6083SPeter Grehan# 2366f6083SPeter Grehan# $FreeBSD$ 3366f6083SPeter Grehan# 4366f6083SPeter Grehan 5f4d34383SMarcelo Araujo.include <src.opts.mk> 6f9c005a1SMarcelo AraujoCFLAGS+=-I${SRCTOP}/sys 7f9c005a1SMarcelo Araujo.PATH: ${SRCTOP}/sys/cam/ctl 8f4d34383SMarcelo Araujo 9366f6083SPeter GrehanPROG= bhyve 10c2e2d02cSBaptiste DaroussinPACKAGE= bhyve 11366f6083SPeter Grehan 12b13e60daSPeter GrehanMAN= bhyve.8 13b1843e71SPeter Grehan 14e37bf586SPeter GrehanBHYVE_SYSDIR?=${SRCTOP} 155ccf6ce1SPeter Grehan 16b1843e71SPeter GrehanSRCS= \ 17d42ea573STycho Nightingale atkbdc.c \ 18b1843e71SPeter Grehan acpi.c \ 196b021cc2SWarner Losh audio.c \ 202cf9911fSPeter Grehan bhyvegc.c \ 21b1843e71SPeter Grehan bhyverun.c \ 22b1843e71SPeter Grehan block_if.c \ 239b1aa8d6SNeel Natu bootrom.c \ 242cf9911fSPeter Grehan console.c \ 25b1843e71SPeter Grehan consport.c \ 26f9c005a1SMarcelo Araujo ctl_util.c \ 27f9c005a1SMarcelo Araujo ctl_scsi_all.c \ 28b1843e71SPeter Grehan dbgport.c \ 2988ac6958SPeter Grehan fwctl.c \ 30cd377eb3SJohn Baldwin gdb.c \ 316b021cc2SWarner Losh hda_codec.c \ 32b1843e71SPeter Grehan inout.c \ 333cbf3585SJohn Baldwin ioapic.c \ 34b1843e71SPeter Grehan mem.c \ 35b1843e71SPeter Grehan mevent.c \ 36b1843e71SPeter Grehan mptbl.c \ 370ff7076bSVincenzo Maffione net_backends.c \ 384f7c3b7bSVincenzo Maffione net_utils.c \ 39b1843e71SPeter Grehan pci_ahci.c \ 409e749f25SAlexander Motin pci_e82545.c \ 41b1843e71SPeter Grehan pci_emul.c \ 426b021cc2SWarner Losh pci_hda.c \ 432cf9911fSPeter Grehan pci_fbuf.c \ 44b1843e71SPeter Grehan pci_hostbridge.c \ 45b3e9732aSJohn Baldwin pci_irq.c \ 46b1843e71SPeter Grehan pci_lpc.c \ 47c066c68cSMarcelo Araujo pci_nvme.c \ 48b1843e71SPeter Grehan pci_passthru.c \ 49b1843e71SPeter Grehan pci_virtio_block.c \ 5013ee8ddeSJakub Wojciech Klama pci_virtio_console.c \ 51b1843e71SPeter Grehan pci_virtio_net.c \ 529d0c4e17SPeter Grehan pci_virtio_rnd.c \ 53f9c005a1SMarcelo Araujo pci_virtio_scsi.c \ 54b1843e71SPeter Grehan pci_uart.c \ 552cf9911fSPeter Grehan pci_xhci.c \ 56b1843e71SPeter Grehan pm.c \ 57b1843e71SPeter Grehan post.c \ 582cf9911fSPeter Grehan ps2kbd.c \ 592cf9911fSPeter Grehan ps2mouse.c \ 602cf9911fSPeter Grehan rfb.c \ 61b1843e71SPeter Grehan rtc.c \ 62af5bfc53STycho Nightingale smbiostbl.c \ 632cf9911fSPeter Grehan sockstream.c \ 643d5444c8SNeel Natu task_switch.c \ 65b1843e71SPeter Grehan uart_emul.c \ 662cf9911fSPeter Grehan usb_emul.c \ 672cf9911fSPeter Grehan usb_mouse.c \ 68b1843e71SPeter Grehan virtio.c \ 692cf9911fSPeter Grehan vga.c \ 709cb339ccSConrad Meyer vmgenc.c \ 71b1843e71SPeter Grehan xmsr.c \ 72f9c005a1SMarcelo Araujo spinup_ap.c \ 73f9c005a1SMarcelo Araujo iov.c 74366f6083SPeter Grehan 75*483d953aSJohn Baldwin.if ${MK_BHYVE_SNAPSHOT} != "no" 76*483d953aSJohn BaldwinSRCS+= snapshot.c 77*483d953aSJohn Baldwin.endif 78*483d953aSJohn Baldwin 79e37bf586SPeter Grehan.PATH: ${BHYVE_SYSDIR}/sys/amd64/vmm 80ba9b7bf7SNeel NatuSRCS+= vmm_instruction_emul.c 81ba9b7bf7SNeel Natu 82f9c005a1SMarcelo AraujoLIBADD= vmmapi md pthread z util sbuf cam 83*483d953aSJohn Baldwin.if ${MK_BHYVE_SNAPSHOT} != "no" 84*483d953aSJohn BaldwinLIBADD+= ucl xo 85*483d953aSJohn Baldwin.endif 862cf9911fSPeter Grehan 878883128bSBjoern A. Zeeb.if ${MK_INET_SUPPORT} != "no" 888883128bSBjoern A. ZeebCFLAGS+=-DINET 898883128bSBjoern A. Zeeb.endif 908883128bSBjoern A. Zeeb.if ${MK_INET6_SUPPORT} != "no" 918883128bSBjoern A. ZeebCFLAGS+=-DINET6 928883128bSBjoern A. Zeeb.endif 93f4d34383SMarcelo Araujo.if ${MK_OPENSSL} == "no" 94f4d34383SMarcelo AraujoCFLAGS+=-DNO_OPENSSL 95f4d34383SMarcelo Araujo.else 96f4d34383SMarcelo AraujoLIBADD+= crypto 97f4d34383SMarcelo Araujo.endif 98f4d34383SMarcelo Araujo 999e749f25SAlexander MotinCFLAGS+= -I${BHYVE_SYSDIR}/sys/dev/e1000 1009e749f25SAlexander MotinCFLAGS+= -I${BHYVE_SYSDIR}/sys/dev/mii 1012cf9911fSPeter GrehanCFLAGS+= -I${BHYVE_SYSDIR}/sys/dev/usb/controller 102*483d953aSJohn Baldwin.if ${MK_BHYVE_SNAPSHOT} != "no" 103*483d953aSJohn BaldwinCFLAGS+= -I${SRCTOP}/contrib/libucl/include 104*483d953aSJohn Baldwin 105*483d953aSJohn Baldwin# Temporary disable capsicum, until we integrate checkpoint code with it. 106*483d953aSJohn BaldwinCFLAGS+= -DWITHOUT_CAPSICUM 107*483d953aSJohn Baldwin 108*483d953aSJohn BaldwinCFLAGS+= -DBHYVE_SNAPSHOT 109*483d953aSJohn Baldwin.endif 110366f6083SPeter Grehan 111cd377eb3SJohn Baldwin.ifdef GDB_LOG 112cd377eb3SJohn BaldwinCFLAGS+=-DGDB_LOG 113cd377eb3SJohn Baldwin.endif 114cd377eb3SJohn Baldwin 115b67e81dbSJohn BaldwinWARNS?= 2 116b67e81dbSJohn Baldwin 117366f6083SPeter Grehan.include <bsd.prog.mk> 118