1# 2# $FreeBSD$ 3# 4 5.include <src.opts.mk> 6CFLAGS+=-I${.CURDIR}/../../contrib/lib9p 7CFLAGS+=-I${SRCTOP}/sys 8.PATH: ${SRCTOP}/sys/cam/ctl 9 10PROG= bhyve 11PACKAGE= bhyve 12 13MAN= bhyve.8 bhyve_config.5 14 15BHYVE_SYSDIR?=${SRCTOP} 16 17SRCS= \ 18 atkbdc.c \ 19 acpi.c \ 20 audio.c \ 21 bhyvegc.c \ 22 bhyverun.c \ 23 block_if.c \ 24 bootrom.c \ 25 config.c \ 26 console.c \ 27 ctl_util.c \ 28 ctl_scsi_all.c \ 29 fwctl.c \ 30 gdb.c \ 31 hda_codec.c \ 32 inout.c \ 33 ioapic.c \ 34 kernemu_dev.c \ 35 mem.c \ 36 mevent.c \ 37 mptbl.c \ 38 net_backends.c \ 39 net_utils.c \ 40 pci_ahci.c \ 41 pci_e82545.c \ 42 pci_emul.c \ 43 pci_hda.c \ 44 pci_fbuf.c \ 45 pci_hostbridge.c \ 46 pci_irq.c \ 47 pci_lpc.c \ 48 pci_nvme.c \ 49 pci_passthru.c \ 50 pci_virtio_9p.c \ 51 pci_virtio_block.c \ 52 pci_virtio_console.c \ 53 pci_virtio_net.c \ 54 pci_virtio_rnd.c \ 55 pci_virtio_scsi.c \ 56 pci_uart.c \ 57 pci_xhci.c \ 58 pctestdev.c \ 59 pm.c \ 60 post.c \ 61 ps2kbd.c \ 62 ps2mouse.c \ 63 rfb.c \ 64 rtc.c \ 65 smbiostbl.c \ 66 sockstream.c \ 67 task_switch.c \ 68 uart_emul.c \ 69 usb_emul.c \ 70 usb_mouse.c \ 71 virtio.c \ 72 vga.c \ 73 vmgenc.c \ 74 xmsr.c \ 75 spinup_ap.c \ 76 iov.c 77 78.if ${MK_BHYVE_SNAPSHOT} != "no" 79SRCS+= snapshot.c 80.endif 81 82CFLAGS.kernemu_dev.c+= -I${SRCTOP}/sys/amd64 83 84.PATH: ${BHYVE_SYSDIR}/sys/amd64/vmm 85SRCS+= vmm_instruction_emul.c 86 87LIBADD= vmmapi md nv pthread z util sbuf cam 9p 88 89.if ${MK_CASPER} != "no" 90LIBADD+= casper 91LIBADD+= cap_pwd 92LIBADD+= cap_grp 93# Temporary disable capsicum, until we integrate checkpoint code with it. 94#CFLAGS+=-DWITH_CASPER 95.endif 96 97.if ${MK_BHYVE_SNAPSHOT} != "no" 98LIBADD+= ucl xo 99.endif 100 101.if ${MK_INET_SUPPORT} != "no" 102CFLAGS+=-DINET 103.endif 104.if ${MK_INET6_SUPPORT} != "no" 105CFLAGS+=-DINET6 106.endif 107.if ${MK_NETGRAPH_SUPPORT} != "no" 108CFLAGS+=-DNETGRAPH 109LIBADD+= netgraph 110.endif 111.if ${MK_OPENSSL} == "no" 112CFLAGS+=-DNO_OPENSSL 113.else 114LIBADD+= crypto 115.endif 116 117CFLAGS+= -I${BHYVE_SYSDIR}/sys/dev/e1000 118CFLAGS+= -I${BHYVE_SYSDIR}/sys/dev/mii 119CFLAGS+= -I${BHYVE_SYSDIR}/sys/dev/usb/controller 120.if ${MK_BHYVE_SNAPSHOT} != "no" 121CFLAGS+= -I${SRCTOP}/contrib/libucl/include 122 123# Temporary disable capsicum, until we integrate checkpoint code with it. 124CFLAGS+= -DWITHOUT_CAPSICUM 125 126CFLAGS+= -DBHYVE_SNAPSHOT 127.endif 128 129.ifdef GDB_LOG 130CFLAGS+=-DGDB_LOG 131.endif 132 133WARNS?= 2 134 135.include <bsd.prog.mk> 136