aboutsummaryrefslogtreecommitdiffstats
path: root/emulators
diff options
context:
space:
mode:
authorlwhsu <lwhsu@FreeBSD.org>2016-01-22 20:46:56 +0800
committerlwhsu <lwhsu@FreeBSD.org>2016-01-22 20:46:56 +0800
commit8559574f7830174920cdfe7d895f585b4abc8a57 (patch)
treee463b15e38b609a9907d8ae1ae69a9812655e99f /emulators
parent47b06fa57bd7fa1468e776960feca6bce8cd76ef (diff)
downloadfreebsd-ports-gnome-8559574f7830174920cdfe7d895f585b4abc8a57.tar.gz
freebsd-ports-gnome-8559574f7830174920cdfe7d895f585b4abc8a57.tar.zst
freebsd-ports-gnome-8559574f7830174920cdfe7d895f585b4abc8a57.zip
Add "Enable R0 logging" option and set BUILD_TYPE=debug while DEBUG option set
PR: 206470 Submitted by: lwhsu Approved by: decke
Diffstat (limited to 'emulators')
-rw-r--r--emulators/virtualbox-ose/Makefile13
1 files changed, 11 insertions, 2 deletions
diff --git a/emulators/virtualbox-ose/Makefile b/emulators/virtualbox-ose/Makefile
index b51fea84e201..f98ccf657d27 100644
--- a/emulators/virtualbox-ose/Makefile
+++ b/emulators/virtualbox-ose/Makefile
@@ -62,7 +62,7 @@ VBOX_UTILS= VBoxExtPackHelperApp VBoxNetAdpCtl VBoxNetDHCP VBoxSVC \
VBOX_GUEST_VER= ${PORTVERSION}
OPTIONS_DEFINE= DBUS DEBUG GUESTADDITIONS MANUAL NLS PULSEAUDIO PYTHON \
- QT4 UDPTUNNEL VDE VNC VPX WEBSERVICE X11
+ QT4 R0LOGGING UDPTUNNEL VDE VNC VPX WEBSERVICE X11
OPTIONS_DEFAULT= DBUS PYTHON QT4 UDPTUNNEL VNC WEBSERVICE X11
OPTIONS_SUB= yes
@@ -70,6 +70,7 @@ DEBUG_DESC= Debug symbols, additional logs and assertions
GUESTADDITIONS_DESC= Build with Guest Additions
MANUAL_DESC= Build with user manual
QT4_DESC= Build with QT4 Frontend
+R0LOGGING_DESC= Enable R0 logging
UDPTUNNEL_DESC= Build with UDP tunnel support
VDE_DESC= Build with VDE support
VNC_DESC= Build with VNC support
@@ -125,10 +126,15 @@ BROKEN= QT4 frontend requires X11 support. Run 'make config' again!
.if ${PORT_OPTIONS:MDEBUG}
KMK_BUILDTYPE= debug
+KMK_FLAGS+= BUILD_TYPE=debug
.else
KMK_BUILDTYPE= release
.endif
+.if ${PORT_OPTIONS:MR0LOGGING} && empty(PORT_OPTIONS:MDEBUG)
+BROKEN= R0 logging requires debug build
+.endif
+
.if ${PORT_OPTIONS:MGUESTADDITIONS}
GUESTADDITIONS= VBoxGuestAdditions_${VBOX_GUEST_VER}.iso
GADISTFILES= ${GUESTADDITIONS}:guestadditions
@@ -192,7 +198,7 @@ PLIST_SUB+= ARCH="${KMK_ARCH}"
KMK_BUILDDIR= ${WRKSRC}/out/${KMK_ARCH}/${KMK_BUILDTYPE}
KMK_CONFIG= VBOX_LIBPATH_X11=${LOCALBASE} VBOX_FREEBSD_SRC=${SRC_BASE}/sys
-KMK_FLAGS= -j${MAKE_JOBS_NUMBER}
+KMK_FLAGS+= -j${MAKE_JOBS_NUMBER}
.include <bsd.port.pre.mk>
@@ -241,6 +247,9 @@ post-patch:
@${ECHO} 'VBOX_PATH_GSOAP_IMPORT = ${PREFIX}/share/gsoap/import' >> ${WRKSRC}/LocalConfig.kmk
@${ECHO} 'VBOX_GCC_PEDANTIC_CXX = -Wshadow $(VBOX_GCC_WARN) -Wno-long-long' >> ${WRKSRC}/LocalConfig.kmk
.endif
+.if ${PORT_OPTIONS:MR0LOGGING}
+ @${ECHO} 'VBOX_WITH_R0_LOGGING = 1' >> ${WRKSRC}/LocalConfig.kmk
+.endif
.if ${COMPILER_TYPE} == clang
@${REINPLACE_CMD} -e 's| -finline-limit=8000||' \
-e 's| -mpreferred-stack-boundary=2||' ${WRKSRC}/Config.kmk