mirror of
https://git.FreeBSD.org/src.git
synced 2024-12-27 11:55:06 +00:00
Move MK_BHYVE/MK_HYPERV to architecture specific sections in Makefiles
instead of introducing an architecture specific section in src.opts.mk Make it clear in the documentation that the options only affect certain architectures to reduce user confusion if the knobs are tweaked A better method for abstracting this out will be done in the future in a different commit Discussed with/Requested by: imp
This commit is contained in:
parent
c05228ba1c
commit
b43a681b2a
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/projects/building-blocks/; revision=275661
54
lib/Makefile
54
lib/Makefile
@ -173,10 +173,6 @@ _libngatm= libngatm
|
||||
_libauditd= libauditd
|
||||
.endif
|
||||
|
||||
.if ${MK_BHYVE} != "no"
|
||||
_libvmmapi= libvmmapi
|
||||
.endif
|
||||
|
||||
.if ${MK_BLUETOOTH} != "no"
|
||||
_libbluetooth= libbluetooth
|
||||
_libsdp= libsdp
|
||||
@ -261,28 +257,6 @@ _libypclnt= libypclnt
|
||||
_libevent= libevent
|
||||
.endif
|
||||
|
||||
.if ${MACHINE_CPUARCH} == "i386" || ${MACHINE_CPUARCH} == "amd64"
|
||||
_libsmb= libsmb
|
||||
_libvgl= libvgl
|
||||
_libproc= libproc
|
||||
_librtld_db= librtld_db
|
||||
.endif
|
||||
|
||||
.if ${MACHINE_CPUARCH} == "mips"
|
||||
_libproc= libproc
|
||||
_librtld_db= librtld_db
|
||||
.endif
|
||||
|
||||
.if ${MACHINE_CPUARCH} == "powerpc"
|
||||
_libproc= libproc
|
||||
_librtld_db= librtld_db
|
||||
_libsmb= libsmb
|
||||
.endif
|
||||
|
||||
.if ${MACHINE_CPUARCH} == "sparc64"
|
||||
_libsmb= libsmb
|
||||
.endif
|
||||
|
||||
.if ${MK_OPENSSL} != "no"
|
||||
_libmp= libmp
|
||||
.endif
|
||||
@ -326,6 +300,34 @@ _libusbhid= libusbhid
|
||||
_libusb= libusb
|
||||
.endif
|
||||
|
||||
.if ${MACHINE_CPUARCH} == "amd64"
|
||||
.if ${MK_BHYVE} != "no"
|
||||
_libvmmapi= libvmmapi
|
||||
.endif
|
||||
.endif
|
||||
|
||||
.if ${MACHINE_CPUARCH} == "i386" || ${MACHINE_CPUARCH} == "amd64"
|
||||
_libsmb= libsmb
|
||||
_libvgl= libvgl
|
||||
_libproc= libproc
|
||||
_librtld_db= librtld_db
|
||||
.endif
|
||||
|
||||
.if ${MACHINE_CPUARCH} == "mips"
|
||||
_libproc= libproc
|
||||
_librtld_db= librtld_db
|
||||
.endif
|
||||
|
||||
.if ${MACHINE_CPUARCH} == "powerpc"
|
||||
_libproc= libproc
|
||||
_librtld_db= librtld_db
|
||||
_libsmb= libsmb
|
||||
.endif
|
||||
|
||||
.if ${MACHINE_CPUARCH} == "sparc64"
|
||||
_libsmb= libsmb
|
||||
.endif
|
||||
|
||||
.if !defined(LIBRARIES_ONLY)
|
||||
afterinstall:
|
||||
${INSTALL_SYMLINK} ../include ${DESTDIR}/usr/lib/include
|
||||
|
@ -184,11 +184,6 @@ NO_OBJ=
|
||||
# in environments where it's not possible to keep /sys publicly readable)
|
||||
SHARED?= copies
|
||||
|
||||
.if ${MK_BHYVE} != "no"
|
||||
LDIRS+= bhyve
|
||||
XFILES+= bhyve/vmrun.sh
|
||||
.endif
|
||||
|
||||
.if ${MK_HAST} != "no"
|
||||
LDIRS+= hast
|
||||
XFILES+= hast/ucarp.sh \
|
||||
@ -219,6 +214,13 @@ XFILES+= libusb20/Makefile \
|
||||
libusb20/control.c
|
||||
.endif
|
||||
|
||||
.if ${MACHINE_CPUARCH} == "amd64"
|
||||
.if ${MK_BHYVE} != "no"
|
||||
LDIRS+= bhyve
|
||||
XFILES+= bhyve/vmrun.sh
|
||||
.endif
|
||||
.endif
|
||||
|
||||
beforeinstall: ${SHARED} etc-examples
|
||||
.ORDER: ${SHARED} etc-examples
|
||||
|
||||
|
@ -729,6 +729,10 @@ MLINKS+=qlxge.4 if_qlxge.4
|
||||
MLINKS+=qlxgb.4 if_qlxgb.4
|
||||
MLINKS+=qlxgbe.4 if_qlxgbe.4
|
||||
MLINKS+=sfxge.4 if_sfxge.4
|
||||
|
||||
.if ${MK_BHYVE} != "no"
|
||||
_bhyve.4= bhyve.4
|
||||
.endif
|
||||
.endif
|
||||
|
||||
.if ${MACHINE_CPUARCH} == "mips"
|
||||
@ -739,10 +743,6 @@ _nvram2env.4= nvram2env.4
|
||||
SUBDIR= man4.${MACHINE_CPUARCH}
|
||||
.endif
|
||||
|
||||
.if ${MK_BHYVE} != "no"
|
||||
_bhyve.4= bhyve.4
|
||||
.endif
|
||||
|
||||
.if ${MK_CCD} != "no"
|
||||
_ccd.4= ccd.4
|
||||
.endif
|
||||
|
@ -53,6 +53,7 @@ __DEFAULT_YES_OPTIONS = \
|
||||
AUDIT \
|
||||
AUTHPF \
|
||||
AUTOFS \
|
||||
BHYVE \
|
||||
BINUTILS \
|
||||
BINUTILS_BOOTSTRAP \
|
||||
BLUETOOTH \
|
||||
@ -101,6 +102,7 @@ __DEFAULT_YES_OPTIONS = \
|
||||
GROFF \
|
||||
HAST \
|
||||
HTML \
|
||||
HYPERV \
|
||||
ICONV \
|
||||
INET \
|
||||
INET6 \
|
||||
@ -234,20 +236,6 @@ __DEFAULT_NO_OPTIONS+=CLANG_IS_CC CLANG CLANG_BOOTSTRAP
|
||||
__DEFAULT_YES_OPTIONS+=GCC GCC_BOOTSTRAP GNUCXX
|
||||
.endif
|
||||
|
||||
# bhyve is only supported on amd64
|
||||
.if ${__T} == "amd64"
|
||||
__DEFAULT_YES_OPTIONS+=BHYVE
|
||||
.else
|
||||
MK_BHYVE:= no
|
||||
.endif
|
||||
|
||||
# hyperv is only supported on amd64 and i386/i386
|
||||
.if ${__T} == "amd64" || (${__T} == "i386" && ${__TT} == "i386")
|
||||
__DEFAULT_YES_OPTIONS+=HYPERV
|
||||
.else
|
||||
MK_HYPERV:= no
|
||||
.endif
|
||||
|
||||
.include <bsd.mkopt.mk>
|
||||
|
||||
#
|
||||
|
@ -24,11 +24,13 @@
|
||||
|
||||
__DEFAULT_YES_OPTIONS = \
|
||||
AUTOFS \
|
||||
BHYVE \
|
||||
BLUETOOTH \
|
||||
CCD \
|
||||
CDDL \
|
||||
CRYPT \
|
||||
FORMAT_EXTENSIONS \
|
||||
HYPERV \
|
||||
ISCSI \
|
||||
INET \
|
||||
INET6 \
|
||||
@ -69,20 +71,6 @@ __TT=${TARGET}
|
||||
__TT=${MACHINE}
|
||||
.endif
|
||||
|
||||
# bhyve is only supported on amd64
|
||||
.if ${__T} == "amd64"
|
||||
__DEFAULT_YES_OPTIONS+=BHYVE
|
||||
.else
|
||||
MK_BHYVE:= no
|
||||
.endif
|
||||
|
||||
# hyperv is only supported on amd64 and i386/i386
|
||||
.if ${__T} == "amd64" || (${__T} == "i386" && ${__TT} == "i386")
|
||||
__DEFAULT_YES_OPTIONS+=HYPERV
|
||||
.else
|
||||
MK_HYPERV:= no
|
||||
.endif
|
||||
|
||||
# expanded inline from bsd.mkopt.mk to avoid share/mk dependency
|
||||
|
||||
# Those that default to yes
|
||||
|
@ -388,10 +388,6 @@ SUBDIR= \
|
||||
_autofs= autofs
|
||||
.endif
|
||||
|
||||
.if ${MK_BHYVE} != "no" || defined(ALL_MODULES)
|
||||
_vmm= vmm
|
||||
.endif
|
||||
|
||||
.if ${MK_CRYPT} != "no" || defined(ALL_MODULES)
|
||||
.if exists(${.CURDIR}/../opencrypto)
|
||||
_crypto= crypto
|
||||
@ -402,10 +398,6 @@ _random= random
|
||||
.endif
|
||||
.endif
|
||||
|
||||
.if ${MK_HYPERV} != "no" || defined(ALL_MODULES)
|
||||
_hyperv= hyperv
|
||||
.endif
|
||||
|
||||
.if (${MK_INET_SUPPORT} != "no" || ${MK_INET6_SUPPORT} != "no") || \
|
||||
defined(ALL_MODULES)
|
||||
_carp= carp
|
||||
@ -505,6 +497,9 @@ _et= et
|
||||
_exca= exca
|
||||
_ext2fs= ext2fs
|
||||
_filemon= filemon
|
||||
.if ${MK_HYPERV} != "no" || defined(ALL_MODULES)
|
||||
_hyperv= hyperv
|
||||
.endif
|
||||
_i2c= i2c
|
||||
.if ${MK_OFED} != "no" || defined(ALL_MODULES)
|
||||
_ibcore= ibcore
|
||||
@ -625,6 +620,10 @@ _qlxge= qlxge
|
||||
_qlxgb= qlxgb
|
||||
_qlxgbe= qlxgbe
|
||||
_sfxge= sfxge
|
||||
|
||||
.if ${MK_BHYVE} != "no" || defined(ALL_MODULES)
|
||||
_vmm= vmm
|
||||
.endif
|
||||
.endif
|
||||
|
||||
.if ${MACHINE_CPUARCH} == "i386"
|
||||
|
@ -2,3 +2,5 @@
|
||||
Set to not build or install
|
||||
.Xr bhyve 8 ,
|
||||
associated utilities, and examples.
|
||||
.Pp
|
||||
This option only affects amd64/amd64
|
||||
|
@ -1,2 +1,4 @@
|
||||
.\" $FreeBSD$
|
||||
Set to build and install HyperV utilities.
|
||||
.Pp
|
||||
This option only affects amd64/amd64 and i386/i386
|
||||
|
Loading…
Reference in New Issue
Block a user