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_input.c \ 54 pci_virtio_net.c \ 55 pci_virtio_rnd.c \ 56 pci_virtio_scsi.c \ 57 pci_uart.c \ 58 pci_xhci.c \ 59 pctestdev.c \ 60 pm.c \ 61 post.c \ 62 ps2kbd.c \ 63 ps2mouse.c \ 64 rfb.c \ 65 rtc.c \ 66 smbiostbl.c \ 67 sockstream.c \ 68 task_switch.c \ 69 uart_emul.c \ 70 usb_emul.c \ 71 usb_mouse.c \ 72 virtio.c \ 73 vga.c \ 74 vmgenc.c \ 75 xmsr.c \ 76 spinup_ap.c \ 77 iov.c 78 79.if ${MK_BHYVE_SNAPSHOT} != "no" 80SRCS+= snapshot.c 81.endif 82 83CFLAGS.kernemu_dev.c+= -I${SRCTOP}/sys/amd64 84 85.PATH: ${BHYVE_SYSDIR}/sys/amd64/vmm 86SRCS+= vmm_instruction_emul.c 87 88LIBADD= vmmapi md nv pthread z util sbuf cam 9p 89 90.if ${MK_CASPER} != "no" 91LIBADD+= casper 92LIBADD+= cap_pwd 93LIBADD+= cap_grp 94# Temporary disable capsicum, until we integrate checkpoint code with it. 95#CFLAGS+=-DWITH_CASPER 96.endif 97 98.if ${MK_BHYVE_SNAPSHOT} != "no" 99LIBADD+= ucl xo 100.endif 101 102.if ${MK_INET_SUPPORT} != "no" 103CFLAGS+=-DINET 104.endif 105.if ${MK_INET6_SUPPORT} != "no" 106CFLAGS+=-DINET6 107.endif 108.if ${MK_NETGRAPH_SUPPORT} != "no" 109CFLAGS+=-DNETGRAPH 110LIBADD+= netgraph 111.endif 112.if ${MK_OPENSSL} == "no" 113CFLAGS+=-DNO_OPENSSL 114.else 115LIBADD+= crypto 116.endif 117 118CFLAGS+= -I${BHYVE_SYSDIR}/sys/dev/e1000 119CFLAGS+= -I${BHYVE_SYSDIR}/sys/dev/mii 120CFLAGS+= -I${BHYVE_SYSDIR}/sys/dev/usb/controller 121.if ${MK_BHYVE_SNAPSHOT} != "no" 122CFLAGS+= -I${SRCTOP}/contrib/libucl/include 123 124# Temporary disable capsicum, until we integrate checkpoint code with it. 125CFLAGS+= -DWITHOUT_CAPSICUM 126 127CFLAGS+= -DBHYVE_SNAPSHOT 128.endif 129 130.ifdef GDB_LOG 131CFLAGS+=-DGDB_LOG 132.endif 133 134WARNS?= 2 135 136.include <bsd.prog.mk> 137