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 basl.c \ 22 bhyvegc.c \ 23 bhyverun.c \ 24 block_if.c \ 25 bootrom.c \ 26 config.c \ 27 console.c \ 28 ctl_util.c \ 29 ctl_scsi_all.c \ 30 fwctl.c \ 31 gdb.c \ 32 hda_codec.c \ 33 inout.c \ 34 ioapic.c \ 35 kernemu_dev.c \ 36 mem.c \ 37 mevent.c \ 38 mptbl.c \ 39 net_backends.c \ 40 net_utils.c \ 41 pci_ahci.c \ 42 pci_e82545.c \ 43 pci_emul.c \ 44 pci_hda.c \ 45 pci_fbuf.c \ 46 pci_hostbridge.c \ 47 pci_irq.c \ 48 pci_lpc.c \ 49 pci_nvme.c \ 50 pci_passthru.c \ 51 pci_virtio_9p.c \ 52 pci_virtio_block.c \ 53 pci_virtio_console.c \ 54 pci_virtio_input.c \ 55 pci_virtio_net.c \ 56 pci_virtio_rnd.c \ 57 pci_virtio_scsi.c \ 58 pci_uart.c \ 59 pci_xhci.c \ 60 pctestdev.c \ 61 pm.c \ 62 post.c \ 63 ps2kbd.c \ 64 ps2mouse.c \ 65 rfb.c \ 66 rtc.c \ 67 smbiostbl.c \ 68 sockstream.c \ 69 task_switch.c \ 70 uart_emul.c \ 71 usb_emul.c \ 72 usb_mouse.c \ 73 virtio.c \ 74 vga.c \ 75 vmgenc.c \ 76 xmsr.c \ 77 spinup_ap.c \ 78 iov.c 79 80.if ${MK_BHYVE_SNAPSHOT} != "no" 81SRCS+= snapshot.c 82.endif 83 84CFLAGS.kernemu_dev.c+= -I${SRCTOP}/sys/amd64 85 86.PATH: ${BHYVE_SYSDIR}/sys/amd64/vmm 87SRCS+= vmm_instruction_emul.c 88 89LIBADD= vmmapi md nv pthread z util sbuf cam 9p 90 91.if ${MK_CASPER} != "no" 92LIBADD+= casper 93LIBADD+= cap_pwd 94LIBADD+= cap_grp 95# Temporary disable capsicum, until we integrate checkpoint code with it. 96#CFLAGS+=-DWITH_CASPER 97.endif 98 99.if ${MK_BHYVE_SNAPSHOT} != "no" 100LIBADD+= ucl xo 101.endif 102 103.if ${MK_INET_SUPPORT} != "no" 104CFLAGS+=-DINET 105.endif 106.if ${MK_INET6_SUPPORT} != "no" 107CFLAGS+=-DINET6 108.endif 109.if ${MK_NETGRAPH_SUPPORT} != "no" 110CFLAGS+=-DNETGRAPH 111LIBADD+= netgraph 112.endif 113.if ${MK_OPENSSL} == "no" 114CFLAGS+=-DNO_OPENSSL 115.else 116LIBADD+= crypto 117.endif 118 119CFLAGS+= -I${BHYVE_SYSDIR}/sys/dev/e1000 120CFLAGS+= -I${BHYVE_SYSDIR}/sys/dev/mii 121CFLAGS+= -I${BHYVE_SYSDIR}/sys/dev/usb/controller 122.if ${MK_BHYVE_SNAPSHOT} != "no" 123CFLAGS+= -I${SRCTOP}/contrib/libucl/include 124 125# Temporary disable capsicum, until we integrate checkpoint code with it. 126CFLAGS+= -DWITHOUT_CAPSICUM 127 128CFLAGS+= -DBHYVE_SNAPSHOT 129.endif 130 131.ifdef GDB_LOG 132CFLAGS+=-DGDB_LOG 133.endif 134 135# Disable thread safety analysis since it only finds very simple bugs and 136# yields many false positives. 137NO_WTHREAD_SAFETY= 138 139NO_WCAST_ALIGN= 140 141SUBDIR= kbdlayout 142 143.include <bsd.prog.mk> 144