aboutsummaryrefslogtreecommitdiff
path: root/emulators
diff options
context:
space:
mode:
authorBeat Gaetzi <beat@FreeBSD.org>2010-01-13 08:03:17 +0000
committerBeat Gaetzi <beat@FreeBSD.org>2010-01-13 08:03:17 +0000
commit078a3145868546becb1f18ad4ff3f84b346ab7ae (patch)
tree4bc52f53b8d0d76da7646866e5ecebe1d952923d /emulators
parent0f40e9df5c9d2e5efbc873c2599b2d2a9d74715b (diff)
downloadports-078a3145868546becb1f18ad4ff3f84b346ab7ae.tar.gz
ports-078a3145868546becb1f18ad4ff3f84b346ab7ae.zip
Notes
Diffstat (limited to 'emulators')
-rw-r--r--emulators/Makefile3
-rw-r--r--emulators/virtualbox-ose-kmod-legacy/Makefile232
-rw-r--r--emulators/virtualbox-ose-kmod-legacy/distinfo9
-rw-r--r--emulators/virtualbox-ose-kmod-legacy/files/patch-Config.kmk10
-rw-r--r--emulators/virtualbox-ose-kmod-legacy/files/patch-configure20
-rw-r--r--emulators/virtualbox-ose-kmod-legacy/files/patch-src-VBox-Devices-Makefile.kmk15
-rw-r--r--emulators/virtualbox-ose-kmod-legacy/files/patch-src-VBox-Frontends-VBoxManage-VBoxInternalManage.cpp50
-rw-r--r--emulators/virtualbox-ose-kmod-legacy/files/patch-src-VBox-HostDrivers-VBoxNetFlt-VBoxNetFltInternal.h28
-rw-r--r--emulators/virtualbox-ose-kmod-legacy/files/patch-src-VBox-HostDrivers-VBoxNetFlt-freebsd-VBoxNetFlt-freebsd.c380
-rw-r--r--emulators/virtualbox-ose-kmod-legacy/files/patch-src-VBox-Runtime-r0drv-freebsd-the-freebsd-kernel.h11
-rw-r--r--emulators/virtualbox-ose-kmod-legacy/files/patch-src-VBox-apps-adpctl_VBoxNetAdpCtl.cpp207
-rw-r--r--emulators/virtualbox-ose-kmod-legacy/files/pkg-install.in22
-rw-r--r--emulators/virtualbox-ose-kmod-legacy/files/vboxnet.in71
-rw-r--r--emulators/virtualbox-ose-kmod-legacy/pkg-message26
-rw-r--r--emulators/virtualbox-ose-kmod-legacy/pkg-plist596
-rw-r--r--emulators/virtualbox-ose-kmod/Makefile232
-rw-r--r--emulators/virtualbox-ose-kmod/distinfo9
-rw-r--r--emulators/virtualbox-ose-kmod/files/patch-Config.kmk10
-rw-r--r--emulators/virtualbox-ose-kmod/files/patch-configure20
-rw-r--r--emulators/virtualbox-ose-kmod/files/patch-src-VBox-Devices-Makefile.kmk15
-rw-r--r--emulators/virtualbox-ose-kmod/files/patch-src-VBox-Frontends-VBoxManage-VBoxInternalManage.cpp50
-rw-r--r--emulators/virtualbox-ose-kmod/files/patch-src-VBox-HostDrivers-VBoxNetFlt-VBoxNetFltInternal.h28
-rw-r--r--emulators/virtualbox-ose-kmod/files/patch-src-VBox-HostDrivers-VBoxNetFlt-freebsd-VBoxNetFlt-freebsd.c380
-rw-r--r--emulators/virtualbox-ose-kmod/files/patch-src-VBox-Runtime-r0drv-freebsd-the-freebsd-kernel.h11
-rw-r--r--emulators/virtualbox-ose-kmod/files/patch-src-VBox-apps-adpctl_VBoxNetAdpCtl.cpp207
-rw-r--r--emulators/virtualbox-ose-kmod/files/pkg-install.in22
-rw-r--r--emulators/virtualbox-ose-kmod/files/vboxnet.in71
-rw-r--r--emulators/virtualbox-ose-kmod/pkg-message26
-rw-r--r--emulators/virtualbox-ose-kmod/pkg-plist596
-rw-r--r--emulators/virtualbox-ose-legacy/Makefile37
-rw-r--r--emulators/virtualbox-ose-legacy/distinfo12
-rw-r--r--emulators/virtualbox-ose-legacy/files/patch-configure56
-rw-r--r--emulators/virtualbox-ose-legacy/files/patch-src-VBox-Additions-x11-VBoxClient-Makefile.kmk20
-rw-r--r--emulators/virtualbox-ose-legacy/files/patch-src-VBox-Devices-Audio-audio.c14
-rw-r--r--emulators/virtualbox-ose-legacy/files/patch-src-VBox-Devices-Makefile.kmk26
-rw-r--r--emulators/virtualbox-ose-legacy/files/patch-src-VBox-Frontends-VBoxManage-VBoxManageHelp.cpp37
-rw-r--r--emulators/virtualbox-ose-legacy/files/patch-src-VBox-Frontends-VBoxManage-VBoxManageModifyVM.cpp23
-rw-r--r--emulators/virtualbox-ose-legacy/files/patch-src-VBox-HostDrivers-Makefile.kmk27
-rw-r--r--emulators/virtualbox-ose-legacy/files/patch-src-VBox-HostDrivers-Support-SUPR3HardenedMain.cpp33
-rw-r--r--emulators/virtualbox-ose-legacy/files/patch-src-VBox-HostDrivers-VBoxNetAdp-freebsd-VBoxNetAdp-freebsd.c11
-rw-r--r--emulators/virtualbox-ose-legacy/files/patch-src-VBox-HostDrivers-VBoxNetFlt-VBoxNetFltInternal.h28
-rw-r--r--emulators/virtualbox-ose-legacy/files/patch-src-VBox-HostDrivers-VBoxNetFlt-freebsd-VBoxNetFlt-freebsd.c384
-rw-r--r--emulators/virtualbox-ose-legacy/files/patch-src-VBox-Installer-Makefile.kmk15
-rw-r--r--emulators/virtualbox-ose-legacy/files/patch-src-VBox-Main-AudioAdapterImpl.cpp14
-rw-r--r--emulators/virtualbox-ose-legacy/files/patch-src-VBox-Main-ConsoleImpl.cpp11
-rw-r--r--emulators/virtualbox-ose-legacy/files/patch-src-VBox-Main-ConsoleImpl2.cpp103
-rw-r--r--emulators/virtualbox-ose-legacy/files/patch-src-VBox-Main-include-ConsoleImpl.h20
-rw-r--r--emulators/virtualbox-ose-legacy/files/patch-src-VBox-Runtime-VBox-log-vbox.cpp82
-rw-r--r--emulators/virtualbox-ose-legacy/files/patch-src-VBox-Runtime-r0drv-freebsd-spinlock-r0drv-freebsd.c14
-rw-r--r--emulators/virtualbox-ose-legacy/files/patch-src-VBox-Runtime-r0drv-freebsd-the-freebsd-kernel.h11
-rw-r--r--emulators/virtualbox-ose-legacy/files/patch-src-VBox-Runtime-r3-freebsd-rtProcInitExePath-freebsd.cpp81
-rw-r--r--emulators/virtualbox-ose-legacy/files/patch-src-VBox-apps-adpctl_VBoxNetAdpCtl.cpp207
-rw-r--r--emulators/virtualbox-ose-legacy/files/patch-src-settings-vm-VBoxVMSettingsAudio.cpp12
-rw-r--r--emulators/virtualbox-ose-legacy/pkg-message11
-rw-r--r--emulators/virtualbox-ose-legacy/pkg-plist11
-rw-r--r--emulators/virtualbox-ose/Makefile37
-rw-r--r--emulators/virtualbox-ose/distinfo12
-rw-r--r--emulators/virtualbox-ose/files/patch-configure56
-rw-r--r--emulators/virtualbox-ose/files/patch-src-VBox-Additions-x11-VBoxClient-Makefile.kmk20
-rw-r--r--emulators/virtualbox-ose/files/patch-src-VBox-Devices-Audio-audio.c14
-rw-r--r--emulators/virtualbox-ose/files/patch-src-VBox-Devices-Makefile.kmk26
-rw-r--r--emulators/virtualbox-ose/files/patch-src-VBox-Frontends-VBoxManage-VBoxManageHelp.cpp37
-rw-r--r--emulators/virtualbox-ose/files/patch-src-VBox-Frontends-VBoxManage-VBoxManageModifyVM.cpp23
-rw-r--r--emulators/virtualbox-ose/files/patch-src-VBox-HostDrivers-Makefile.kmk27
-rw-r--r--emulators/virtualbox-ose/files/patch-src-VBox-HostDrivers-Support-SUPR3HardenedMain.cpp33
-rw-r--r--emulators/virtualbox-ose/files/patch-src-VBox-HostDrivers-VBoxNetAdp-freebsd-VBoxNetAdp-freebsd.c11
-rw-r--r--emulators/virtualbox-ose/files/patch-src-VBox-HostDrivers-VBoxNetFlt-VBoxNetFltInternal.h28
-rw-r--r--emulators/virtualbox-ose/files/patch-src-VBox-HostDrivers-VBoxNetFlt-freebsd-VBoxNetFlt-freebsd.c384
-rw-r--r--emulators/virtualbox-ose/files/patch-src-VBox-Installer-Makefile.kmk15
-rw-r--r--emulators/virtualbox-ose/files/patch-src-VBox-Main-AudioAdapterImpl.cpp14
-rw-r--r--emulators/virtualbox-ose/files/patch-src-VBox-Main-ConsoleImpl.cpp11
-rw-r--r--emulators/virtualbox-ose/files/patch-src-VBox-Main-ConsoleImpl2.cpp103
-rw-r--r--emulators/virtualbox-ose/files/patch-src-VBox-Main-include-ConsoleImpl.h20
-rw-r--r--emulators/virtualbox-ose/files/patch-src-VBox-Runtime-VBox-log-vbox.cpp82
-rw-r--r--emulators/virtualbox-ose/files/patch-src-VBox-Runtime-r0drv-freebsd-spinlock-r0drv-freebsd.c14
-rw-r--r--emulators/virtualbox-ose/files/patch-src-VBox-Runtime-r0drv-freebsd-the-freebsd-kernel.h11
-rw-r--r--emulators/virtualbox-ose/files/patch-src-VBox-Runtime-r3-freebsd-rtProcInitExePath-freebsd.cpp81
-rw-r--r--emulators/virtualbox-ose/files/patch-src-VBox-apps-adpctl_VBoxNetAdpCtl.cpp207
-rw-r--r--emulators/virtualbox-ose/files/patch-src-settings-vm-VBoxVMSettingsAudio.cpp12
-rw-r--r--emulators/virtualbox-ose/pkg-message11
-rw-r--r--emulators/virtualbox-ose/pkg-plist11
-rw-r--r--emulators/virtualbox/Makefile259
-rw-r--r--emulators/virtualbox/distinfo6
-rw-r--r--emulators/virtualbox/files/patch-Config.kmk10
-rw-r--r--emulators/virtualbox/files/patch-configure20
-rw-r--r--emulators/virtualbox/files/patch-src-VBox-Devices-Makefile.kmk15
-rw-r--r--emulators/virtualbox/files/patch-src-VBox-Frontends-VBoxManage-VBoxInternalManage.cpp50
-rw-r--r--emulators/virtualbox/files/patch-src-VBox-HostDrivers-VBoxNetAdp-freebsd-VBoxNetAdp-freebsd.c11
-rw-r--r--emulators/virtualbox/files/patch-src-VBox-HostDrivers-VBoxNetFlt-VBoxNetFltInternal.h28
-rw-r--r--emulators/virtualbox/files/patch-src-VBox-HostDrivers-VBoxNetFlt-freebsd-VBoxNetFlt-freebsd.c384
-rw-r--r--emulators/virtualbox/files/patch-src-VBox-Runtime-r0drv-freebsd-spinlock-r0drv-freebsd.c14
-rw-r--r--emulators/virtualbox/files/patch-src-VBox-Runtime-r0drv-freebsd-the-freebsd-kernel.h11
-rw-r--r--emulators/virtualbox/files/patch-src-VBox-apps-adpctl_VBoxNetAdpCtl.cpp207
-rw-r--r--emulators/virtualbox/files/pkg-install.in22
-rw-r--r--emulators/virtualbox/pkg-descr7
-rw-r--r--emulators/virtualbox/pkg-message26
-rw-r--r--emulators/virtualbox/pkg-plist599
97 files changed, 1418 insertions, 6208 deletions
diff --git a/emulators/Makefile b/emulators/Makefile
index 44b12161150c..27630c0b0cd4 100644
--- a/emulators/Makefile
+++ b/emulators/Makefile
@@ -175,7 +175,8 @@
SUBDIR += vgb-bin
SUBDIR += vgba-bin
SUBDIR += vice
- SUBDIR += virtualbox
+ SUBDIR += virtualbox-ose
+ SUBDIR += virtualbox-ose-kmod
SUBDIR += visualos
SUBDIR += vmips
SUBDIR += vmsbackup
diff --git a/emulators/virtualbox-ose-kmod-legacy/Makefile b/emulators/virtualbox-ose-kmod-legacy/Makefile
index 46617a1b64b8..a0da9cfeac2c 100644
--- a/emulators/virtualbox-ose-kmod-legacy/Makefile
+++ b/emulators/virtualbox-ose-kmod-legacy/Makefile
@@ -1,186 +1,83 @@
-# New ports collection makefile for: virtualbox
-# Date created: 2009-05-02
+# New ports collection makefile for: virtualbox-ose-kmod
+# Date created: 2009-09-21
# Whom: Bernhard Froehlich <decke@bluelife.at>
#
# $FreeBSD$
#
-PORTNAME= virtualbox
-DISTVERSION= 3.0.51r22902
-PORTREVISION= 3
+PORTNAME= virtualbox-ose
+DISTVERSION= 3.1.2
CATEGORIES= emulators kld
MASTER_SITES= http://tmp.chruetertee.ch/ \
http://freebsd.unixfreunde.de/sources/ \
http://disasterarea.chruetertee.ch/ \
- http://mirror.4bit.ws/ \
- http://dlc.sun.com/virtualbox/${VBOX_GUEST_VER}/:guestadditions
-DISTFILES= ${DISTNAME}${EXTRACT_SUFX} ${GADISTFILES}
-EXTRACT_ONLY= ${DISTNAME}${EXTRACT_SUFX}
+ http://mirror.4bit.ws/
+PKGNAMESUFFIX= -kmod
+DISTNAME= VirtualBox-${DISTVERSION}-OSE
-#for discussion please use emulation@FreeBSD.org
MAINTAINER= vbox@FreeBSD.org
-COMMENT= A general-purpose full virtualizer for x86 hardware
+COMMENT= VirtualBox kernel module for FreeBSD
BUILD_DEPENDS= yasm:${PORTSDIR}/devel/yasm \
as86:${PORTSDIR}/devel/dev86 \
- xsltproc:${PORTSDIR}/textproc/libxslt \
kmk:${PORTSDIR}/devel/kBuild
-LIB_DEPENDS= png.5:${PORTSDIR}/graphics/png \
- xslt.2:${PORTSDIR}/textproc/libxslt \
- curl.5:${PORTSDIR}/ftp/curl
+WRKSRC= ${WRKDIR}/VirtualBox-${PORTVERSION}_OSE
+USE_RC_SUBR= vboxnet
ONLY_FOR_ARCHS= i386 amd64
-USE_GNOME= libidl
-USE_CDRTOOLS= yes
USE_BZIP2= yes
-USE_PYTHON= yes
-USE_PYDISTUTILS= easy_install
-PYDISTUTILS_PKGNAME= vboxapi
-PYDISTUTILS_PKGVERSION= 1.0
-PYDISTUTILS_NOEGGINFO= yes
HAS_CONFIGURE= yes
-CONFIGURE_ARGS+=--with-gcc="${CC}" --with-g++="${CXX}"
-USE_LDCONFIG= ${PREFIX}/lib/virtualbox
+CONFIGURE_ARGS+=--with-gcc="${CC}" --with-g++="${CXX}" --nofatal \
+ --disable-xpcom --disable-sdl-ttf --disable-pulse \
+ --disable-alsa --disable-dbus --disable-python \
+ --build-headless
CONFLICTS= bcc-[0-9]*
-VBOXGROUP?= vboxusers
-VBOXGID?= 920
-VBOX_FRONTENDS= VBoxHeadless
-VBOX_GUEST_VER= 3.0.6
-
-SUB_FILES= pkg-install
-
-SUB_LIST= PREFIX=${PREFIX} \
- VBOXGROUP=${VBOXGROUP} \
- VBOXGID=${VBOXGID}
-
-OPTIONS= QT4 "Build with QT4 Frontend" on \
- DEBUG "Build with debugging symbols" off \
- GUESTADDITIONS "Build with Guest Additions" off \
- DBUS "Build with D-Bus and HAL support" on \
- PULSEAUDIO "Build with PulseAudio" off \
- X11 "Build with X11 support" on \
- NLS "Native language support" on
+OPTIONS= DEBUG "Build with debugging symbols" off
.include <bsd.port.options.mk>
-PLIST_SUB+= KMODDIR=${KMODDIR:C,^/,,} \
- PYTHON_VER=${PYTHON_VER} \
- PYTHON_VERU=${PYTHON_VER:S/./_/} \
- GUEST_VER=${VBOX_GUEST_VER}
+PLIST_SUB+= KMODDIR=${KMODDIR:C,^/,,}
KMODDIR= /boot/modules
-KMK_BUILDTYPE= release
-KMK_CONFIG= VBOX_LIBPATH_X11=${LOCALBASE} VBOX_FREEBSD_SRC=${SRC_BASE}/sys
-KMK_FLAGS=
-
-.if defined(WITHOUT_QT4) && !defined(WITHOUT_NLS)
-BROKEN= NLS support requires QT4 frontend. Run 'make config' again!
-.endif
-.if defined(WITHOUT_X11) && !defined(WITHOUT_QT4)
-BROKEN= QT4 frontend requires X11 support. Run 'make config' again!
-.endif
-
-.if !defined(WITHOUT_X11)
-USE_SDL= sdl
-USE_XORG= xcursor xmu
-VBOX_FRONTENDS+=VBoxBFE VBoxSDL VBoxTestOGL
-PLIST_SUB+= X11=""
-.else
-CONFIGURE_ARGS+=--build-headless
-PLIST_SUB+= X11="@comment "
-.endif
-
-.if !defined(WITHOUT_QT4)
-USE_QT_VER= 4
-QT_NONSTANDARD= yes
-QT_COMPONENTS= gui network moc_build uic_build rcc_build linguist
-INSTALLS_ICONS= yes
-VBOX_FRONTENDS+=VirtualBox
-PLIST_SUB+= QT4=""
-.else
-CONFIGURE_ARGS+=--disable-qt4
-PLIST_SUB+= QT4="@comment "
-.endif
+VBOX_BIN= ${WRKSRC}/out/${KMK_ARCH}/${KMK_BUILDTYPE}/bin/src
-.if defined(WITH_GUESTADDITIONS)
-GUESTADDITIONS= VBoxGuestAdditions_${VBOX_GUEST_VER}.iso
-GADISTFILES= ${GUESTADDITIONS}:guestadditions
-RESTRICTED= for personal use only
-RESTRICTED_FILES= ${GUESTADDITIONS}
-FETCH_ARGS= -pRr
-PLIST_SUB+= GUESTADDITIONS=""
-.else
-PLIST_SUB+= GUESTADDITIONS="@comment "
-.endif
+KMK_BUILDTYPE= release
+KMK_CONFIG= VBOX_LIBPATH_X11=${LOCALBASE} VBOX_FREEBSD_SRC=${SRC_BASE}/sys
+KMK_FLAGS= HostDrivers-src vboxdrv-mod VBoxNetFlt-src VBoxNetAdp-src
.if defined(WITH_DEBUG)
KMK_FLAGS+= BUILD_TYPE=debug
KMK_BUILDTYPE= debug
.endif
-.if !defined(WITHOUT_DBUS)
-LIB_DEPENDS+= dbus-1.3:${PORTSDIR}/devel/dbus
-.else
-CONFIGURE_ARGS+=--disable-dbus
-.endif
-
-.if !defined(WITH_PULSEAUDIO)
-CONFIGURE_ARGS+=--disable-pulse
-.endif
-
-.if !defined(WITHOUT_NLS)
-PLIST_SUB+= NLS=""
-.else
-PLIST_SUB+= NLS="@comment "
-.endif
-
-.if !exists(${SRC_BASE}/sys/kern/bus_if.m)
-IGNORE= requires kernel sources for the kernel module
-.endif
-
.if ${OSVERSION} < 700000
BROKEN= Does not compile on FreeBSD 6.X
.endif
.if ${ARCH} == i386
KMK_ARCH= freebsd.x86
-PLIST_SUB+= I386=""
.else
KMK_ARCH= freebsd.${ARCH}
-PLIST_SUB+= I386="@comment "
.endif
-.include <bsd.port.pre.mk>
-
-pre-everything::
-.if ${ARCH} == "amd64"
-.if !exists(/usr/lib32)
- @${ECHO} 'Requires 32-bit libraries installed under /usr/lib32.'
- @${ECHO} 'Do: cd /usr/src; make build32 install32; ldconfig -v -m -R /usr/lib32'
- @${FALSE}
-.endif
+.if !exists(${SRC_BASE}/sys/kern/bus_if.m)
+IGNORE= requires kernel sources
.endif
+.include <bsd.port.pre.mk>
+
post-patch:
- @${ECHO} 'VBOX_PATH_APP_PRIVATE_ARCH = ${PREFIX}/lib/virtualbox' > ${WRKSRC}/LocalConfig.kmk
- @${ECHO} 'VBOX_PATH_SHARED_LIBS = ${PREFIX}/lib/virtualbox' >> ${WRKSRC}/LocalConfig.kmk
- @${ECHO} 'VBOX_WITH_RUNPATH = ${PREFIX}/lib/virtualbox' >> ${WRKSRC}/LocalConfig.kmk
- @${ECHO} 'VBOX_PATH_APP_PRIVATE = ${DATADIR}' >> ${WRKSRC}/LocalConfig.kmk
- @${ECHO} 'VBOX_PATH_APP_DOCS = ${DOCSDIR}' >> ${WRKSRC}/LocalConfig.kmk
- @${ECHO} 'VBOX_WITH_INSTALLER = 1' >> ${WRKSRC}/LocalConfig.kmk
- @${ECHO} 'VBOX_WITH_TESTCASES=' >> ${WRKSRC}/LocalConfig.kmk
-.if defined(WITHOUT_X11)
- @${ECHO} 'VBOX_WITH_X11_ADDITIONS=' >> ${WRKSRC}/LocalConfig.kmk
-.endif
+ @${ECHO} 'VBOX_WITH_VBOXDRV = 1' > ${WRKSRC}/LocalConfig.kmk
+ @${ECHO} 'VBOX_WITH_NETFLT = 1' >> ${WRKSRC}/LocalConfig.kmk
+ @${ECHO} 'VBOX_WITH_NETADP = 1' >> ${WRKSRC}/LocalConfig.kmk
+ @${ECHO} 'VBOX_WITH_ADDITIONS =' >> ${WRKSRC}/LocalConfig.kmk
@${REINPLACE_CMD} -e 's|/usr/local|${LOCALBASE}|g' \
- ${WRKSRC}/Config.kmk ${WRKSRC}/configure \
- ${WRKSRC}/kBuild/units/qt3.kmk ${WRKSRC}/kBuild/units/qt4.kmk \
- ${WRKSRC}/kBuild/sdks/LIBSDL.kmk \
- ${WRKSRC}/src/libs/xpcom18a4/python/gen_python_deps.py
+ ${WRKSRC}/Config.kmk \
+ ${WRKSRC}/configure
@${REINPLACE_CMD} -e 's|\$$KBUILDDIR_BIN/kmk_sed|${PREFIX}/bin/kmk_sed|g' ${WRKSRC}/configure
pre-build:
@@ -188,72 +85,13 @@ pre-build:
${WRKSRC}/env.sh
do-build:
- cd ${WRKSRC} && ${SH} env.sh && ${KMK_CONFIG} ${LOCALBASE}/bin/kmk ${KMK_FLAGS}
+ cd ${WRKSRC} && ${SH} env.sh && cd ${WRKSRC}/src/VBox/HostDrivers && ${KMK_CONFIG} ${LOCALBASE}/bin/kmk ${KMK_FLAGS}
+ cd ${VBOX_BIN} && make
do-install:
${MKDIR} ${KMODDIR}
-.for f in vboxdrv.ko vboxnetadp.ko vboxnetflt.ko
- ${INSTALL_KLD} ${WRKSRC}/out/${KMK_ARCH}/${KMK_BUILDTYPE}/bin/${f} ${KMODDIR}
-.endfor
-
- ${MKDIR} ${DATADIR}
- (cd ${WRKSRC}/out/${KMK_ARCH}/${KMK_BUILDTYPE}/bin/sdk/bindings/xpcom && ${COPYTREE_SHARE} "idl samples" ${DATADIR})
-
- ${MKDIR} ${PREFIX}/include/virtualbox
- (cd ${WRKSRC}/out/${KMK_ARCH}/${KMK_BUILDTYPE}/bin/sdk/bindings/xpcom/include && ${COPYTREE_SHARE} "*" ${PREFIX}/include/virtualbox)
-
- ${MKDIR} ${PREFIX}/lib/virtualbox
- (cd ${WRKSRC}/out/${KMK_ARCH}/${KMK_BUILDTYPE}/bin && ${COPYTREE_SHARE} "*.so *.gc *.r0 components" ${PREFIX}/lib/virtualbox)
-
-.if !defined(WITHOUT_NLS)
- ${MKDIR} ${DATADIR}/nls
- (cd ${WRKSRC}/out/${KMK_ARCH}/${KMK_BUILDTYPE}/obj/VirtualBox/qtnls && ${COPYTREE_SHARE} "*.qm" ${DATADIR}/nls)
-.endif
-
- ${MKDIR} ${PREFIX}/bin
-.for f in VBoxManage VBoxNetAdpCtl VBoxNetDHCP VBoxSVC VBoxXPCOMIPCD ${VBOX_FRONTENDS}
- ${INSTALL_PROGRAM} ${WRKSRC}/out/${KMK_ARCH}/${KMK_BUILDTYPE}/bin/${f} ${PREFIX}/lib/virtualbox/
- ${LN} -sf ${PREFIX}/lib/virtualbox/${f} ${PREFIX}/bin/
-.endfor
-
-.for f in VBoxNetAdpCtl VBoxNetDHCP ${VBOX_FRONTENDS}
- ${CHMOD} 4511 ${PREFIX}/lib/virtualbox/${f}
-.endfor
-
-.for f in VBoxManage VBoxSVC VBoxXPCOMIPCD
- ${CHMOD} 0711 ${PREFIX}/lib/virtualbox/${f}
-.endfor
-
-.if defined(WITH_GUESTADDITIONS)
- ${MKDIR} ${PREFIX}/lib/virtualbox/additions
- ${INSTALL_DATA} ${DISTDIR}/${GUESTADDITIONS} ${PREFIX}/lib/virtualbox/additions/
- ${LN} -sf ${PREFIX}/lib/virtualbox/additions/${GUESTADDITIONS} ${PREFIX}/lib/virtualbox/additions/VBoxGuestAdditions.iso
-.endif
-
- cd ${WRKSRC}/out/${KMK_ARCH}/${KMK_BUILDTYPE}/bin/sdk/installer && \
- VBOX_INSTALL_PATH="${PREFIX}/lib/virtualbox" ${PYTHON_CMD} vboxapisetup.py install
-
- @${MKDIR} ${PYTHON_SITELIBDIR}
- (cd ${WRKSRC}/out/${KMK_ARCH}/${KMK_BUILDTYPE}/bin/sdk/bindings/xpcom/python && ${COPYTREE_SHARE} "*" ${PYTHON_SITELIBDIR})
- ${PYTHON_CMD} -mcompileall ${PYTHON_SITELIBDIR}/xpcom/
-
-post-install:
- @${SETENV} ${SH} ${PKGINSTALL} ${PKGNAME} POST-INSTALL
-
-.for f in VBoxManage VBoxNetDHCP VBoxSVC VBoxXPCOMIPCD ${VBOX_FRONTENDS}
- ${CHOWN} root:${VBOXGROUP} ${PREFIX}/lib/virtualbox/${f}
-.endfor
-
- @${FIND} ${DATADIR} -type d -print0 | ${XARGS} -0 ${CHMOD} 755
- @${FIND} ${PREFIX}/include/virtualbox -type d -print0 | ${XARGS} -0 ${CHMOD} 755
- @${FIND} ${PREFIX}/lib/virtualbox -type d -print0 | ${XARGS} -0 ${CHMOD} 755
-
-.if !defined(WITHOUT_QT4)
- ${MKDIR} ${PREFIX}/share/icons/hicolor/48x48/apps/
- ${INSTALL_DATA} ${WRKSRC}/src/VBox/Frontends/VirtualBox/images/OSE/VirtualBox_48px.png ${PREFIX}/share/icons/hicolor/48x48/apps/VBox.png
- ${MKDIR} ${PREFIX}/share/applications/
- ${INSTALL_DATA} ${WRKSRC}/src/VBox/Installer/solaris/virtualbox.desktop ${PREFIX}/share/applications/virtualbox.desktop
-.endif
- @${CAT} ${PKGMESSAGE}
+ ${INSTALL_KLD} ${VBOX_BIN}/vboxdrv/vboxdrv.ko ${KMODDIR}
+ ${INSTALL_KLD} ${VBOX_BIN}/vboxnetadp/vboxnetadp.ko ${KMODDIR}
+ ${INSTALL_KLD} ${VBOX_BIN}/vboxnetflt/vboxnetflt.ko ${KMODDIR}
.include <bsd.port.post.mk>
diff --git a/emulators/virtualbox-ose-kmod-legacy/distinfo b/emulators/virtualbox-ose-kmod-legacy/distinfo
index 492de57d1c4a..af7117996821 100644
--- a/emulators/virtualbox-ose-kmod-legacy/distinfo
+++ b/emulators/virtualbox-ose-kmod-legacy/distinfo
@@ -1,6 +1,3 @@
-MD5 (virtualbox-3.0.51r22902.tar.bz2) = c2fbfd0eca2d2c9e6ad5f029cf75def0
-SHA256 (virtualbox-3.0.51r22902.tar.bz2) = ccbc88276f9e1944005d1c2f3661ec6d7113b22801ecbbb72d422aa0ab2b0a2a
-SIZE (virtualbox-3.0.51r22902.tar.bz2) = 51742256
-MD5 (VBoxGuestAdditions_3.0.6.iso) = 8d033b4f66db1a3e5b914da1717e9c21
-SHA256 (VBoxGuestAdditions_3.0.6.iso) = d6a8b61ef1004637c8be3a70612bb0e101f552d7eb0a9a376ff1ad264baf6a3c
-SIZE (VBoxGuestAdditions_3.0.6.iso) = 32786432
+MD5 (VirtualBox-3.1.2-OSE.tar.bz2) = e7808f16114f5b1a65aa2df1aa33e1a7
+SHA256 (VirtualBox-3.1.2-OSE.tar.bz2) = 293f582e37eda29efdb53c6468481b446e1964592f5728656b74664f4d32f2b1
+SIZE (VirtualBox-3.1.2-OSE.tar.bz2) = 55553394
diff --git a/emulators/virtualbox-ose-kmod-legacy/files/patch-Config.kmk b/emulators/virtualbox-ose-kmod-legacy/files/patch-Config.kmk
deleted file mode 100644
index 2ce55eb8a12d..000000000000
--- a/emulators/virtualbox-ose-kmod-legacy/files/patch-Config.kmk
+++ /dev/null
@@ -1,10 +0,0 @@
---- Config.kmk.bak 2009-09-02 18:34:01.000000000 +0200
-+++ Config.kmk 2009-09-02 19:19:09.000000000 +0200
-@@ -781,6 +781,7 @@
- VBOX_WITH_VBOXBFE=
- VBOX_WITH_OGL=
- VBOX_WITH_KCHMVIEWER=
-+ VBOX_WITH_HGSMI=
- endif
-
- #
diff --git a/emulators/virtualbox-ose-kmod-legacy/files/patch-configure b/emulators/virtualbox-ose-kmod-legacy/files/patch-configure
deleted file mode 100644
index c6532c3db606..000000000000
--- a/emulators/virtualbox-ose-kmod-legacy/files/patch-configure
+++ /dev/null
@@ -1,20 +0,0 @@
---- configure.orgi 2009-05-31 13:43:50.000000000 +0200
-+++ configure 2009-05-31 13:45:47.000000000 +0200
-@@ -102,7 +102,7 @@
- XSLTPROC="xsltproc"
- GENISOIMAGE="genisoimage"
- MKISOFS="mkisofs"
--LIBCRYPTO="-lcrypto"
-+LIBCRYPTO="-lcrypto -lssl"
- LIBPTHREAD="-lpthread"
- LIBCAP="-lcap"
- GSOAP=""
-@@ -1698,7 +1698,7 @@
- cat $ODIR.tmp_src.cc >> $LOG
- echo "using the following command line:" >> $LOG
- echo "$CXX -O -Wall -o $ODIR.tmp_out $ODIR.tmp_src.cc -I$p/include/$d $p/$b/lib$d.so" >> $LOG
-- $CXX -O -Wall -o $ODIR.tmp_out $ODIR.tmp_src.cc -I$p/include/$d $p/$b/lib$d.so >> $LOG 2>&1
-+ $CXX -O -Wall -o $ODIR.tmp_out $ODIR.tmp_src.cc -I$p/include/$d $p/$b/lib$d.so -pthread >> $LOG 2>&1
- if [ $? -eq 0 ]; then
- found=1
- break
diff --git a/emulators/virtualbox-ose-kmod-legacy/files/patch-src-VBox-Devices-Makefile.kmk b/emulators/virtualbox-ose-kmod-legacy/files/patch-src-VBox-Devices-Makefile.kmk
deleted file mode 100644
index d404c8aee176..000000000000
--- a/emulators/virtualbox-ose-kmod-legacy/files/patch-src-VBox-Devices-Makefile.kmk
+++ /dev/null
@@ -1,15 +0,0 @@
---- src/VBox/Devices/Makefile.kmk.orig 2009-11-01 22:50:39.000000000 +0100
-+++ src/VBox/Devices/Makefile.kmk 2009-11-01 22:50:52.000000000 +0100
-@@ -31,8 +31,10 @@
- include $(PATH_SUB_CURRENT)/PC/VMI/Makefile.kmk
- endif
- include $(PATH_SUB_CURRENT)/Graphics/BIOS/Makefile.kmk
--include $(PATH_SUB_CURRENT)/testcase/Makefile.kmk
--include $(PATH_SUB_CURRENT)/Storage/testcase/Makefile.kmk
-+ifdef VBOX_WITH_TESTCASES
-+ include $(PATH_SUB_CURRENT)/testcase/Makefile.kmk
-+ include $(PATH_SUB_CURRENT)/Storage/testcase/Makefile.kmk
-+endif
- ifndef VBOX_OSE
- include $(PATH_SUB_CURRENT)/Storage/VBoxHDDFormats/Makefile.kmk
- endif
diff --git a/emulators/virtualbox-ose-kmod-legacy/files/patch-src-VBox-Frontends-VBoxManage-VBoxInternalManage.cpp b/emulators/virtualbox-ose-kmod-legacy/files/patch-src-VBox-Frontends-VBoxManage-VBoxInternalManage.cpp
deleted file mode 100644
index 0a1f735fb79a..000000000000
--- a/emulators/virtualbox-ose-kmod-legacy/files/patch-src-VBox-Frontends-VBoxManage-VBoxInternalManage.cpp
+++ /dev/null
@@ -1,50 +0,0 @@
-Index: src/VBox/Frontends/VBoxManage/VBoxInternalManage.cpp
-@@ -54,7 +54,8 @@
- #ifdef RT_OS_WINDOWS
- # include <windows.h>
- # include <winioctl.h>
--#elif defined(RT_OS_LINUX) || defined(RT_OS_DARWIN) || defined(RT_OS_SOLARIS)
-+#elif defined(RT_OS_LINUX) || defined(RT_OS_DARWIN) \
-+ || defined(RT_OS_SOLARIS) || defined(RT_OS_FREEBSD)
- # include <errno.h>
- # include <sys/ioctl.h>
- # include <sys/types.h>
-@@ -76,6 +77,9 @@
- # include <sys/dkio.h>
- # include <sys/vtoc.h>
- #endif /* RT_OS_SOLARIS */
-+#ifdef RT_OS_FREEBSD
-+# include <sys/disk.h>
-+#endif /* RT_OS_FREEBSD */
-
- using namespace com;
-
-@@ -1013,6 +1017,28 @@
- vrc = VERR_INVALID_PARAMETER;
- goto out;
- }
-+#elif defined(RT_OS_FREEBSD)
-+ struct stat DevStat;
-+ if (!fstat(RawFile, &DevStat) && S_ISCHR(DevStat.st_mode))
-+ {
-+ off_t cMediasize = 0;
-+ if (!ioctl(RawFile, DIOCGMEDIASIZE, &cMediasize))
-+ {
-+ cbSize = cMediasize;
-+ }
-+ else
-+ {
-+ vrc = RTErrConvertFromErrno(errno);
-+ RTPrintf("Cannot get the block count for file '%s': %Rrc", rawdisk.raw(), vrc);
-+ goto out;
-+ }
-+ }
-+ else
-+ {
-+ RTPrintf("File '%s' is no character device\n", rawdisk.raw());
-+ vrc = VERR_INVALID_PARAMETER;
-+ goto out;
-+ }
- #else /* all unrecognized OSes */
- /* Hopefully this works on all other hosts. If it doesn't, it'll just fail
- * creating the VMDK, so no real harm done. */
diff --git a/emulators/virtualbox-ose-kmod-legacy/files/patch-src-VBox-HostDrivers-VBoxNetFlt-VBoxNetFltInternal.h b/emulators/virtualbox-ose-kmod-legacy/files/patch-src-VBox-HostDrivers-VBoxNetFlt-VBoxNetFltInternal.h
deleted file mode 100644
index 250a1960a7f4..000000000000
--- a/emulators/virtualbox-ose-kmod-legacy/files/patch-src-VBox-HostDrivers-VBoxNetFlt-VBoxNetFltInternal.h
+++ /dev/null
@@ -1,28 +0,0 @@
-Index: src/VBox/HostDrivers/VBoxNetFlt/VBoxNetFltInternal.h
-===================================================================
---- src/VBox/HostDrivers/VBoxNetFlt/VBoxNetFltInternal.h (revision 23391)
-+++ src/VBox/HostDrivers/VBoxNetFlt/VBoxNetFltInternal.h (working copy)
-@@ -206,6 +206,14 @@
- hook_p output;
- /** Original interface flags */
- unsigned int flags;
-+ /** Input queue */
-+ struct ifqueue inq;
-+ /** Output queue */
-+ struct ifqueue outq;
-+ /** Input task */
-+ struct task tskin;
-+ /** Output task */
-+ struct task tskout;
- /** The MAC address of the interface. */
- RTMAC Mac;
- /** @} */
-@@ -241,6 +249,8 @@
- # endif
- #elif defined(RT_OS_LINUX)
- uint8_t abPadding[320];
-+#elif defined(RT_OS_FREEBSD)
-+ uint8_t abPadding[320];
- #else
- uint8_t abPadding[128];
- #endif
diff --git a/emulators/virtualbox-ose-kmod-legacy/files/patch-src-VBox-HostDrivers-VBoxNetFlt-freebsd-VBoxNetFlt-freebsd.c b/emulators/virtualbox-ose-kmod-legacy/files/patch-src-VBox-HostDrivers-VBoxNetFlt-freebsd-VBoxNetFlt-freebsd.c
index f23fedbf0ec0..ac0ba0eee28c 100644
--- a/emulators/virtualbox-ose-kmod-legacy/files/patch-src-VBox-HostDrivers-VBoxNetFlt-freebsd-VBoxNetFlt-freebsd.c
+++ b/emulators/virtualbox-ose-kmod-legacy/files/patch-src-VBox-HostDrivers-VBoxNetFlt-freebsd-VBoxNetFlt-freebsd.c
@@ -2,35 +2,6 @@ Index: src/VBox/HostDrivers/VBoxNetFlt/freebsd/VBoxNetFlt-freebsd.c
===================================================================
--- src/VBox/HostDrivers/VBoxNetFlt/freebsd/VBoxNetFlt-freebsd.c (revision 23391)
+++ src/VBox/HostDrivers/VBoxNetFlt/freebsd/VBoxNetFlt-freebsd.c (working copy)
-@@ -43,6 +43,8 @@
- #include <sys/socket.h>
- #include <sys/sockio.h>
- #include <sys/syscallsubr.h>
-+#include <sys/queue.h>
-+#include <sys/taskqueue.h>
-
- #include <net/if.h>
- #include <net/if_var.h>
-@@ -78,8 +80,6 @@
- static ng_rcvdata_t ng_vboxnetflt_rcvdata;
- static ng_disconnect_t ng_vboxnetflt_disconnect;
- static int ng_vboxnetflt_mod_event(module_t mod, int event, void *data);
--static int ng_vboxnetflt_rcv_in(hook_p node, item_p item);
--static int ng_vboxnetflt_rcv_out(hook_p node, item_p item);
-
- /** Netgraph node type */
- #define NG_VBOXNETFLT_NODE_TYPE "vboxnetflt"
-@@ -112,8 +112,8 @@
- {
- .version = NG_ABI_VERSION,
- .name = NG_VBOXNETFLT_NODE_TYPE,
-- .mod_event = vboxnetflt_modevent,
-- .constructor = ng_vboxnetflt_constructor,
-+ .mod_event = vboxnetflt_modevent,
-+ .constructor = ng_vboxnetflt_constructor,
- .rcvmsg = ng_vboxnetflt_rcvmsg,
- .shutdown = ng_vboxnetflt_shutdown,
- .newhook = ng_vboxnetflt_newhook,
@@ -122,7 +122,7 @@
.cmdlist = ng_vboxnetflt_cmdlist,
};
@@ -40,345 +11,12 @@ Index: src/VBox/HostDrivers/VBoxNetFlt/freebsd/VBoxNetFlt-freebsd.c
MODULE_DEPEND(ng_vboxnetflt, vboxdrv, 1, 1, 1);
/**
-@@ -267,16 +267,12 @@
- if (strcmp(name, NG_VBOXNETFLT_HOOK_IN) == 0)
- {
- #if __FreeBSD_version >= 800000
-- NG_HOOK_SET_RCVDATA(hook, ng_vboxnetflt_rcv_in);
- NG_HOOK_SET_TO_INBOUND(hook);
- #endif
- pThis->u.s.input = hook;
- }
- else if (strcmp(name, NG_VBOXNETFLT_HOOK_OUT) == 0)
- {
--#if __FreeBSD_version >= 800000
-- NG_HOOK_SET_RCVDATA(hook, ng_vboxnetflt_rcv_out);
--#endif
- pThis->u.s.output = hook;
- }
- else
-@@ -310,161 +306,171 @@
-
- /**
- * Handle data on netgraph hooks.
-+ * Frames processing is deferred to a taskqueue because this might
-+ * be called with non-sleepable locks held and code paths inside
-+ * the virtual switch might sleep.
- */
- static int ng_vboxnetflt_rcvdata(hook_p hook, item_p item)
- {
- const node_p node = NG_HOOK_NODE(hook);
- PVBOXNETFLTINS pThis = NG_NODE_PRIVATE(node);
-+ struct ifnet *ifp = pThis->u.s.ifp;
- struct mbuf *m;
-+ struct m_tag *mtag;
-+ bool fActive;
-
-+ fActive = ASMAtomicUoReadBool(&pThis->fActive);
-+
-+ NGI_GET_M(item, m);
-+ NG_FREE_ITEM(item);
-+
-+ /* Locate tag to see if processing should be skipped for this frame */
-+ mtag = m_tag_locate(m, MTAG_VBOX, PACKET_TAG_VBOX, NULL);
-+ if (mtag != NULL)
-+ {
-+ m_tag_unlink(m, mtag);
-+ m_tag_free(mtag);
-+ }
-+
-+ /*
-+ * Handle incoming hook. This is connected to the
-+ * input path of the interface, thus handling incoming frames.
-+ */
- if (pThis->u.s.input == hook)
-- return ng_vboxnetflt_rcv_in(hook, item);
-+ {
-+ if (mtag != NULL || !fActive)
-+ {
-+ ether_demux(ifp, m);
-+ return (0);
-+ }
-+ mtx_lock_spin(&pThis->u.s.inq.ifq_mtx);
-+ _IF_ENQUEUE(&pThis->u.s.inq, m);
-+ mtx_unlock_spin(&pThis->u.s.inq.ifq_mtx);
-+ taskqueue_enqueue_fast(taskqueue_fast, &pThis->u.s.tskin);
-+ }
-+ /**
-+ * Handle mbufs on the outgoing hook, frames going to the interface
-+ */
- else if (pThis->u.s.output == hook)
-- return ng_vboxnetflt_rcv_out(hook, item);
-+ {
-+ if (mtag != NULL || !fActive)
-+ return ether_output_frame(ifp, m);
-+ mtx_lock_spin(&pThis->u.s.outq.ifq_mtx);
-+ _IF_ENQUEUE(&pThis->u.s.outq, m);
-+ mtx_unlock_spin(&pThis->u.s.outq.ifq_mtx);
-+ taskqueue_enqueue_fast(taskqueue_fast, &pThis->u.s.tskout);
-+ }
- else
- {
-- NGI_GET_M(item, m);
-- NG_FREE_ITEM(item);
-+ m_freem(m);
- }
- return (0);
- }
-
-+static int ng_vboxnetflt_shutdown(node_p node)
-+{
-+ PVBOXNETFLTINS pThis = NG_NODE_PRIVATE(node);
-+ bool fActive;
-+
-+ /* Prevent node shutdown if we're active */
-+ fActive = ASMAtomicUoReadBool(&pThis->fActive);
-+ if (fActive)
-+ return (EBUSY);
-+ NG_NODE_UNREF(node);
-+ return (0);
-+}
-+
-+static int ng_vboxnetflt_disconnect(hook_p hook)
-+{
-+ return (0);
-+}
-+
- /**
-- * Handle incoming hook. This is connected to the
-- * input path of the interface, thus handling incoming frames.
-+ * Input processing task, handles incoming frames
- */
--static int ng_vboxnetflt_rcv_in(hook_p hook, item_p item)
-+static void vboxNetFltFreeBSDinput(void *arg, int pending)
- {
-+ PVBOXNETFLTINS pThis = (PVBOXNETFLTINS)arg;
- struct mbuf *m, *m0;
-- struct m_tag *mtag;
-- const node_p node = NG_HOOK_NODE(hook);
-- PVBOXNETFLTINS pThis = NG_NODE_PRIVATE(node);
- struct ifnet *ifp = pThis->u.s.ifp;
-- bool fActive, fDropIt = false;
- unsigned int cSegs = 0;
-+ bool fDropIt = false, fActive;
- PINTNETSG pSG;
-
-- NGI_GET_M(item, m);
-- NG_FREE_ITEM(item);
--
-- fActive = ASMAtomicUoReadBool(&pThis->fActive);
-- if (!fActive)
-- goto out;
--
-- mtag = m_tag_locate(m, MTAG_VBOX, PACKET_TAG_VBOX, NULL);
-- if (mtag != NULL)
-- {
-- m_tag_unlink(m, mtag);
-- m_tag_free(mtag);
-- goto out;
-- }
- vboxNetFltRetain(pThis, true /* fBusy */);
--
-- for (m0 = m; m0 != NULL; m0 = m0->m_next)
-+ for (;;)
- {
-- if (m0->m_len > 0)
-- cSegs++;
-- }
-+ mtx_lock_spin(&pThis->u.s.inq.ifq_mtx);
-+ _IF_DEQUEUE(&pThis->u.s.inq, m);
-+ mtx_unlock_spin(&pThis->u.s.inq.ifq_mtx);
-+ if (m == NULL)
-+ break;
-
-+ for (m0 = m; m0 != NULL; m0 = m0->m_next)
-+ if (m0->m_len > 0)
-+ cSegs++;
-+
- #ifdef PADD_RUNT_FRAMES_FROM_HOST
-- if (m_length(m, NULL) < 60)
-- cSegs++;
-+ if (m_length(m, NULL) < 60)
-+ cSegs++;
- #endif
-
-- /* Create a copy of the mbuf and hand it to the virtual switch */
-- pSG = RTMemTmpAlloc(RT_OFFSETOF(INTNETSG, aSegs[cSegs]));
-- vboxNetFltFreeBSDMBufToSG(pThis, m, pSG, cSegs, 0);
-- fDropIt = pThis->pSwitchPort->pfnRecv(pThis->pSwitchPort, pSG, INTNETTRUNKDIR_WIRE);
-- RTMemTmpFree(pSG);
-+ /* Create a copy and deliver to the virtual switch */
-+ pSG = RTMemTmpAlloc(RT_OFFSETOF(INTNETSG, aSegs[cSegs]));
-+ vboxNetFltFreeBSDMBufToSG(pThis, m, pSG, cSegs, 0);
-+ fDropIt = pThis->pSwitchPort->pfnRecv(pThis->pSwitchPort, pSG, INTNETTRUNKDIR_HOST);
-+ RTMemTmpFree(pSG);
-+ if (fDropIt)
-+ m_freem(m);
-+ else
-+ ether_demux(ifp, m);
-+ }
- vboxNetFltRelease(pThis, true /* fBusy */);
--
--out:
-- /* Only deliver it to the host stack if the destination weren't a guest */
-- if (fDropIt)
-- {
-- m_freem(m);
-- return (0);
-- }
-- ether_demux(ifp, m);
-- return (0);
- }
-
- /**
-- * Handle mbufs on the outgoing hook, frames going to the interface
-+ * Output processing task, handles outgoing frames
- */
--static int ng_vboxnetflt_rcv_out(hook_p hook, item_p item)
-+static void vboxNetFltFreeBSDoutput(void *arg, int pending)
- {
-+ PVBOXNETFLTINS pThis = (PVBOXNETFLTINS)arg;
- struct mbuf *m, *m0;
-- struct m_tag *mtag;
-- const node_p node = NG_HOOK_NODE(hook);
-- PVBOXNETFLTINS pThis = NG_NODE_PRIVATE(node);
- struct ifnet *ifp = pThis->u.s.ifp;
- unsigned int cSegs = 0;
- bool fDropIt = false, fActive;
- PINTNETSG pSG;
-
-- NGI_GET_M(item, m);
-- NG_FREE_ITEM(item);
--
-- fActive = ASMAtomicUoReadBool(&pThis->fActive);
-- if (!fActive)
-- return ether_output_frame(ifp, m);
--
- vboxNetFltRetain(pThis, true /* fBusy */);
-- /* Pass directly to interface if the packet originated from us */
-- mtag = m_tag_locate(m, MTAG_VBOX, PACKET_TAG_VBOX, NULL);
-- if (mtag != NULL)
-+ for (;;)
- {
-- m_tag_unlink(m, mtag);
-- m_tag_free(mtag);
-- goto out;
-- }
-+ mtx_lock_spin(&pThis->u.s.outq.ifq_mtx);
-+ _IF_DEQUEUE(&pThis->u.s.outq, m);
-+ mtx_unlock_spin(&pThis->u.s.outq.ifq_mtx);
-+ if (m == NULL)
-+ break;
-
-- for (m0 = m; m0 != NULL; m0 = m0->m_next)
-- {
-- if (m0->m_len > 0)
-- cSegs++;
-- }
-+ for (m0 = m; m0 != NULL; m0 = m0->m_next)
-+ if (m0->m_len > 0)
-+ cSegs++;
-
- #ifdef PADD_RUNT_FRAMES_FROM_HOST
-- if (m_length(m, NULL) < 60)
-- cSegs++;
-+ if (m_length(m, NULL) < 60)
-+ cSegs++;
- #endif
-- /* Create a copy and deliver to the virtual switch */
-- pSG = RTMemTmpAlloc(RT_OFFSETOF(INTNETSG, aSegs[cSegs]));
-- vboxNetFltFreeBSDMBufToSG(pThis, m, pSG, cSegs, 0);
-- fDropIt = pThis->pSwitchPort->pfnRecv(pThis->pSwitchPort, pSG, INTNETTRUNKDIR_HOST);
-- RTMemTmpFree(pSG);
-+ /* Create a copy and deliver to the virtual switch */
-+ pSG = RTMemTmpAlloc(RT_OFFSETOF(INTNETSG, aSegs[cSegs]));
-+ vboxNetFltFreeBSDMBufToSG(pThis, m, pSG, cSegs, 0);
-+ fDropIt = pThis->pSwitchPort->pfnRecv(pThis->pSwitchPort, pSG, INTNETTRUNKDIR_HOST);
-+ RTMemTmpFree(pSG);
-
--out:
-+ if (fDropIt)
-+ m_freem(m);
-+ else
-+ ether_output_frame(ifp, m);
-+ }
- vboxNetFltRelease(pThis, true /* fBusy */);
-- if (fDropIt)
-- {
-- m_freem(m);
-- return (0);
-- }
--
-- return ether_output_frame(ifp, m);
- }
-
--static int ng_vboxnetflt_shutdown(node_p node)
--{
-- PVBOXNETFLTINS pThis = NG_NODE_PRIVATE(node);
-- bool fActive;
--
-- /* Prevent node shutdown if we're active */
-- fActive = ASMAtomicUoReadBool(&pThis->fActive);
-- if (fActive)
-- return (EBUSY);
-- NG_NODE_UNREF(node);
-- return (0);
--}
--
--static int ng_vboxnetflt_disconnect(hook_p hook)
--{
-- return (0);
--}
--
- /**
- * Called to deliver a frame to either the host, the wire or both.
- */
-@@ -536,13 +542,23 @@
-
- /* Create a new netgraph node for this instance */
- if (ng_make_node_common(&ng_vboxnetflt_typestruct, &node) != 0)
-- return VERR_INTERNAL_ERROR;
-+ return VERR_INTERNAL_ERROR;
-
- RTSpinlockAcquire(pThis->hSpinlock, &Tmp);
- ASMAtomicUoWritePtr((void * volatile *)&pThis->u.s.ifp, ifp);
- pThis->u.s.node = node;
- bcopy(IF_LLADDR(ifp), &pThis->u.s.Mac, ETHER_ADDR_LEN);
- ASMAtomicUoWriteBool(&pThis->fDisconnectedFromHost, false);
-+ /* Initialize deferred input queue */
-+ bzero(&pThis->u.s.inq, sizeof(struct ifqueue));
-+ mtx_init(&pThis->u.s.inq.ifq_mtx, "vboxnetflt inq", NULL, MTX_SPIN);
-+ TASK_INIT(&pThis->u.s.tskin, 0, vboxNetFltFreeBSDinput, pThis);
-+
-+ /* Initialize deferred output queue */
-+ bzero(&pThis->u.s.outq, sizeof(struct ifqueue));
-+ mtx_init(&pThis->u.s.outq.ifq_mtx, "vboxnetflt outq", NULL, MTX_SPIN);
-+ TASK_INIT(&pThis->u.s.tskout, 0, vboxNetFltFreeBSDoutput, pThis);
-+
- RTSpinlockRelease(pThis->hSpinlock, &Tmp);
-
- NG_NODE_SET_PRIVATE(node, pThis);
-@@ -571,7 +587,10 @@
- }
-
- if (ifp0 != NULL)
-+ {
-+ vboxNetFltOsDeleteInstance(pThis);
- vboxNetFltOsInitInstance(pThis, NULL);
-+ }
-
- return !ASMAtomicUoReadBool(&pThis->fDisconnectedFromHost);
- }
-@@ -579,6 +598,12 @@
- void vboxNetFltOsDeleteInstance(PVBOXNETFLTINS pThis)
- {
-
-+ taskqueue_drain(taskqueue_fast, &pThis->u.s.tskin);
-+ taskqueue_drain(taskqueue_fast, &pThis->u.s.tskout);
-+
-+ mtx_destroy(&pThis->u.s.inq.ifq_mtx);
-+ mtx_destroy(&pThis->u.s.outq.ifq_mtx);
-+
- if (pThis->u.s.node != NULL)
- ng_rmnode_self(pThis->u.s.node);
- pThis->u.s.node = NULL;
+@@ -418,7 +418,7 @@
+ /* Create a copy and deliver to the virtual switch */
+ pSG = RTMemTmpAlloc(RT_OFFSETOF(INTNETSG, aSegs[cSegs]));
+ vboxNetFltFreeBSDMBufToSG(pThis, m, pSG, cSegs, 0);
+- fDropIt = pThis->pSwitchPort->pfnRecv(pThis->pSwitchPort, pSG, INTNETTRUNKDIR_HOST);
++ fDropIt = pThis->pSwitchPort->pfnRecv(pThis->pSwitchPort, pSG, INTNETTRUNKDIR_WIRE);
+ RTMemTmpFree(pSG);
+ if (fDropIt)
+ m_freem(m);
diff --git a/emulators/virtualbox-ose-kmod-legacy/files/patch-src-VBox-Runtime-r0drv-freebsd-the-freebsd-kernel.h b/emulators/virtualbox-ose-kmod-legacy/files/patch-src-VBox-Runtime-r0drv-freebsd-the-freebsd-kernel.h
deleted file mode 100644
index 4332049487c3..000000000000
--- a/emulators/virtualbox-ose-kmod-legacy/files/patch-src-VBox-Runtime-r0drv-freebsd-the-freebsd-kernel.h
+++ /dev/null
@@ -1,11 +0,0 @@
---- src/VBox/Runtime/r0drv/freebsd/the-freebsd-kernel.h.orig 2009-09-11 14:48:47.000000000 +0200
-+++ src/VBox/Runtime/r0drv/freebsd/the-freebsd-kernel.h 2009-09-11 14:48:54.000000000 +0200
-@@ -76,7 +76,7 @@
- # define SLEEPQ_TIMEDWAIT_SIG(EventInt) sleepq_timedwait_sig(EventInt, 0)
- # define SLEEPQ_WAIT(EventInt) sleepq_wait(EventInt, 0)
- # define SLEEPQ_WAIT_SIG(EventInt) sleepq_wait_sig(EventInt, 0)
--#elif
-+#else
- # define SLEEPQ_TIMEDWAIT(EventInt) sleepq_timedwait(EventInt)
- # define SLEEPQ_TIMEDWAIT_SIG(EventInt) sleepq_timedwait_sig(EventInt)
- # define SLEEPQ_WAIT(EventInt) sleepq_wait(EventInt)
diff --git a/emulators/virtualbox-ose-kmod-legacy/files/patch-src-VBox-apps-adpctl_VBoxNetAdpCtl.cpp b/emulators/virtualbox-ose-kmod-legacy/files/patch-src-VBox-apps-adpctl_VBoxNetAdpCtl.cpp
deleted file mode 100644
index 955bf7a3a151..000000000000
--- a/emulators/virtualbox-ose-kmod-legacy/files/patch-src-VBox-apps-adpctl_VBoxNetAdpCtl.cpp
+++ /dev/null
@@ -1,207 +0,0 @@
---- src/apps/adpctl/VBoxNetAdpCtl.cpp.r22902 2009-04-10 14:03:59.000000000 +0200
-+++ src/apps/adpctl/VBoxNetAdpCtl.cpp 2009-09-16 14:07:11.000000000 +0200
-@@ -1,4 +1,4 @@
--/* $Id: VBoxNetAdpCtl.cpp 18864 2009-04-10 12:03:59Z vboxsync $ */
-+/* $Id: VBoxNetAdpCtl.cpp 23064 2009-09-16 12:07:11Z vboxsync $ */
- /** @file
- * Apps - VBoxAdpCtl, Configuration tool for vboxnetX adapters.
- */
-@@ -24,7 +24,6 @@
- /*******************************************************************************
- * Header Files *
- *******************************************************************************/
--#include <assert.h>
- #include <stdio.h>
- #include <stdlib.h>
- #include <string.h>
-@@ -36,11 +35,12 @@
- # include <sys/ioccom.h>
- #endif
-
--/* @todo Error codes must be moved to some header file */
--#define ADPCTLERR_NO_CTL_DEV 3
--#define ADPCTLERR_IOCTL_FAILED 4
-+/** @todo Error codes must be moved to some header file */
-+#define ADPCTLERR_BAD_NAME 2
-+#define ADPCTLERR_NO_CTL_DEV 3
-+#define ADPCTLERR_IOCTL_FAILED 4
-
--/* @todo These are duplicates from src/VBox/HostDrivers/VBoxNetAdp/VBoxNetAdpInternal.h */
-+/** @todo These are duplicates from src/VBox/HostDrivers/VBoxNetAdp/VBoxNetAdpInternal.h */
- #define VBOXNETADP_CTL_DEV_NAME "/dev/vboxnetctl"
- #define VBOXNETADP_NAME "vboxnet"
- #define VBOXNETADP_MAX_NAME_LEN 32
-@@ -85,6 +85,7 @@
- pcszArg5, /* [network mask] */
- NULL /* terminator */
- };
-+ char * const envp[] = { (char*)"LC_ALL=C", NULL };
- int rc = EXIT_SUCCESS;
- pid_t childPid = fork();
- switch (childPid)
-@@ -94,7 +95,7 @@
- rc = EXIT_FAILURE;
- break;
- case 0: /* Child process. */
-- if (execv(VBOXADPCTL_IFCONFIG_PATH, (char * const*)argv) == -1)
-+ if (execve(VBOXADPCTL_IFCONFIG_PATH, (char * const*)argv, envp) == -1)
- rc = EXIT_FAILURE;
- break;
- default: /* Parent process. */
-@@ -108,15 +109,39 @@
- #define MAX_ADDRESSES 128
- #define MAX_ADDRLEN 64
-
--static bool removeAddresses(const char *pszAdapterName)
-+static bool removeAddresses(char *pszAdapterName)
- {
-- char szCmd[1024], szBuf[1024];
-+ char szBuf[1024];
- char aszAddresses[MAX_ADDRESSES][MAX_ADDRLEN];
-+ int rc;
-+ int fds[2];
-+ char * const argv[] = { VBOXADPCTL_IFCONFIG_PATH, pszAdapterName, NULL };
-+ char * const envp[] = { (char*)"LC_ALL=C", NULL };
-
- memset(aszAddresses, 0, sizeof(aszAddresses));
-- snprintf(szCmd, sizeof(szCmd), VBOXADPCTL_IFCONFIG_PATH " %s", pszAdapterName);
-- FILE *fp = popen(szCmd, "r");
-
-+ rc = pipe(fds);
-+ if (rc < 0)
-+ return false;
-+
-+ pid_t pid = fork();
-+ if (pid < 0)
-+ return false;
-+
-+ if (pid == 0)
-+ {
-+ /* child */
-+ close(fds[0]);
-+ close(STDOUT_FILENO);
-+ rc = dup2(fds[1], STDOUT_FILENO);
-+ if (rc >= 0)
-+ execve(VBOXADPCTL_IFCONFIG_PATH, argv, envp);
-+ return false;
-+ }
-+
-+ /* parent */
-+ close(fds[1]);
-+ FILE *fp = fdopen(fds[0], "r");
- if (!fp)
- return false;
-
-@@ -124,9 +149,6 @@
- for (cAddrs = 0; cAddrs < MAX_ADDRESSES && fgets(szBuf, sizeof(szBuf), fp);)
- {
- int cbSkipWS = strspn(szBuf, " \t");
--#if 0 /* Don't use this! assert() breaks the mac build. Use IPRT or be a rectangular building thing. */
-- assert(cbSkipWS < 20);
--#endif
- char *pszWord = strtok(szBuf + cbSkipWS, " ");
- /* We are concerned with IPv6 address lines only. */
- if (!pszWord || strcmp(pszWord, "inet6"))
-@@ -143,11 +165,12 @@
- continue;
- strncpy(aszAddresses[cAddrs++], pszWord, MAX_ADDRLEN-1);
- }
-- pclose(fp);
-+ fclose(fp);
-
- for (int i = 0; i < cAddrs; i++)
- {
-- if (executeIfconfig(pszAdapterName, "inet6", VBOXADPCTL_DEL_CMD, aszAddresses[i]) != EXIT_SUCCESS)
-+ if (executeIfconfig(pszAdapterName, "inet6",
-+ VBOXADPCTL_DEL_CMD, aszAddresses[i]) != EXIT_SUCCESS)
- return false;
- }
-
-@@ -166,19 +189,41 @@
- int rc = ioctl(fd, uCmd, pData);
- if (rc == -1)
- {
-- perror("VBoxNetAdpCtl: ioctl failed for " VBOXNETADP_CTL_DEV_NAME);
-+ perror("VBoxNetAdpCtl: ioctl failed for " VBOXNETADP_CTL_DEV_NAME);
- rc = ADPCTLERR_IOCTL_FAILED;
- }
--
-+
- close(fd);
--
-+
- return rc;
- }
-
-+int checkAdapterName(const char *pcszNameIn, char *pszNameOut)
-+{
-+ int iAdapterIndex = -1;
-+
-+ if ( strlen(pcszNameIn) >= VBOXNETADP_MAX_NAME_LEN
-+ || sscanf(pcszNameIn, "vboxnet%d", &iAdapterIndex) != 1
-+ || iAdapterIndex < 0 || iAdapterIndex > 99 )
-+ {
-+ fprintf(stderr, "Setting configuration for %s is not supported.\n", pcszNameIn);
-+ return ADPCTLERR_BAD_NAME;
-+ }
-+ sprintf(pszNameOut, "vboxnet%d", iAdapterIndex);
-+ if (strcmp(pszNameOut, pcszNameIn))
-+ {
-+ fprintf(stderr, "Invalid adapter name %s.\n", pcszNameIn);
-+ return ADPCTLERR_BAD_NAME;
-+ }
-+
-+ return 0;
-+}
-+
- int main(int argc, char *argv[])
-
- {
-- const char *pszAdapterName;
-+ char szAdapterName[VBOXNETADP_MAX_NAME_LEN];
-+ char *pszAdapterName;
- const char *pszAddress;
- const char *pszNetworkMask = NULL;
- const char *pszOption = NULL;
-@@ -216,13 +261,18 @@
- pszAddress = argv[2];
- if (strcmp("remove", pszAddress) == 0)
- {
-- strncpy(Req.szName, pszAdapterName, sizeof(Req.szName));
-+ rc = checkAdapterName(pszAdapterName, szAdapterName);
-+ if (rc)
-+ return rc;
-+ memset(&Req, '\0', sizeof(Req));
-+ snprintf(Req.szName, sizeof(Req.szName), "%s", szAdapterName);
- return doIOCtl(VBOXNETADP_CTL_REMOVE, &Req);
- }
- break;
- case 2:
- if (strcmp("add", argv[1]) == 0)
- {
-+ memset(&Req, '\0', sizeof(Req));
- rc = doIOCtl(VBOXNETADP_CTL_ADD, &Req);
- if (rc == 0)
- puts(Req.szName);
-@@ -237,11 +287,11 @@
- return 1;
- }
-
-- if (strncmp("vboxnet", pszAdapterName, 7))
-- {
-- fprintf(stderr, "Setting configuration for %s is not supported.\n", pszAdapterName);
-- return 2;
-- }
-+ rc = checkAdapterName(pszAdapterName, szAdapterName);
-+ if (rc)
-+ return rc;
-+
-+ pszAdapterName = szAdapterName;
-
- if (fRemove)
- {
-@@ -276,3 +326,4 @@
- }
- return rc;
- }
-+
diff --git a/emulators/virtualbox-ose-kmod-legacy/files/pkg-install.in b/emulators/virtualbox-ose-kmod-legacy/files/pkg-install.in
deleted file mode 100644
index 5d5268d8e8ce..000000000000
--- a/emulators/virtualbox-ose-kmod-legacy/files/pkg-install.in
+++ /dev/null
@@ -1,22 +0,0 @@
-#!/bin/sh
-
-case $2 in
-POST-INSTALL)
- GROUP=%%VBOXGROUP%%
- GID=%%VBOXGID%%
- PW=/usr/sbin/pw
-
- if ${PW} group show "${GROUP}" 2>/dev/null; then
- echo "You already have a group \"${GROUP}\", so I will use it."
- else
- if ${PW} groupadd ${GROUP} -g ${GID}; then
- echo "Added group \"${GROUP}\"."
- else
- echo "Adding group \"${GROUP}\" failed..."
- exit 1
- fi
- fi
-
- exit 0
- ;;
-esac
diff --git a/emulators/virtualbox-ose-kmod-legacy/files/vboxnet.in b/emulators/virtualbox-ose-kmod-legacy/files/vboxnet.in
new file mode 100644
index 000000000000..69cb0e402521
--- /dev/null
+++ b/emulators/virtualbox-ose-kmod-legacy/files/vboxnet.in
@@ -0,0 +1,71 @@
+#!/bin/sh
+#
+# $FreeBSD$
+#
+
+# PROVIDE: vboxnet
+# REQUIRE: FILESYSTEMS
+# BEFORE: netif
+# KEYWORD: nojail
+
+#
+# Add the following lines to /etc/rc.conf.local or /etc/rc.conf
+# to enable this service:
+#
+# vboxnet_enable (bool): Set to NO by default.
+# Set it to YES to load network related kernel modules on startup
+
+. %%RC_SUBR%%
+
+name="vboxnet"
+rcvar=${name}_enable
+start_cmd="vboxnet_start"
+stop_cmd="vboxnet_stop"
+
+vboxnet_start()
+{
+ if ! kldstat -q -m ng_vboxnetflt;
+ then
+ if ! kldload vboxnetflt > /dev/null 2>&1;
+ then
+ warn "Can't load vboxnetflt module."
+ return 1
+ fi
+ fi
+
+ if ! kldstat -q -m vboxnetadp;
+ then
+ if ! kldload vboxnetadp > /dev/null 2>&1;
+ then
+ warn "Can't load vboxnetadp module."
+ return 1
+ fi
+ fi
+}
+
+vboxnet_stop()
+{
+ if kldstat -q -m vboxnetadp;
+ then
+ if ! kldunload vboxnetadp > /dev/null 2>&1;
+ then
+ warn "Can't unload vboxnetadp module."
+ return 1
+ fi
+ fi
+
+ if kldstat -q -m ng_vboxnetflt;
+ then
+ if ! kldunload vboxnetflt > /dev/null 2>&1;
+ then
+ warn "Can't unload vboxnetflt module."
+ return 1
+ fi
+ fi
+}
+
+load_rc_config $name
+
+: ${vboxnet_enable="NO"}
+
+run_rc_command "$1"
diff --git a/emulators/virtualbox-ose-kmod-legacy/pkg-message b/emulators/virtualbox-ose-kmod-legacy/pkg-message
deleted file mode 100644
index 91b8b16427cd..000000000000
--- a/emulators/virtualbox-ose-kmod-legacy/pkg-message
+++ /dev/null
@@ -1,26 +0,0 @@
-=============================================================================
-
-VirtualBox was installed.
-
-You need to load the vboxdrv kernel module and a mounted /proc filesystem.
-
-% mount -t procfs proc /proc
-% kldload vboxdrv
-
-For bridged networking you also need to load the vboxnetflt kernel module.
-
-% kldload vboxnetflt
-
-You also have to add all users to your vboxusers group in order to use vbox.
-
-% pw groupmod vboxusers -m jerry
-
-Running VirtualBox as non-root user may fail with a fatal error
-NS_ERROR_FACTORY_NOT_REGISTERED. In this case delete /tmp/.vbox-*-ipc file.
-
-Check wiki page for known issues and troubleshooting:
-http://wiki.freebsd.org/VirtualBox
-
-Please report any problems to emulation@. Thanks!
-
-=============================================================================
diff --git a/emulators/virtualbox-ose-kmod-legacy/pkg-plist b/emulators/virtualbox-ose-kmod-legacy/pkg-plist
index f8ade22c00a7..f4567ba3fc9a 100644
--- a/emulators/virtualbox-ose-kmod-legacy/pkg-plist
+++ b/emulators/virtualbox-ose-kmod-legacy/pkg-plist
@@ -1,598 +1,4 @@
-%%X11%%bin/VBoxBFE
-bin/VBoxHeadless
-bin/VBoxManage
-bin/VBoxNetAdpCtl
-bin/VBoxNetDHCP
-%%X11%%bin/VBoxSDL
-bin/VBoxSVC
-%%X11%%bin/VBoxTestOGL
-bin/VBoxXPCOMIPCD
-%%QT4%%bin/VirtualBox
-%%X11%%lib/virtualbox/VBoxBFE
-%%X11%%lib/virtualbox/VBoxBFE.so
-lib/virtualbox/VBoxDD.so
-lib/virtualbox/VBoxDD2.so
-lib/virtualbox/VBoxDDU.so
-lib/virtualbox/VBoxGuestPropSvc.so
-lib/virtualbox/VBoxHeadless
-lib/virtualbox/VBoxHeadless.so
-%%QT4%%lib/virtualbox/VBoxKeyboard.so
-lib/virtualbox/VBoxManage
-lib/virtualbox/VBoxNetAdpCtl
-lib/virtualbox/VBoxNetDHCP
-lib/virtualbox/VBoxNetDHCP.so
-%%X11%%lib/virtualbox/VBoxOGLhostcrutil.so
-%%X11%%lib/virtualbox/VBoxOGLhosterrorspu.so
-%%X11%%lib/virtualbox/VBoxOGLrenderspu.so
-lib/virtualbox/VBoxPython.so
-lib/virtualbox/VBoxREM.so
-%%X11%%lib/virtualbox/VBoxTestOGL
-%%I386%%lib/virtualbox/VBoxREM32.so
-%%I386%%lib/virtualbox/VBoxREM64.so
-lib/virtualbox/VBoxRT.so
-%%X11%%lib/virtualbox/VBoxSDL
-%%X11%%lib/virtualbox/VBoxSDL.so
-lib/virtualbox/VBoxSVC
-lib/virtualbox/VBoxSharedClipboard.so
-%%X11%%lib/virtualbox/VBoxSharedCrOpenGL.so
-lib/virtualbox/VBoxSharedFolders.so
-lib/virtualbox/VBoxVMM.so
-lib/virtualbox/VBoxXPCOM.so
-lib/virtualbox/VBoxXPCOMC.so
-lib/virtualbox/VBoxXPCOMIPCD
-%%QT4%%lib/virtualbox/VirtualBox
-%%QT4%%lib/virtualbox/VirtualBox.so
-lib/virtualbox/VBoxDD2GC.gc
-lib/virtualbox/VBoxDDGC.gc
-lib/virtualbox/VMMGC.gc
-lib/virtualbox/VBoxDD2R0.r0
-lib/virtualbox/VBoxDDR0.r0
-%%GUESTADDITIONS%%lib/virtualbox/additions/VBoxGuestAdditions.iso
-%%GUESTADDITIONS%%lib/virtualbox/additions/VBoxGuestAdditions_%%GUEST_VER%%.iso
-lib/virtualbox/VBoxPython%%PYTHON_VERU%%.so
-lib/virtualbox/VMMR0.r0
-lib/virtualbox/components/VirtualBox_XPCOM.xpt
-lib/virtualbox/components/VBoxXPCOMIPCC.so
-lib/virtualbox/components/VBoxSVCM.so
-lib/virtualbox/components/VBoxC.so
-lib/virtualbox/components/VBoxXPCOMBase.xpt
-%%NLS%%%%DATADIR%%/nls/VirtualBox_ar.qm
-%%NLS%%%%DATADIR%%/nls/VirtualBox_bg.qm
-%%NLS%%%%DATADIR%%/nls/VirtualBox_ca.qm
-%%NLS%%%%DATADIR%%/nls/VirtualBox_cs.qm
-%%NLS%%%%DATADIR%%/nls/VirtualBox_de.qm
-%%NLS%%%%DATADIR%%/nls/VirtualBox_el.qm
-%%NLS%%%%DATADIR%%/nls/VirtualBox_es.qm
-%%NLS%%%%DATADIR%%/nls/VirtualBox_eu.qm
-%%NLS%%%%DATADIR%%/nls/VirtualBox_fi.qm
-%%NLS%%%%DATADIR%%/nls/VirtualBox_fr.qm
-%%NLS%%%%DATADIR%%/nls/VirtualBox_hu.qm
-%%NLS%%%%DATADIR%%/nls/VirtualBox_id.qm
-%%NLS%%%%DATADIR%%/nls/VirtualBox_it.qm
-%%NLS%%%%DATADIR%%/nls/VirtualBox_ja.qm
-%%NLS%%%%DATADIR%%/nls/VirtualBox_km_KH.qm
-%%NLS%%%%DATADIR%%/nls/VirtualBox_ko.qm
-%%NLS%%%%DATADIR%%/nls/VirtualBox_nl.qm
-%%NLS%%%%DATADIR%%/nls/VirtualBox_pl.qm
-%%NLS%%%%DATADIR%%/nls/VirtualBox_pt.qm
-%%NLS%%%%DATADIR%%/nls/VirtualBox_pt_BR.qm
-%%NLS%%%%DATADIR%%/nls/VirtualBox_ro.qm
-%%NLS%%%%DATADIR%%/nls/VirtualBox_ru.qm
-%%NLS%%%%DATADIR%%/nls/VirtualBox_sk.qm
-%%NLS%%%%DATADIR%%/nls/VirtualBox_sr.qm
-%%NLS%%%%DATADIR%%/nls/VirtualBox_sv.qm
-%%NLS%%%%DATADIR%%/nls/VirtualBox_tr.qm
-%%NLS%%%%DATADIR%%/nls/VirtualBox_uk.qm
-%%NLS%%%%DATADIR%%/nls/VirtualBox_zh_CN.qm
-%%NLS%%%%DATADIR%%/nls/VirtualBox_zh_TW.qm
-%%NLS%%%%DATADIR%%/nls/qt_ar.qm
-%%NLS%%%%DATADIR%%/nls/qt_bg.qm
-%%NLS%%%%DATADIR%%/nls/qt_ca.qm
-%%NLS%%%%DATADIR%%/nls/qt_cs.qm
-%%NLS%%%%DATADIR%%/nls/qt_de.qm
-%%NLS%%%%DATADIR%%/nls/qt_el.qm
-%%NLS%%%%DATADIR%%/nls/qt_es.qm
-%%NLS%%%%DATADIR%%/nls/qt_eu.qm
-%%NLS%%%%DATADIR%%/nls/qt_fi.qm
-%%NLS%%%%DATADIR%%/nls/qt_fr.qm
-%%NLS%%%%DATADIR%%/nls/qt_hu.qm
-%%NLS%%%%DATADIR%%/nls/qt_id.qm
-%%NLS%%%%DATADIR%%/nls/qt_it.qm
-%%NLS%%%%DATADIR%%/nls/qt_ja.qm
-%%NLS%%%%DATADIR%%/nls/qt_km_KH.qm
-%%NLS%%%%DATADIR%%/nls/qt_ko.qm
-%%NLS%%%%DATADIR%%/nls/qt_nl.qm
-%%NLS%%%%DATADIR%%/nls/qt_pl.qm
-%%NLS%%%%DATADIR%%/nls/qt_pt.qm
-%%NLS%%%%DATADIR%%/nls/qt_pt_BR.qm
-%%NLS%%%%DATADIR%%/nls/qt_ro.qm
-%%NLS%%%%DATADIR%%/nls/qt_ru.qm
-%%NLS%%%%DATADIR%%/nls/qt_sk.qm
-%%NLS%%%%DATADIR%%/nls/qt_sr.qm
-%%NLS%%%%DATADIR%%/nls/qt_sv.qm
-%%NLS%%%%DATADIR%%/nls/qt_tr.qm
-%%NLS%%%%DATADIR%%/nls/qt_uk.qm
-%%NLS%%%%DATADIR%%/nls/qt_zh_CN.qm
-%%NLS%%%%DATADIR%%/nls/qt_zh_TW.qm
-%%QT4%%share/applications/virtualbox.desktop
-%%QT4%%share/icons/hicolor/48x48/apps/VBox.png
-%%DATADIR%%/idl/nsIDebug.idl
-%%DATADIR%%/idl/nsIInterfaceRequestor.idl
-%%DATADIR%%/idl/nsIMemory.idl
-%%DATADIR%%/idl/nsIProgrammingLanguage.idl
-%%DATADIR%%/idl/nsISupports.idl
-%%DATADIR%%/idl/nsITraceRefcnt.idl
-%%DATADIR%%/idl/nsIWeakReference.idl
-%%DATADIR%%/idl/nsIConsoleMessage.idl
-%%DATADIR%%/idl/nsIConsoleService.idl
-%%DATADIR%%/idl/nsIConsoleListener.idl
-%%DATADIR%%/idl/nsIErrorService.idl
-%%DATADIR%%/idl/nsIException.idl
-%%DATADIR%%/idl/nsIExceptionService.idl
-%%DATADIR%%/idl/nsrootidl.idl
-%%DATADIR%%/idl/nsIClassInfo.idl
-%%DATADIR%%/idl/nsIFactory.idl
-%%DATADIR%%/idl/nsIModule.idl
-%%DATADIR%%/idl/nsIComponentRegistrar.idl
-%%DATADIR%%/idl/nsIServiceManager.idl
-%%DATADIR%%/idl/nsIComponentManager.idl
-%%DATADIR%%/idl/nsICategoryManager.idl
-%%DATADIR%%/idl/nsINativeComponentLoader.idl
-%%DATADIR%%/idl/nsIComponentLoader.idl
-%%DATADIR%%/idl/nsIComponentManagerObsolete.idl
-%%DATADIR%%/idl/nsISupportsArray.idl
-%%DATADIR%%/idl/nsIComponentLoaderManager.idl
-%%DATADIR%%/idl/nsICollection.idl
-%%DATADIR%%/idl/nsISerializable.idl
-%%DATADIR%%/idl/nsIEnumerator.idl
-%%DATADIR%%/idl/nsISimpleEnumerator.idl
-%%DATADIR%%/idl/nsIObserverService.idl
-%%DATADIR%%/idl/nsIObserver.idl
-%%DATADIR%%/idl/nsIAtom.idl
-%%DATADIR%%/idl/nsIAtomService.idl
-%%DATADIR%%/idl/nsIProperties.idl
-%%DATADIR%%/idl/nsIPersistentProperties2.idl
-%%DATADIR%%/idl/nsIRecyclingAllocator.idl
-%%DATADIR%%/idl/nsIStringEnumerator.idl
-%%DATADIR%%/idl/nsISupportsPrimitives.idl
-%%DATADIR%%/idl/nsISupportsIterators.idl
-%%DATADIR%%/idl/nsITimelineService.idl
-%%DATADIR%%/idl/nsIVariant.idl
-%%DATADIR%%/idl/nsIArray.idl
-%%DATADIR%%/idl/nsIPropertyBag.idl
-%%DATADIR%%/idl/nsIHashable.idl
-%%DATADIR%%/idl/nsIDirectoryService.idl
-%%DATADIR%%/idl/nsIDirectoryEnumerator.idl
-%%DATADIR%%/idl/nsIFile.idl
-%%DATADIR%%/idl/nsILocalFile.idl
-%%DATADIR%%/idl/nsIInputStream.idl
-%%DATADIR%%/idl/nsILocalFileMac.idl
-%%DATADIR%%/idl/nsIObjectInputStream.idl
-%%DATADIR%%/idl/nsIBinaryInputStream.idl
-%%DATADIR%%/idl/nsIObjectOutputStream.idl
-%%DATADIR%%/idl/nsIBinaryOutputStream.idl
-%%DATADIR%%/idl/nsIStreamBufferAccess.idl
-%%DATADIR%%/idl/nsIOutputStream.idl
-%%DATADIR%%/idl/nsIByteArrayInputStream.idl
-%%DATADIR%%/idl/nsIFastLoadFileControl.idl
-%%DATADIR%%/idl/nsISeekableStream.idl
-%%DATADIR%%/idl/nsIInputStreamTee.idl
-%%DATADIR%%/idl/nsIFastLoadService.idl
-%%DATADIR%%/idl/nsIMultiplexInputStream.idl
-%%DATADIR%%/idl/nsIPipe.idl
-%%DATADIR%%/idl/nsIAsyncInputStream.idl
-%%DATADIR%%/idl/nsIAsyncOutputStream.idl
-%%DATADIR%%/idl/nsIScriptableInputStream.idl
-%%DATADIR%%/idl/nsIStorageStream.idl
-%%DATADIR%%/idl/nsILineInputStream.idl
-%%DATADIR%%/idl/nsIStringStream.idl
-%%DATADIR%%/idl/nsIProxyObjectManager.idl
-%%DATADIR%%/idl/nsIEventQueue.idl
-%%DATADIR%%/idl/nsIEventQueueService.idl
-%%DATADIR%%/idl/nsIRunnable.idl
-%%DATADIR%%/idl/nsIThread.idl
-%%DATADIR%%/idl/nsIEventTarget.idl
-%%DATADIR%%/idl/nsIEnvironment.idl
-%%DATADIR%%/idl/nsITimer.idl
-%%DATADIR%%/idl/nsITimerInternal.idl
-%%DATADIR%%/idl/nsITimerManager.idl
-%%DATADIR%%/idl/nsIInterfaceInfo.idl
-%%DATADIR%%/idl/nsIProcess.idl
-%%DATADIR%%/idl/nsIXPTLoader.idl
-%%DATADIR%%/idl/nsIInterfaceInfoManager.idl
-%%DATADIR%%/idl/ipcIMessageObserver.idl
-%%DATADIR%%/idl/ipcIService.idl
-%%DATADIR%%/idl/ipcIClientObserver.idl
-%%DATADIR%%/idl/ipcILockService.idl
-%%DATADIR%%/idl/ipcIDConnectService.idl
-%%DATADIR%%/idl/ipcITransactionService.idl
-%%DATADIR%%/idl/ipcITransactionObserver.idl
-%%DATADIR%%/idl/VirtualBox_XPCOM.idl
-%%DATADIR%%/samples/tstVBoxAPILinux.cpp
-%%DATADIR%%/samples/Makefile
-include/virtualbox/VBoxCAPI_v2_2.h
-include/virtualbox/VBoxCAPI_v3_0.h
-include/virtualbox/VBoxCAPI_v3_1.h
-include/virtualbox/VirtualBox_XPCOM.h
-include/virtualbox/ipcIClientObserver.h
-include/virtualbox/ipcIDConnectService.h
-include/virtualbox/ipcILockService.h
-include/virtualbox/ipcIMessageObserver.h
-include/virtualbox/ipcIService.h
-include/virtualbox/ipcITransactionObserver.h
-include/virtualbox/ipcITransactionService.h
-include/virtualbox/ipcd/ipcCID.h
-include/virtualbox/ipcd/ipcLockCID.h
-include/virtualbox/ipcd/ipcMessageReader.h
-include/virtualbox/ipcd/ipcMessageWriter.h
-include/virtualbox/ipcd/ipcModule.h
-include/virtualbox/ipcd/ipcModuleUtil.h
-include/virtualbox/ipcd/ipcdclient.h
-include/virtualbox/nsIArray.h
-include/virtualbox/nsIAsyncInputStream.h
-include/virtualbox/nsIAsyncOutputStream.h
-include/virtualbox/nsIAtom.h
-include/virtualbox/nsIAtomService.h
-include/virtualbox/nsIBinaryInputStream.h
-include/virtualbox/nsIBinaryOutputStream.h
-include/virtualbox/nsIByteArrayInputStream.h
-include/virtualbox/nsICategoryManager.h
-include/virtualbox/nsIClassInfo.h
-include/virtualbox/nsICollection.h
-include/virtualbox/nsIComponentLoader.h
-include/virtualbox/nsIComponentLoaderManager.h
-include/virtualbox/nsIComponentManager.h
-include/virtualbox/nsIComponentManagerObsolete.h
-include/virtualbox/nsIComponentRegistrar.h
-include/virtualbox/nsIConsoleListener.h
-include/virtualbox/nsIConsoleMessage.h
-include/virtualbox/nsIConsoleService.h
-include/virtualbox/nsIDebug.h
-include/virtualbox/nsIDirectoryEnumerator.h
-include/virtualbox/nsIDirectoryService.h
-include/virtualbox/nsIEnumerator.h
-include/virtualbox/nsIEnvironment.h
-include/virtualbox/nsIErrorService.h
-include/virtualbox/nsIEventQueue.h
-include/virtualbox/nsIEventQueueService.h
-include/virtualbox/nsIEventTarget.h
-include/virtualbox/nsIException.h
-include/virtualbox/nsIExceptionService.h
-include/virtualbox/nsIFactory.h
-include/virtualbox/nsIFastLoadFileControl.h
-include/virtualbox/nsIFastLoadService.h
-include/virtualbox/nsIFile.h
-include/virtualbox/nsIHashable.h
-include/virtualbox/nsIInputStream.h
-include/virtualbox/nsIInputStreamTee.h
-include/virtualbox/nsIInterfaceInfo.h
-include/virtualbox/nsIInterfaceInfoManager.h
-include/virtualbox/nsIInterfaceRequestor.h
-include/virtualbox/nsILineInputStream.h
-include/virtualbox/nsILocalFile.h
-include/virtualbox/nsILocalFileMac.h
-include/virtualbox/nsIMemory.h
-include/virtualbox/nsIModule.h
-include/virtualbox/nsIMultiplexInputStream.h
-include/virtualbox/nsINativeComponentLoader.h
-include/virtualbox/nsIObjectInputStream.h
-include/virtualbox/nsIObjectOutputStream.h
-include/virtualbox/nsIObserver.h
-include/virtualbox/nsIObserverService.h
-include/virtualbox/nsIOutputStream.h
-include/virtualbox/nsIPersistentProperties2.h
-include/virtualbox/nsIPipe.h
-include/virtualbox/nsIProcess.h
-include/virtualbox/nsIProgrammingLanguage.h
-include/virtualbox/nsIProperties.h
-include/virtualbox/nsIPropertyBag.h
-include/virtualbox/nsIProxyObjectManager.h
-include/virtualbox/nsIRecyclingAllocator.h
-include/virtualbox/nsIRunnable.h
-include/virtualbox/nsIScriptableInputStream.h
-include/virtualbox/nsISeekableStream.h
-include/virtualbox/nsISerializable.h
-include/virtualbox/nsIServiceManager.h
-include/virtualbox/nsISimpleEnumerator.h
-include/virtualbox/nsIStorageStream.h
-include/virtualbox/nsIStreamBufferAccess.h
-include/virtualbox/nsIStringEnumerator.h
-include/virtualbox/nsIStringStream.h
-include/virtualbox/nsISupports.h
-include/virtualbox/nsISupportsArray.h
-include/virtualbox/nsISupportsIterators.h
-include/virtualbox/nsISupportsPrimitives.h
-include/virtualbox/nsIThread.h
-include/virtualbox/nsITimelineService.h
-include/virtualbox/nsITimer.h
-include/virtualbox/nsITimerInternal.h
-include/virtualbox/nsITimerManager.h
-include/virtualbox/nsITraceRefcnt.h
-include/virtualbox/nsIVariant.h
-include/virtualbox/nsIWeakReference.h
-include/virtualbox/nsIXPTLoader.h
-include/virtualbox/nsprpub/nspr.h
-include/virtualbox/nsprpub/plarena.h
-include/virtualbox/nsprpub/plarenas.h
-include/virtualbox/nsprpub/plbase64.h
-include/virtualbox/nsprpub/plerror.h
-include/virtualbox/nsprpub/plgetopt.h
-include/virtualbox/nsprpub/plhash.h
-include/virtualbox/nsprpub/plresolv.h
-include/virtualbox/nsprpub/plstr.h
-include/virtualbox/nsprpub/pratom.h
-include/virtualbox/nsprpub/prbit.h
-include/virtualbox/nsprpub/prclist.h
-include/virtualbox/nsprpub/prcmon.h
-include/virtualbox/nsprpub/prcountr.h
-include/virtualbox/nsprpub/prcvar.h
-include/virtualbox/nsprpub/prdtoa.h
-include/virtualbox/nsprpub/prenv.h
-include/virtualbox/nsprpub/prerr.h
-include/virtualbox/nsprpub/prerror.h
-include/virtualbox/nsprpub/prinet.h
-include/virtualbox/nsprpub/prinit.h
-include/virtualbox/nsprpub/prinrval.h
-include/virtualbox/nsprpub/prio.h
-include/virtualbox/nsprpub/pripcsem.h
-include/virtualbox/nsprpub/prlink.h
-include/virtualbox/nsprpub/md/_iprt_atomic.h
-include/virtualbox/nsprpub/md/_darwin.h
-include/virtualbox/nsprpub/md/_freebsd.h
-include/virtualbox/nsprpub/md/_l4v2.h
-include/virtualbox/nsprpub/md/_linux.h
-include/virtualbox/nsprpub/md/_macos.h
-include/virtualbox/nsprpub/md/_netbsd.h
-include/virtualbox/nsprpub/md/_openbsd.h
-include/virtualbox/nsprpub/md/_os2_errors.h
-include/virtualbox/nsprpub/md/_os2.h
-include/virtualbox/nsprpub/md/_pcos.h
-include/virtualbox/nsprpub/md/_solaris.h
-include/virtualbox/nsprpub/md/_unix_errors.h
-include/virtualbox/nsprpub/md/_unixos.h
-include/virtualbox/nsprpub/md/_pth.h
-include/virtualbox/nsprpub/md/prosdep.h
-include/virtualbox/nsprpub/md/_freebsd.cfg
-include/virtualbox/nsprpub/md/_linux.cfg
-include/virtualbox/nsprpub/md/_darwin.cfg
-include/virtualbox/nsprpub/md/_netbsd.cfg
-include/virtualbox/nsprpub/md/_openbsd.cfg
-include/virtualbox/nsprpub/md/_os2.cfg
-include/virtualbox/nsprpub/md/_solaris32.cfg
-include/virtualbox/nsprpub/md/_l4v2.cfg
-include/virtualbox/nsprpub/md/_solaris64.cfg
-include/virtualbox/nsprpub/prlock.h
-include/virtualbox/nsprpub/prlog.h
-include/virtualbox/nsprpub/prlong.h
-include/virtualbox/nsprpub/prmem.h
-include/virtualbox/nsprpub/prmon.h
-include/virtualbox/nsprpub/prmwait.h
-include/virtualbox/nsprpub/prnetdb.h
-include/virtualbox/nsprpub/prolock.h
-include/virtualbox/nsprpub/prpdce.h
-include/virtualbox/nsprpub/prprf.h
-include/virtualbox/nsprpub/prproces.h
-include/virtualbox/nsprpub/prrng.h
-include/virtualbox/nsprpub/prrwlock.h
-include/virtualbox/nsprpub/prshm.h
-include/virtualbox/nsprpub/prshma.h
-include/virtualbox/nsprpub/prsystem.h
-include/virtualbox/nsprpub/prthread.h
-include/virtualbox/nsprpub/prtime.h
-include/virtualbox/nsprpub/prtpool.h
-include/virtualbox/nsprpub/prtrace.h
-include/virtualbox/nsprpub/prtypes.h
-include/virtualbox/nsprpub/prvrsion.h
-include/virtualbox/nsprpub/prwin16.h
-include/virtualbox/nsprpub/prcpucfg.h
-include/virtualbox/nsprpub/obsolete/pralarm.h
-include/virtualbox/nsprpub/obsolete/probslet.h
-include/virtualbox/nsprpub/obsolete/protypes.h
-include/virtualbox/nsprpub/obsolete/prsem.h
-include/virtualbox/nsprpub/private/pprio.h
-include/virtualbox/nsprpub/private/pprthred.h
-include/virtualbox/nsprpub/private/prpriv.h
-include/virtualbox/nsrootidl.h
-include/virtualbox/string/nsAString.h
-include/virtualbox/string/nsAlgorithm.h
-include/virtualbox/string/nsCharTraits.h
-include/virtualbox/string/nsDependentString.h
-include/virtualbox/string/nsDependentSubstring.h
-include/virtualbox/string/nsEmbedString.h
-include/virtualbox/string/nsLiteralString.h
-include/virtualbox/string/nsObsoleteAString.h
-include/virtualbox/string/nsPrintfCString.h
-include/virtualbox/string/nsPromiseFlatString.h
-include/virtualbox/string/nsReadableUtils.h
-include/virtualbox/string/nsString.h
-include/virtualbox/string/nsStringAPI.h
-include/virtualbox/string/nsStringFwd.h
-include/virtualbox/string/nsStringIterator.h
-include/virtualbox/string/nsSubstring.h
-include/virtualbox/string/nsSubstringTuple.h
-include/virtualbox/string/nsTAString.h
-include/virtualbox/string/nsTString.h
-include/virtualbox/string/nsTDependentString.h
-include/virtualbox/string/nsTDependentSubstring.h
-include/virtualbox/string/nsTObsoleteAString.h
-include/virtualbox/string/nsTPromiseFlatString.h
-include/virtualbox/string/nsTSubstring.h
-include/virtualbox/string/nsTSubstringTuple.h
-include/virtualbox/string/nsUTF8Utils.h
-include/virtualbox/string/nsXPIDLString.h
-include/virtualbox/string/string-template-def-char.h
-include/virtualbox/string/string-template-def-unichar.h
-include/virtualbox/string/string-template-undef.h
-include/virtualbox/xpcom/nsAgg.h
-include/virtualbox/xpcom/nsAppDirectoryServiceDefs.h
-include/virtualbox/xpcom/nsArray.h
-include/virtualbox/xpcom/nsArrayEnumerator.h
-include/virtualbox/xpcom/nsAtomService.h
-include/virtualbox/xpcom/nsAutoBuffer.h
-include/virtualbox/xpcom/nsAutoLock.h
-include/virtualbox/xpcom/nsAutoPtr.h
-include/virtualbox/xpcom/nsBaseHashtable.h
-include/virtualbox/xpcom/nsCOMArray.h
-include/virtualbox/xpcom/nsCRT.h
-include/virtualbox/xpcom/nsCategoryManagerUtils.h
-include/virtualbox/xpcom/nsCheapSets.h
-include/virtualbox/xpcom/nsClassHashtable.h
-include/virtualbox/xpcom/nsCom.h
-include/virtualbox/xpcom/nsComponentManagerObsolete.h
-include/virtualbox/xpcom/nsComponentManagerUtils.h
-include/virtualbox/xpcom/nsCppSharedAllocator.h
-include/virtualbox/xpcom/nsID.h
-include/virtualbox/xpcom/nsDataHashtable.h
-include/virtualbox/xpcom/nsDebugImpl.h
-include/virtualbox/xpcom/nsDeque.h
-include/virtualbox/xpcom/nsDirectoryService.h
-include/virtualbox/xpcom/nsDirectoryServiceDefs.h
-include/virtualbox/xpcom/nsDirectoryServiceUtils.h
-include/virtualbox/xpcom/nsDoubleHashtable.h
-include/virtualbox/xpcom/nsEnumeratorUtils.h
-include/virtualbox/xpcom/nsError.h
-include/virtualbox/xpcom/nsEscape.h
-include/virtualbox/xpcom/nsEventQueueUtils.h
-include/virtualbox/xpcom/nsFastLoadPtr.h
-include/virtualbox/xpcom/nsFastLoadService.h
-include/virtualbox/xpcom/nsFixedSizeAllocator.h
-include/virtualbox/xpcom/nsHashKeys.h
-include/virtualbox/xpcom/nsHashSets.h
-include/virtualbox/xpcom/nsHashtable.h
-include/virtualbox/xpcom/nsIAllocator.h
-include/virtualbox/xpcom/nsIByteBuffer.h
-include/virtualbox/xpcom/nsIID.h
-include/virtualbox/xpcom/nsIServiceManagerObsolete.h
-include/virtualbox/xpcom/nsIServiceManagerUtils.h
-include/virtualbox/xpcom/nsISupportsBase.h
-include/virtualbox/xpcom/nsISupportsObsolete.h
-include/virtualbox/xpcom/nsIUnicharBuffer.h
-include/virtualbox/xpcom/nsIUnicharInputStream.h
-include/virtualbox/xpcom/nsInt64.h
-include/virtualbox/xpcom/nsInterfaceHashtable.h
-include/virtualbox/xpcom/nsLinebreakConverter.h
-include/virtualbox/xpcom/nsLocalFile.h
-include/virtualbox/xpcom/nsLocalFileUnix.h
-include/virtualbox/xpcom/nsLocalFileOS2.h
-include/virtualbox/xpcom/nsLocalFileOSX.h
-include/virtualbox/xpcom/nsModule.h
-include/virtualbox/xpcom/nsMultiplexInputStream.h
-include/virtualbox/xpcom/nsNativeCharsetUtils.h
-include/virtualbox/xpcom/nsProcess.h
-include/virtualbox/xpcom/nsNativeComponentLoader.h
-include/virtualbox/xpcom/nsObserverService.h
-include/virtualbox/xpcom/nsObsoleteModuleLoading.h
-include/virtualbox/xpcom/nsProxiedService.h
-include/virtualbox/xpcom/nsProxyEvent.h
-include/virtualbox/xpcom/nsProxyRelease.h
-include/virtualbox/xpcom/nsQuickSort.h
-include/virtualbox/xpcom/nsRecyclingAllocator.h
-include/virtualbox/xpcom/nsRefPtrHashtable.h
-include/virtualbox/xpcom/nsScriptableInputStream.h
-include/virtualbox/xpcom/nsStaticAtom.h
-include/virtualbox/xpcom/nsStaticComponent.h
-include/virtualbox/xpcom/nsStaticNameTable.h
-include/virtualbox/xpcom/nsStorageStream.h
-include/virtualbox/xpcom/nsStreamUtils.h
-include/virtualbox/xpcom/nsStringEnumerator.h
-include/virtualbox/xpcom/nsStringIO.h
-include/virtualbox/xpcom/nsTHashtable.h
-include/virtualbox/xpcom/nsStringStream.h
-include/virtualbox/xpcom/nsSupportsArray.h
-include/virtualbox/xpcom/nsSupportsPrimitives.h
-include/virtualbox/xpcom/nsTextFormatter.h
-include/virtualbox/xpcom/nsTime.h
-include/virtualbox/xpcom/nsTraceRefcntImpl.h
-include/virtualbox/xpcom/nsUnitConversion.h
-include/virtualbox/xpcom/nsValueArray.h
-include/virtualbox/xpcom/nsVariant.h
-include/virtualbox/xpcom/nsVoidArray.h
-include/virtualbox/xpcom/nsWeakPtr.h
-include/virtualbox/xpcom/nsXPCOM.h
-include/virtualbox/xpcom/nsXPCOMCID.h
-include/virtualbox/xpcom/nscore.h
-include/virtualbox/xpcom/pldhash.h
-include/virtualbox/xpcom/plevent.h
-include/virtualbox/xpcom/xcDll.h
-include/virtualbox/xpcom/xpt_arena.h
-include/virtualbox/xpcom/xpt_struct.h
-include/virtualbox/xpcom/xpt_xdr.h
-include/virtualbox/xpcom/xptcall.h
-include/virtualbox/xpcom/xptcstubsdecl.inc
-include/virtualbox/xpcom/xptcstubsdef.inc
-include/virtualbox/xpcom/xptinfo.h
-include/virtualbox/xpcom/nsIInterfaceRequestorUtils.h
-include/virtualbox/xpcom/nsISupportsImpl.h
-include/virtualbox/xpcom/nsISupportsUtils.h
-include/virtualbox/xpcom/nsIWeakReferenceUtils.h
-include/virtualbox/xpcom/nsCOMPtr.h
-include/virtualbox/xpcom/nsDebug.h
-include/virtualbox/xpcom/nsGenericFactory.h
-include/virtualbox/xpcom/nsIGenericFactory.h
-include/virtualbox/xpcom/nsMemory.h
-include/virtualbox/xpcom/nsTraceRefcnt.h
-include/virtualbox/xpcom/nsWeakReference.h
-include/virtualbox/xpcom/nsXPCOMGlue.h
-include/virtualbox/xpcom/xpcom-config.h
-%%PYTHON_SITELIBDIR%%/vboxapi/__init__.py
-%%PYTHON_SITELIBDIR%%/vboxapi/__init__.pyc
-%%PYTHON_SITELIBDIR%%/vboxapi/VirtualBox_constants.py
-%%PYTHON_SITELIBDIR%%/vboxapi/VirtualBox_constants.pyc
-%%PYTHON_SITELIBDIR%%/vboxapi-1.0-py%%PYTHON_VER%%.egg-info
-%%PYTHON_SITELIBDIR%%/xpcom/__init__.py
-%%PYTHON_SITELIBDIR%%/xpcom/__init__.pyc
-%%PYTHON_SITELIBDIR%%/xpcom/components.py
-%%PYTHON_SITELIBDIR%%/xpcom/components.pyc
-%%PYTHON_SITELIBDIR%%/xpcom/file.py
-%%PYTHON_SITELIBDIR%%/xpcom/file.pyc
-%%PYTHON_SITELIBDIR%%/xpcom/nsError.py
-%%PYTHON_SITELIBDIR%%/xpcom/nsError.pyc
-%%PYTHON_SITELIBDIR%%/xpcom/primitives.py
-%%PYTHON_SITELIBDIR%%/xpcom/primitives.pyc
-%%PYTHON_SITELIBDIR%%/xpcom/vboxxpcom.py
-%%PYTHON_SITELIBDIR%%/xpcom/vboxxpcom.pyc
-%%PYTHON_SITELIBDIR%%/xpcom/xpcom_consts.py
-%%PYTHON_SITELIBDIR%%/xpcom/xpcom_consts.pyc
-%%PYTHON_SITELIBDIR%%/xpcom/xpt.py
-%%PYTHON_SITELIBDIR%%/xpcom/xpt.pyc
-%%PYTHON_SITELIBDIR%%/xpcom/client/__init__.py
-%%PYTHON_SITELIBDIR%%/xpcom/client/__init__.pyc
-%%PYTHON_SITELIBDIR%%/xpcom/server/__init__.py
-%%PYTHON_SITELIBDIR%%/xpcom/server/__init__.pyc
-%%PYTHON_SITELIBDIR%%/xpcom/server/enumerator.py
-%%PYTHON_SITELIBDIR%%/xpcom/server/enumerator.pyc
-%%PYTHON_SITELIBDIR%%/xpcom/server/factory.py
-%%PYTHON_SITELIBDIR%%/xpcom/server/factory.pyc
-%%PYTHON_SITELIBDIR%%/xpcom/server/loader.py
-%%PYTHON_SITELIBDIR%%/xpcom/server/loader.pyc
-%%PYTHON_SITELIBDIR%%/xpcom/server/module.py
-%%PYTHON_SITELIBDIR%%/xpcom/server/module.pyc
-%%PYTHON_SITELIBDIR%%/xpcom/server/policy.py
-%%PYTHON_SITELIBDIR%%/xpcom/server/policy.pyc
-@dirrm %%PYTHON_SITELIBDIR%%/xpcom/server
-@dirrm %%PYTHON_SITELIBDIR%%/xpcom/client
-@dirrm %%PYTHON_SITELIBDIR%%/xpcom
-@dirrm %%PYTHON_SITELIBDIR%%/vboxapi
-@dirrm include/virtualbox/xpcom
-@dirrm include/virtualbox/string
-@dirrm include/virtualbox/nsprpub/private
-@dirrm include/virtualbox/nsprpub/obsolete
-@dirrm include/virtualbox/nsprpub/md
-@dirrm include/virtualbox/nsprpub
-@dirrm include/virtualbox/ipcd
-@dirrm include/virtualbox
-%%NLS%%@dirrm %%DATADIR%%/nls
-@dirrm %%DATADIR%%/samples
-@dirrm %%DATADIR%%/idl
-@dirrm %%DATADIR%%
-%%QT4%%@dirrmtry share/icons/hicolor/48x48/apps
-%%QT4%%@dirrmtry share/icons/hicolor/48x48
-%%QT4%%@dirrmtry share/icons/hicolor
-%%QT4%%@dirrmtry share/icons
-%%QT4%%@dirrmtry share/applications
-@dirrm lib/virtualbox/components
-%%GUESTADDITIONS%%@dirrm lib/virtualbox/additions
-@dirrm lib/virtualbox
+@comment $FreeBSD$
@cwd /
%%KMODDIR%%/vboxdrv.ko
%%KMODDIR%%/vboxnetadp.ko
diff --git a/emulators/virtualbox-ose-kmod/Makefile b/emulators/virtualbox-ose-kmod/Makefile
index 46617a1b64b8..a0da9cfeac2c 100644
--- a/emulators/virtualbox-ose-kmod/Makefile
+++ b/emulators/virtualbox-ose-kmod/Makefile
@@ -1,186 +1,83 @@
-# New ports collection makefile for: virtualbox
-# Date created: 2009-05-02
+# New ports collection makefile for: virtualbox-ose-kmod
+# Date created: 2009-09-21
# Whom: Bernhard Froehlich <decke@bluelife.at>
#
# $FreeBSD$
#
-PORTNAME= virtualbox
-DISTVERSION= 3.0.51r22902
-PORTREVISION= 3
+PORTNAME= virtualbox-ose
+DISTVERSION= 3.1.2
CATEGORIES= emulators kld
MASTER_SITES= http://tmp.chruetertee.ch/ \
http://freebsd.unixfreunde.de/sources/ \
http://disasterarea.chruetertee.ch/ \
- http://mirror.4bit.ws/ \
- http://dlc.sun.com/virtualbox/${VBOX_GUEST_VER}/:guestadditions
-DISTFILES= ${DISTNAME}${EXTRACT_SUFX} ${GADISTFILES}
-EXTRACT_ONLY= ${DISTNAME}${EXTRACT_SUFX}
+ http://mirror.4bit.ws/
+PKGNAMESUFFIX= -kmod
+DISTNAME= VirtualBox-${DISTVERSION}-OSE
-#for discussion please use emulation@FreeBSD.org
MAINTAINER= vbox@FreeBSD.org
-COMMENT= A general-purpose full virtualizer for x86 hardware
+COMMENT= VirtualBox kernel module for FreeBSD
BUILD_DEPENDS= yasm:${PORTSDIR}/devel/yasm \
as86:${PORTSDIR}/devel/dev86 \
- xsltproc:${PORTSDIR}/textproc/libxslt \
kmk:${PORTSDIR}/devel/kBuild
-LIB_DEPENDS= png.5:${PORTSDIR}/graphics/png \
- xslt.2:${PORTSDIR}/textproc/libxslt \
- curl.5:${PORTSDIR}/ftp/curl
+WRKSRC= ${WRKDIR}/VirtualBox-${PORTVERSION}_OSE
+USE_RC_SUBR= vboxnet
ONLY_FOR_ARCHS= i386 amd64
-USE_GNOME= libidl
-USE_CDRTOOLS= yes
USE_BZIP2= yes
-USE_PYTHON= yes
-USE_PYDISTUTILS= easy_install
-PYDISTUTILS_PKGNAME= vboxapi
-PYDISTUTILS_PKGVERSION= 1.0
-PYDISTUTILS_NOEGGINFO= yes
HAS_CONFIGURE= yes
-CONFIGURE_ARGS+=--with-gcc="${CC}" --with-g++="${CXX}"
-USE_LDCONFIG= ${PREFIX}/lib/virtualbox
+CONFIGURE_ARGS+=--with-gcc="${CC}" --with-g++="${CXX}" --nofatal \
+ --disable-xpcom --disable-sdl-ttf --disable-pulse \
+ --disable-alsa --disable-dbus --disable-python \
+ --build-headless
CONFLICTS= bcc-[0-9]*
-VBOXGROUP?= vboxusers
-VBOXGID?= 920
-VBOX_FRONTENDS= VBoxHeadless
-VBOX_GUEST_VER= 3.0.6
-
-SUB_FILES= pkg-install
-
-SUB_LIST= PREFIX=${PREFIX} \
- VBOXGROUP=${VBOXGROUP} \
- VBOXGID=${VBOXGID}
-
-OPTIONS= QT4 "Build with QT4 Frontend" on \
- DEBUG "Build with debugging symbols" off \
- GUESTADDITIONS "Build with Guest Additions" off \
- DBUS "Build with D-Bus and HAL support" on \
- PULSEAUDIO "Build with PulseAudio" off \
- X11 "Build with X11 support" on \
- NLS "Native language support" on
+OPTIONS= DEBUG "Build with debugging symbols" off
.include <bsd.port.options.mk>
-PLIST_SUB+= KMODDIR=${KMODDIR:C,^/,,} \
- PYTHON_VER=${PYTHON_VER} \
- PYTHON_VERU=${PYTHON_VER:S/./_/} \
- GUEST_VER=${VBOX_GUEST_VER}
+PLIST_SUB+= KMODDIR=${KMODDIR:C,^/,,}
KMODDIR= /boot/modules
-KMK_BUILDTYPE= release
-KMK_CONFIG= VBOX_LIBPATH_X11=${LOCALBASE} VBOX_FREEBSD_SRC=${SRC_BASE}/sys
-KMK_FLAGS=
-
-.if defined(WITHOUT_QT4) && !defined(WITHOUT_NLS)
-BROKEN= NLS support requires QT4 frontend. Run 'make config' again!
-.endif
-.if defined(WITHOUT_X11) && !defined(WITHOUT_QT4)
-BROKEN= QT4 frontend requires X11 support. Run 'make config' again!
-.endif
-
-.if !defined(WITHOUT_X11)
-USE_SDL= sdl
-USE_XORG= xcursor xmu
-VBOX_FRONTENDS+=VBoxBFE VBoxSDL VBoxTestOGL
-PLIST_SUB+= X11=""
-.else
-CONFIGURE_ARGS+=--build-headless
-PLIST_SUB+= X11="@comment "
-.endif
-
-.if !defined(WITHOUT_QT4)
-USE_QT_VER= 4
-QT_NONSTANDARD= yes
-QT_COMPONENTS= gui network moc_build uic_build rcc_build linguist
-INSTALLS_ICONS= yes
-VBOX_FRONTENDS+=VirtualBox
-PLIST_SUB+= QT4=""
-.else
-CONFIGURE_ARGS+=--disable-qt4
-PLIST_SUB+= QT4="@comment "
-.endif
+VBOX_BIN= ${WRKSRC}/out/${KMK_ARCH}/${KMK_BUILDTYPE}/bin/src
-.if defined(WITH_GUESTADDITIONS)
-GUESTADDITIONS= VBoxGuestAdditions_${VBOX_GUEST_VER}.iso
-GADISTFILES= ${GUESTADDITIONS}:guestadditions
-RESTRICTED= for personal use only
-RESTRICTED_FILES= ${GUESTADDITIONS}
-FETCH_ARGS= -pRr
-PLIST_SUB+= GUESTADDITIONS=""
-.else
-PLIST_SUB+= GUESTADDITIONS="@comment "
-.endif
+KMK_BUILDTYPE= release
+KMK_CONFIG= VBOX_LIBPATH_X11=${LOCALBASE} VBOX_FREEBSD_SRC=${SRC_BASE}/sys
+KMK_FLAGS= HostDrivers-src vboxdrv-mod VBoxNetFlt-src VBoxNetAdp-src
.if defined(WITH_DEBUG)
KMK_FLAGS+= BUILD_TYPE=debug
KMK_BUILDTYPE= debug
.endif
-.if !defined(WITHOUT_DBUS)
-LIB_DEPENDS+= dbus-1.3:${PORTSDIR}/devel/dbus
-.else
-CONFIGURE_ARGS+=--disable-dbus
-.endif
-
-.if !defined(WITH_PULSEAUDIO)
-CONFIGURE_ARGS+=--disable-pulse
-.endif
-
-.if !defined(WITHOUT_NLS)
-PLIST_SUB+= NLS=""
-.else
-PLIST_SUB+= NLS="@comment "
-.endif
-
-.if !exists(${SRC_BASE}/sys/kern/bus_if.m)
-IGNORE= requires kernel sources for the kernel module
-.endif
-
.if ${OSVERSION} < 700000
BROKEN= Does not compile on FreeBSD 6.X
.endif
.if ${ARCH} == i386
KMK_ARCH= freebsd.x86
-PLIST_SUB+= I386=""
.else
KMK_ARCH= freebsd.${ARCH}
-PLIST_SUB+= I386="@comment "
.endif
-.include <bsd.port.pre.mk>
-
-pre-everything::
-.if ${ARCH} == "amd64"
-.if !exists(/usr/lib32)
- @${ECHO} 'Requires 32-bit libraries installed under /usr/lib32.'
- @${ECHO} 'Do: cd /usr/src; make build32 install32; ldconfig -v -m -R /usr/lib32'
- @${FALSE}
-.endif
+.if !exists(${SRC_BASE}/sys/kern/bus_if.m)
+IGNORE= requires kernel sources
.endif
+.include <bsd.port.pre.mk>
+
post-patch:
- @${ECHO} 'VBOX_PATH_APP_PRIVATE_ARCH = ${PREFIX}/lib/virtualbox' > ${WRKSRC}/LocalConfig.kmk
- @${ECHO} 'VBOX_PATH_SHARED_LIBS = ${PREFIX}/lib/virtualbox' >> ${WRKSRC}/LocalConfig.kmk
- @${ECHO} 'VBOX_WITH_RUNPATH = ${PREFIX}/lib/virtualbox' >> ${WRKSRC}/LocalConfig.kmk
- @${ECHO} 'VBOX_PATH_APP_PRIVATE = ${DATADIR}' >> ${WRKSRC}/LocalConfig.kmk
- @${ECHO} 'VBOX_PATH_APP_DOCS = ${DOCSDIR}' >> ${WRKSRC}/LocalConfig.kmk
- @${ECHO} 'VBOX_WITH_INSTALLER = 1' >> ${WRKSRC}/LocalConfig.kmk
- @${ECHO} 'VBOX_WITH_TESTCASES=' >> ${WRKSRC}/LocalConfig.kmk
-.if defined(WITHOUT_X11)
- @${ECHO} 'VBOX_WITH_X11_ADDITIONS=' >> ${WRKSRC}/LocalConfig.kmk
-.endif
+ @${ECHO} 'VBOX_WITH_VBOXDRV = 1' > ${WRKSRC}/LocalConfig.kmk
+ @${ECHO} 'VBOX_WITH_NETFLT = 1' >> ${WRKSRC}/LocalConfig.kmk
+ @${ECHO} 'VBOX_WITH_NETADP = 1' >> ${WRKSRC}/LocalConfig.kmk
+ @${ECHO} 'VBOX_WITH_ADDITIONS =' >> ${WRKSRC}/LocalConfig.kmk
@${REINPLACE_CMD} -e 's|/usr/local|${LOCALBASE}|g' \
- ${WRKSRC}/Config.kmk ${WRKSRC}/configure \
- ${WRKSRC}/kBuild/units/qt3.kmk ${WRKSRC}/kBuild/units/qt4.kmk \
- ${WRKSRC}/kBuild/sdks/LIBSDL.kmk \
- ${WRKSRC}/src/libs/xpcom18a4/python/gen_python_deps.py
+ ${WRKSRC}/Config.kmk \
+ ${WRKSRC}/configure
@${REINPLACE_CMD} -e 's|\$$KBUILDDIR_BIN/kmk_sed|${PREFIX}/bin/kmk_sed|g' ${WRKSRC}/configure
pre-build:
@@ -188,72 +85,13 @@ pre-build:
${WRKSRC}/env.sh
do-build:
- cd ${WRKSRC} && ${SH} env.sh && ${KMK_CONFIG} ${LOCALBASE}/bin/kmk ${KMK_FLAGS}
+ cd ${WRKSRC} && ${SH} env.sh && cd ${WRKSRC}/src/VBox/HostDrivers && ${KMK_CONFIG} ${LOCALBASE}/bin/kmk ${KMK_FLAGS}
+ cd ${VBOX_BIN} && make
do-install:
${MKDIR} ${KMODDIR}
-.for f in vboxdrv.ko vboxnetadp.ko vboxnetflt.ko
- ${INSTALL_KLD} ${WRKSRC}/out/${KMK_ARCH}/${KMK_BUILDTYPE}/bin/${f} ${KMODDIR}
-.endfor
-
- ${MKDIR} ${DATADIR}
- (cd ${WRKSRC}/out/${KMK_ARCH}/${KMK_BUILDTYPE}/bin/sdk/bindings/xpcom && ${COPYTREE_SHARE} "idl samples" ${DATADIR})
-
- ${MKDIR} ${PREFIX}/include/virtualbox
- (cd ${WRKSRC}/out/${KMK_ARCH}/${KMK_BUILDTYPE}/bin/sdk/bindings/xpcom/include && ${COPYTREE_SHARE} "*" ${PREFIX}/include/virtualbox)
-
- ${MKDIR} ${PREFIX}/lib/virtualbox
- (cd ${WRKSRC}/out/${KMK_ARCH}/${KMK_BUILDTYPE}/bin && ${COPYTREE_SHARE} "*.so *.gc *.r0 components" ${PREFIX}/lib/virtualbox)
-
-.if !defined(WITHOUT_NLS)
- ${MKDIR} ${DATADIR}/nls
- (cd ${WRKSRC}/out/${KMK_ARCH}/${KMK_BUILDTYPE}/obj/VirtualBox/qtnls && ${COPYTREE_SHARE} "*.qm" ${DATADIR}/nls)
-.endif
-
- ${MKDIR} ${PREFIX}/bin
-.for f in VBoxManage VBoxNetAdpCtl VBoxNetDHCP VBoxSVC VBoxXPCOMIPCD ${VBOX_FRONTENDS}
- ${INSTALL_PROGRAM} ${WRKSRC}/out/${KMK_ARCH}/${KMK_BUILDTYPE}/bin/${f} ${PREFIX}/lib/virtualbox/
- ${LN} -sf ${PREFIX}/lib/virtualbox/${f} ${PREFIX}/bin/
-.endfor
-
-.for f in VBoxNetAdpCtl VBoxNetDHCP ${VBOX_FRONTENDS}
- ${CHMOD} 4511 ${PREFIX}/lib/virtualbox/${f}
-.endfor
-
-.for f in VBoxManage VBoxSVC VBoxXPCOMIPCD
- ${CHMOD} 0711 ${PREFIX}/lib/virtualbox/${f}
-.endfor
-
-.if defined(WITH_GUESTADDITIONS)
- ${MKDIR} ${PREFIX}/lib/virtualbox/additions
- ${INSTALL_DATA} ${DISTDIR}/${GUESTADDITIONS} ${PREFIX}/lib/virtualbox/additions/
- ${LN} -sf ${PREFIX}/lib/virtualbox/additions/${GUESTADDITIONS} ${PREFIX}/lib/virtualbox/additions/VBoxGuestAdditions.iso
-.endif
-
- cd ${WRKSRC}/out/${KMK_ARCH}/${KMK_BUILDTYPE}/bin/sdk/installer && \
- VBOX_INSTALL_PATH="${PREFIX}/lib/virtualbox" ${PYTHON_CMD} vboxapisetup.py install
-
- @${MKDIR} ${PYTHON_SITELIBDIR}
- (cd ${WRKSRC}/out/${KMK_ARCH}/${KMK_BUILDTYPE}/bin/sdk/bindings/xpcom/python && ${COPYTREE_SHARE} "*" ${PYTHON_SITELIBDIR})
- ${PYTHON_CMD} -mcompileall ${PYTHON_SITELIBDIR}/xpcom/
-
-post-install:
- @${SETENV} ${SH} ${PKGINSTALL} ${PKGNAME} POST-INSTALL
-
-.for f in VBoxManage VBoxNetDHCP VBoxSVC VBoxXPCOMIPCD ${VBOX_FRONTENDS}
- ${CHOWN} root:${VBOXGROUP} ${PREFIX}/lib/virtualbox/${f}
-.endfor
-
- @${FIND} ${DATADIR} -type d -print0 | ${XARGS} -0 ${CHMOD} 755
- @${FIND} ${PREFIX}/include/virtualbox -type d -print0 | ${XARGS} -0 ${CHMOD} 755
- @${FIND} ${PREFIX}/lib/virtualbox -type d -print0 | ${XARGS} -0 ${CHMOD} 755
-
-.if !defined(WITHOUT_QT4)
- ${MKDIR} ${PREFIX}/share/icons/hicolor/48x48/apps/
- ${INSTALL_DATA} ${WRKSRC}/src/VBox/Frontends/VirtualBox/images/OSE/VirtualBox_48px.png ${PREFIX}/share/icons/hicolor/48x48/apps/VBox.png
- ${MKDIR} ${PREFIX}/share/applications/
- ${INSTALL_DATA} ${WRKSRC}/src/VBox/Installer/solaris/virtualbox.desktop ${PREFIX}/share/applications/virtualbox.desktop
-.endif
- @${CAT} ${PKGMESSAGE}
+ ${INSTALL_KLD} ${VBOX_BIN}/vboxdrv/vboxdrv.ko ${KMODDIR}
+ ${INSTALL_KLD} ${VBOX_BIN}/vboxnetadp/vboxnetadp.ko ${KMODDIR}
+ ${INSTALL_KLD} ${VBOX_BIN}/vboxnetflt/vboxnetflt.ko ${KMODDIR}
.include <bsd.port.post.mk>
diff --git a/emulators/virtualbox-ose-kmod/distinfo b/emulators/virtualbox-ose-kmod/distinfo
index 492de57d1c4a..af7117996821 100644
--- a/emulators/virtualbox-ose-kmod/distinfo
+++ b/emulators/virtualbox-ose-kmod/distinfo
@@ -1,6 +1,3 @@
-MD5 (virtualbox-3.0.51r22902.tar.bz2) = c2fbfd0eca2d2c9e6ad5f029cf75def0
-SHA256 (virtualbox-3.0.51r22902.tar.bz2) = ccbc88276f9e1944005d1c2f3661ec6d7113b22801ecbbb72d422aa0ab2b0a2a
-SIZE (virtualbox-3.0.51r22902.tar.bz2) = 51742256
-MD5 (VBoxGuestAdditions_3.0.6.iso) = 8d033b4f66db1a3e5b914da1717e9c21
-SHA256 (VBoxGuestAdditions_3.0.6.iso) = d6a8b61ef1004637c8be3a70612bb0e101f552d7eb0a9a376ff1ad264baf6a3c
-SIZE (VBoxGuestAdditions_3.0.6.iso) = 32786432
+MD5 (VirtualBox-3.1.2-OSE.tar.bz2) = e7808f16114f5b1a65aa2df1aa33e1a7
+SHA256 (VirtualBox-3.1.2-OSE.tar.bz2) = 293f582e37eda29efdb53c6468481b446e1964592f5728656b74664f4d32f2b1
+SIZE (VirtualBox-3.1.2-OSE.tar.bz2) = 55553394
diff --git a/emulators/virtualbox-ose-kmod/files/patch-Config.kmk b/emulators/virtualbox-ose-kmod/files/patch-Config.kmk
deleted file mode 100644
index 2ce55eb8a12d..000000000000
--- a/emulators/virtualbox-ose-kmod/files/patch-Config.kmk
+++ /dev/null
@@ -1,10 +0,0 @@
---- Config.kmk.bak 2009-09-02 18:34:01.000000000 +0200
-+++ Config.kmk 2009-09-02 19:19:09.000000000 +0200
-@@ -781,6 +781,7 @@
- VBOX_WITH_VBOXBFE=
- VBOX_WITH_OGL=
- VBOX_WITH_KCHMVIEWER=
-+ VBOX_WITH_HGSMI=
- endif
-
- #
diff --git a/emulators/virtualbox-ose-kmod/files/patch-configure b/emulators/virtualbox-ose-kmod/files/patch-configure
deleted file mode 100644
index c6532c3db606..000000000000
--- a/emulators/virtualbox-ose-kmod/files/patch-configure
+++ /dev/null
@@ -1,20 +0,0 @@
---- configure.orgi 2009-05-31 13:43:50.000000000 +0200
-+++ configure 2009-05-31 13:45:47.000000000 +0200
-@@ -102,7 +102,7 @@
- XSLTPROC="xsltproc"
- GENISOIMAGE="genisoimage"
- MKISOFS="mkisofs"
--LIBCRYPTO="-lcrypto"
-+LIBCRYPTO="-lcrypto -lssl"
- LIBPTHREAD="-lpthread"
- LIBCAP="-lcap"
- GSOAP=""
-@@ -1698,7 +1698,7 @@
- cat $ODIR.tmp_src.cc >> $LOG
- echo "using the following command line:" >> $LOG
- echo "$CXX -O -Wall -o $ODIR.tmp_out $ODIR.tmp_src.cc -I$p/include/$d $p/$b/lib$d.so" >> $LOG
-- $CXX -O -Wall -o $ODIR.tmp_out $ODIR.tmp_src.cc -I$p/include/$d $p/$b/lib$d.so >> $LOG 2>&1
-+ $CXX -O -Wall -o $ODIR.tmp_out $ODIR.tmp_src.cc -I$p/include/$d $p/$b/lib$d.so -pthread >> $LOG 2>&1
- if [ $? -eq 0 ]; then
- found=1
- break
diff --git a/emulators/virtualbox-ose-kmod/files/patch-src-VBox-Devices-Makefile.kmk b/emulators/virtualbox-ose-kmod/files/patch-src-VBox-Devices-Makefile.kmk
deleted file mode 100644
index d404c8aee176..000000000000
--- a/emulators/virtualbox-ose-kmod/files/patch-src-VBox-Devices-Makefile.kmk
+++ /dev/null
@@ -1,15 +0,0 @@
---- src/VBox/Devices/Makefile.kmk.orig 2009-11-01 22:50:39.000000000 +0100
-+++ src/VBox/Devices/Makefile.kmk 2009-11-01 22:50:52.000000000 +0100
-@@ -31,8 +31,10 @@
- include $(PATH_SUB_CURRENT)/PC/VMI/Makefile.kmk
- endif
- include $(PATH_SUB_CURRENT)/Graphics/BIOS/Makefile.kmk
--include $(PATH_SUB_CURRENT)/testcase/Makefile.kmk
--include $(PATH_SUB_CURRENT)/Storage/testcase/Makefile.kmk
-+ifdef VBOX_WITH_TESTCASES
-+ include $(PATH_SUB_CURRENT)/testcase/Makefile.kmk
-+ include $(PATH_SUB_CURRENT)/Storage/testcase/Makefile.kmk
-+endif
- ifndef VBOX_OSE
- include $(PATH_SUB_CURRENT)/Storage/VBoxHDDFormats/Makefile.kmk
- endif
diff --git a/emulators/virtualbox-ose-kmod/files/patch-src-VBox-Frontends-VBoxManage-VBoxInternalManage.cpp b/emulators/virtualbox-ose-kmod/files/patch-src-VBox-Frontends-VBoxManage-VBoxInternalManage.cpp
deleted file mode 100644
index 0a1f735fb79a..000000000000
--- a/emulators/virtualbox-ose-kmod/files/patch-src-VBox-Frontends-VBoxManage-VBoxInternalManage.cpp
+++ /dev/null
@@ -1,50 +0,0 @@
-Index: src/VBox/Frontends/VBoxManage/VBoxInternalManage.cpp
-@@ -54,7 +54,8 @@
- #ifdef RT_OS_WINDOWS
- # include <windows.h>
- # include <winioctl.h>
--#elif defined(RT_OS_LINUX) || defined(RT_OS_DARWIN) || defined(RT_OS_SOLARIS)
-+#elif defined(RT_OS_LINUX) || defined(RT_OS_DARWIN) \
-+ || defined(RT_OS_SOLARIS) || defined(RT_OS_FREEBSD)
- # include <errno.h>
- # include <sys/ioctl.h>
- # include <sys/types.h>
-@@ -76,6 +77,9 @@
- # include <sys/dkio.h>
- # include <sys/vtoc.h>
- #endif /* RT_OS_SOLARIS */
-+#ifdef RT_OS_FREEBSD
-+# include <sys/disk.h>
-+#endif /* RT_OS_FREEBSD */
-
- using namespace com;
-
-@@ -1013,6 +1017,28 @@
- vrc = VERR_INVALID_PARAMETER;
- goto out;
- }
-+#elif defined(RT_OS_FREEBSD)
-+ struct stat DevStat;
-+ if (!fstat(RawFile, &DevStat) && S_ISCHR(DevStat.st_mode))
-+ {
-+ off_t cMediasize = 0;
-+ if (!ioctl(RawFile, DIOCGMEDIASIZE, &cMediasize))
-+ {
-+ cbSize = cMediasize;
-+ }
-+ else
-+ {
-+ vrc = RTErrConvertFromErrno(errno);
-+ RTPrintf("Cannot get the block count for file '%s': %Rrc", rawdisk.raw(), vrc);
-+ goto out;
-+ }
-+ }
-+ else
-+ {
-+ RTPrintf("File '%s' is no character device\n", rawdisk.raw());
-+ vrc = VERR_INVALID_PARAMETER;
-+ goto out;
-+ }
- #else /* all unrecognized OSes */
- /* Hopefully this works on all other hosts. If it doesn't, it'll just fail
- * creating the VMDK, so no real harm done. */
diff --git a/emulators/virtualbox-ose-kmod/files/patch-src-VBox-HostDrivers-VBoxNetFlt-VBoxNetFltInternal.h b/emulators/virtualbox-ose-kmod/files/patch-src-VBox-HostDrivers-VBoxNetFlt-VBoxNetFltInternal.h
deleted file mode 100644
index 250a1960a7f4..000000000000
--- a/emulators/virtualbox-ose-kmod/files/patch-src-VBox-HostDrivers-VBoxNetFlt-VBoxNetFltInternal.h
+++ /dev/null
@@ -1,28 +0,0 @@
-Index: src/VBox/HostDrivers/VBoxNetFlt/VBoxNetFltInternal.h
-===================================================================
---- src/VBox/HostDrivers/VBoxNetFlt/VBoxNetFltInternal.h (revision 23391)
-+++ src/VBox/HostDrivers/VBoxNetFlt/VBoxNetFltInternal.h (working copy)
-@@ -206,6 +206,14 @@
- hook_p output;
- /** Original interface flags */
- unsigned int flags;
-+ /** Input queue */
-+ struct ifqueue inq;
-+ /** Output queue */
-+ struct ifqueue outq;
-+ /** Input task */
-+ struct task tskin;
-+ /** Output task */
-+ struct task tskout;
- /** The MAC address of the interface. */
- RTMAC Mac;
- /** @} */
-@@ -241,6 +249,8 @@
- # endif
- #elif defined(RT_OS_LINUX)
- uint8_t abPadding[320];
-+#elif defined(RT_OS_FREEBSD)
-+ uint8_t abPadding[320];
- #else
- uint8_t abPadding[128];
- #endif
diff --git a/emulators/virtualbox-ose-kmod/files/patch-src-VBox-HostDrivers-VBoxNetFlt-freebsd-VBoxNetFlt-freebsd.c b/emulators/virtualbox-ose-kmod/files/patch-src-VBox-HostDrivers-VBoxNetFlt-freebsd-VBoxNetFlt-freebsd.c
index f23fedbf0ec0..ac0ba0eee28c 100644
--- a/emulators/virtualbox-ose-kmod/files/patch-src-VBox-HostDrivers-VBoxNetFlt-freebsd-VBoxNetFlt-freebsd.c
+++ b/emulators/virtualbox-ose-kmod/files/patch-src-VBox-HostDrivers-VBoxNetFlt-freebsd-VBoxNetFlt-freebsd.c
@@ -2,35 +2,6 @@ Index: src/VBox/HostDrivers/VBoxNetFlt/freebsd/VBoxNetFlt-freebsd.c
===================================================================
--- src/VBox/HostDrivers/VBoxNetFlt/freebsd/VBoxNetFlt-freebsd.c (revision 23391)
+++ src/VBox/HostDrivers/VBoxNetFlt/freebsd/VBoxNetFlt-freebsd.c (working copy)
-@@ -43,6 +43,8 @@
- #include <sys/socket.h>
- #include <sys/sockio.h>
- #include <sys/syscallsubr.h>
-+#include <sys/queue.h>
-+#include <sys/taskqueue.h>
-
- #include <net/if.h>
- #include <net/if_var.h>
-@@ -78,8 +80,6 @@
- static ng_rcvdata_t ng_vboxnetflt_rcvdata;
- static ng_disconnect_t ng_vboxnetflt_disconnect;
- static int ng_vboxnetflt_mod_event(module_t mod, int event, void *data);
--static int ng_vboxnetflt_rcv_in(hook_p node, item_p item);
--static int ng_vboxnetflt_rcv_out(hook_p node, item_p item);
-
- /** Netgraph node type */
- #define NG_VBOXNETFLT_NODE_TYPE "vboxnetflt"
-@@ -112,8 +112,8 @@
- {
- .version = NG_ABI_VERSION,
- .name = NG_VBOXNETFLT_NODE_TYPE,
-- .mod_event = vboxnetflt_modevent,
-- .constructor = ng_vboxnetflt_constructor,
-+ .mod_event = vboxnetflt_modevent,
-+ .constructor = ng_vboxnetflt_constructor,
- .rcvmsg = ng_vboxnetflt_rcvmsg,
- .shutdown = ng_vboxnetflt_shutdown,
- .newhook = ng_vboxnetflt_newhook,
@@ -122,7 +122,7 @@
.cmdlist = ng_vboxnetflt_cmdlist,
};
@@ -40,345 +11,12 @@ Index: src/VBox/HostDrivers/VBoxNetFlt/freebsd/VBoxNetFlt-freebsd.c
MODULE_DEPEND(ng_vboxnetflt, vboxdrv, 1, 1, 1);
/**
-@@ -267,16 +267,12 @@
- if (strcmp(name, NG_VBOXNETFLT_HOOK_IN) == 0)
- {
- #if __FreeBSD_version >= 800000
-- NG_HOOK_SET_RCVDATA(hook, ng_vboxnetflt_rcv_in);
- NG_HOOK_SET_TO_INBOUND(hook);
- #endif
- pThis->u.s.input = hook;
- }
- else if (strcmp(name, NG_VBOXNETFLT_HOOK_OUT) == 0)
- {
--#if __FreeBSD_version >= 800000
-- NG_HOOK_SET_RCVDATA(hook, ng_vboxnetflt_rcv_out);
--#endif
- pThis->u.s.output = hook;
- }
- else
-@@ -310,161 +306,171 @@
-
- /**
- * Handle data on netgraph hooks.
-+ * Frames processing is deferred to a taskqueue because this might
-+ * be called with non-sleepable locks held and code paths inside
-+ * the virtual switch might sleep.
- */
- static int ng_vboxnetflt_rcvdata(hook_p hook, item_p item)
- {
- const node_p node = NG_HOOK_NODE(hook);
- PVBOXNETFLTINS pThis = NG_NODE_PRIVATE(node);
-+ struct ifnet *ifp = pThis->u.s.ifp;
- struct mbuf *m;
-+ struct m_tag *mtag;
-+ bool fActive;
-
-+ fActive = ASMAtomicUoReadBool(&pThis->fActive);
-+
-+ NGI_GET_M(item, m);
-+ NG_FREE_ITEM(item);
-+
-+ /* Locate tag to see if processing should be skipped for this frame */
-+ mtag = m_tag_locate(m, MTAG_VBOX, PACKET_TAG_VBOX, NULL);
-+ if (mtag != NULL)
-+ {
-+ m_tag_unlink(m, mtag);
-+ m_tag_free(mtag);
-+ }
-+
-+ /*
-+ * Handle incoming hook. This is connected to the
-+ * input path of the interface, thus handling incoming frames.
-+ */
- if (pThis->u.s.input == hook)
-- return ng_vboxnetflt_rcv_in(hook, item);
-+ {
-+ if (mtag != NULL || !fActive)
-+ {
-+ ether_demux(ifp, m);
-+ return (0);
-+ }
-+ mtx_lock_spin(&pThis->u.s.inq.ifq_mtx);
-+ _IF_ENQUEUE(&pThis->u.s.inq, m);
-+ mtx_unlock_spin(&pThis->u.s.inq.ifq_mtx);
-+ taskqueue_enqueue_fast(taskqueue_fast, &pThis->u.s.tskin);
-+ }
-+ /**
-+ * Handle mbufs on the outgoing hook, frames going to the interface
-+ */
- else if (pThis->u.s.output == hook)
-- return ng_vboxnetflt_rcv_out(hook, item);
-+ {
-+ if (mtag != NULL || !fActive)
-+ return ether_output_frame(ifp, m);
-+ mtx_lock_spin(&pThis->u.s.outq.ifq_mtx);
-+ _IF_ENQUEUE(&pThis->u.s.outq, m);
-+ mtx_unlock_spin(&pThis->u.s.outq.ifq_mtx);
-+ taskqueue_enqueue_fast(taskqueue_fast, &pThis->u.s.tskout);
-+ }
- else
- {
-- NGI_GET_M(item, m);
-- NG_FREE_ITEM(item);
-+ m_freem(m);
- }
- return (0);
- }
-
-+static int ng_vboxnetflt_shutdown(node_p node)
-+{
-+ PVBOXNETFLTINS pThis = NG_NODE_PRIVATE(node);
-+ bool fActive;
-+
-+ /* Prevent node shutdown if we're active */
-+ fActive = ASMAtomicUoReadBool(&pThis->fActive);
-+ if (fActive)
-+ return (EBUSY);
-+ NG_NODE_UNREF(node);
-+ return (0);
-+}
-+
-+static int ng_vboxnetflt_disconnect(hook_p hook)
-+{
-+ return (0);
-+}
-+
- /**
-- * Handle incoming hook. This is connected to the
-- * input path of the interface, thus handling incoming frames.
-+ * Input processing task, handles incoming frames
- */
--static int ng_vboxnetflt_rcv_in(hook_p hook, item_p item)
-+static void vboxNetFltFreeBSDinput(void *arg, int pending)
- {
-+ PVBOXNETFLTINS pThis = (PVBOXNETFLTINS)arg;
- struct mbuf *m, *m0;
-- struct m_tag *mtag;
-- const node_p node = NG_HOOK_NODE(hook);
-- PVBOXNETFLTINS pThis = NG_NODE_PRIVATE(node);
- struct ifnet *ifp = pThis->u.s.ifp;
-- bool fActive, fDropIt = false;
- unsigned int cSegs = 0;
-+ bool fDropIt = false, fActive;
- PINTNETSG pSG;
-
-- NGI_GET_M(item, m);
-- NG_FREE_ITEM(item);
--
-- fActive = ASMAtomicUoReadBool(&pThis->fActive);
-- if (!fActive)
-- goto out;
--
-- mtag = m_tag_locate(m, MTAG_VBOX, PACKET_TAG_VBOX, NULL);
-- if (mtag != NULL)
-- {
-- m_tag_unlink(m, mtag);
-- m_tag_free(mtag);
-- goto out;
-- }
- vboxNetFltRetain(pThis, true /* fBusy */);
--
-- for (m0 = m; m0 != NULL; m0 = m0->m_next)
-+ for (;;)
- {
-- if (m0->m_len > 0)
-- cSegs++;
-- }
-+ mtx_lock_spin(&pThis->u.s.inq.ifq_mtx);
-+ _IF_DEQUEUE(&pThis->u.s.inq, m);
-+ mtx_unlock_spin(&pThis->u.s.inq.ifq_mtx);
-+ if (m == NULL)
-+ break;
-
-+ for (m0 = m; m0 != NULL; m0 = m0->m_next)
-+ if (m0->m_len > 0)
-+ cSegs++;
-+
- #ifdef PADD_RUNT_FRAMES_FROM_HOST
-- if (m_length(m, NULL) < 60)
-- cSegs++;
-+ if (m_length(m, NULL) < 60)
-+ cSegs++;
- #endif
-
-- /* Create a copy of the mbuf and hand it to the virtual switch */
-- pSG = RTMemTmpAlloc(RT_OFFSETOF(INTNETSG, aSegs[cSegs]));
-- vboxNetFltFreeBSDMBufToSG(pThis, m, pSG, cSegs, 0);
-- fDropIt = pThis->pSwitchPort->pfnRecv(pThis->pSwitchPort, pSG, INTNETTRUNKDIR_WIRE);
-- RTMemTmpFree(pSG);
-+ /* Create a copy and deliver to the virtual switch */
-+ pSG = RTMemTmpAlloc(RT_OFFSETOF(INTNETSG, aSegs[cSegs]));
-+ vboxNetFltFreeBSDMBufToSG(pThis, m, pSG, cSegs, 0);
-+ fDropIt = pThis->pSwitchPort->pfnRecv(pThis->pSwitchPort, pSG, INTNETTRUNKDIR_HOST);
-+ RTMemTmpFree(pSG);
-+ if (fDropIt)
-+ m_freem(m);
-+ else
-+ ether_demux(ifp, m);
-+ }
- vboxNetFltRelease(pThis, true /* fBusy */);
--
--out:
-- /* Only deliver it to the host stack if the destination weren't a guest */
-- if (fDropIt)
-- {
-- m_freem(m);
-- return (0);
-- }
-- ether_demux(ifp, m);
-- return (0);
- }
-
- /**
-- * Handle mbufs on the outgoing hook, frames going to the interface
-+ * Output processing task, handles outgoing frames
- */
--static int ng_vboxnetflt_rcv_out(hook_p hook, item_p item)
-+static void vboxNetFltFreeBSDoutput(void *arg, int pending)
- {
-+ PVBOXNETFLTINS pThis = (PVBOXNETFLTINS)arg;
- struct mbuf *m, *m0;
-- struct m_tag *mtag;
-- const node_p node = NG_HOOK_NODE(hook);
-- PVBOXNETFLTINS pThis = NG_NODE_PRIVATE(node);
- struct ifnet *ifp = pThis->u.s.ifp;
- unsigned int cSegs = 0;
- bool fDropIt = false, fActive;
- PINTNETSG pSG;
-
-- NGI_GET_M(item, m);
-- NG_FREE_ITEM(item);
--
-- fActive = ASMAtomicUoReadBool(&pThis->fActive);
-- if (!fActive)
-- return ether_output_frame(ifp, m);
--
- vboxNetFltRetain(pThis, true /* fBusy */);
-- /* Pass directly to interface if the packet originated from us */
-- mtag = m_tag_locate(m, MTAG_VBOX, PACKET_TAG_VBOX, NULL);
-- if (mtag != NULL)
-+ for (;;)
- {
-- m_tag_unlink(m, mtag);
-- m_tag_free(mtag);
-- goto out;
-- }
-+ mtx_lock_spin(&pThis->u.s.outq.ifq_mtx);
-+ _IF_DEQUEUE(&pThis->u.s.outq, m);
-+ mtx_unlock_spin(&pThis->u.s.outq.ifq_mtx);
-+ if (m == NULL)
-+ break;
-
-- for (m0 = m; m0 != NULL; m0 = m0->m_next)
-- {
-- if (m0->m_len > 0)
-- cSegs++;
-- }
-+ for (m0 = m; m0 != NULL; m0 = m0->m_next)
-+ if (m0->m_len > 0)
-+ cSegs++;
-
- #ifdef PADD_RUNT_FRAMES_FROM_HOST
-- if (m_length(m, NULL) < 60)
-- cSegs++;
-+ if (m_length(m, NULL) < 60)
-+ cSegs++;
- #endif
-- /* Create a copy and deliver to the virtual switch */
-- pSG = RTMemTmpAlloc(RT_OFFSETOF(INTNETSG, aSegs[cSegs]));
-- vboxNetFltFreeBSDMBufToSG(pThis, m, pSG, cSegs, 0);
-- fDropIt = pThis->pSwitchPort->pfnRecv(pThis->pSwitchPort, pSG, INTNETTRUNKDIR_HOST);
-- RTMemTmpFree(pSG);
-+ /* Create a copy and deliver to the virtual switch */
-+ pSG = RTMemTmpAlloc(RT_OFFSETOF(INTNETSG, aSegs[cSegs]));
-+ vboxNetFltFreeBSDMBufToSG(pThis, m, pSG, cSegs, 0);
-+ fDropIt = pThis->pSwitchPort->pfnRecv(pThis->pSwitchPort, pSG, INTNETTRUNKDIR_HOST);
-+ RTMemTmpFree(pSG);
-
--out:
-+ if (fDropIt)
-+ m_freem(m);
-+ else
-+ ether_output_frame(ifp, m);
-+ }
- vboxNetFltRelease(pThis, true /* fBusy */);
-- if (fDropIt)
-- {
-- m_freem(m);
-- return (0);
-- }
--
-- return ether_output_frame(ifp, m);
- }
-
--static int ng_vboxnetflt_shutdown(node_p node)
--{
-- PVBOXNETFLTINS pThis = NG_NODE_PRIVATE(node);
-- bool fActive;
--
-- /* Prevent node shutdown if we're active */
-- fActive = ASMAtomicUoReadBool(&pThis->fActive);
-- if (fActive)
-- return (EBUSY);
-- NG_NODE_UNREF(node);
-- return (0);
--}
--
--static int ng_vboxnetflt_disconnect(hook_p hook)
--{
-- return (0);
--}
--
- /**
- * Called to deliver a frame to either the host, the wire or both.
- */
-@@ -536,13 +542,23 @@
-
- /* Create a new netgraph node for this instance */
- if (ng_make_node_common(&ng_vboxnetflt_typestruct, &node) != 0)
-- return VERR_INTERNAL_ERROR;
-+ return VERR_INTERNAL_ERROR;
-
- RTSpinlockAcquire(pThis->hSpinlock, &Tmp);
- ASMAtomicUoWritePtr((void * volatile *)&pThis->u.s.ifp, ifp);
- pThis->u.s.node = node;
- bcopy(IF_LLADDR(ifp), &pThis->u.s.Mac, ETHER_ADDR_LEN);
- ASMAtomicUoWriteBool(&pThis->fDisconnectedFromHost, false);
-+ /* Initialize deferred input queue */
-+ bzero(&pThis->u.s.inq, sizeof(struct ifqueue));
-+ mtx_init(&pThis->u.s.inq.ifq_mtx, "vboxnetflt inq", NULL, MTX_SPIN);
-+ TASK_INIT(&pThis->u.s.tskin, 0, vboxNetFltFreeBSDinput, pThis);
-+
-+ /* Initialize deferred output queue */
-+ bzero(&pThis->u.s.outq, sizeof(struct ifqueue));
-+ mtx_init(&pThis->u.s.outq.ifq_mtx, "vboxnetflt outq", NULL, MTX_SPIN);
-+ TASK_INIT(&pThis->u.s.tskout, 0, vboxNetFltFreeBSDoutput, pThis);
-+
- RTSpinlockRelease(pThis->hSpinlock, &Tmp);
-
- NG_NODE_SET_PRIVATE(node, pThis);
-@@ -571,7 +587,10 @@
- }
-
- if (ifp0 != NULL)
-+ {
-+ vboxNetFltOsDeleteInstance(pThis);
- vboxNetFltOsInitInstance(pThis, NULL);
-+ }
-
- return !ASMAtomicUoReadBool(&pThis->fDisconnectedFromHost);
- }
-@@ -579,6 +598,12 @@
- void vboxNetFltOsDeleteInstance(PVBOXNETFLTINS pThis)
- {
-
-+ taskqueue_drain(taskqueue_fast, &pThis->u.s.tskin);
-+ taskqueue_drain(taskqueue_fast, &pThis->u.s.tskout);
-+
-+ mtx_destroy(&pThis->u.s.inq.ifq_mtx);
-+ mtx_destroy(&pThis->u.s.outq.ifq_mtx);
-+
- if (pThis->u.s.node != NULL)
- ng_rmnode_self(pThis->u.s.node);
- pThis->u.s.node = NULL;
+@@ -418,7 +418,7 @@
+ /* Create a copy and deliver to the virtual switch */
+ pSG = RTMemTmpAlloc(RT_OFFSETOF(INTNETSG, aSegs[cSegs]));
+ vboxNetFltFreeBSDMBufToSG(pThis, m, pSG, cSegs, 0);
+- fDropIt = pThis->pSwitchPort->pfnRecv(pThis->pSwitchPort, pSG, INTNETTRUNKDIR_HOST);
++ fDropIt = pThis->pSwitchPort->pfnRecv(pThis->pSwitchPort, pSG, INTNETTRUNKDIR_WIRE);
+ RTMemTmpFree(pSG);
+ if (fDropIt)
+ m_freem(m);
diff --git a/emulators/virtualbox-ose-kmod/files/patch-src-VBox-Runtime-r0drv-freebsd-the-freebsd-kernel.h b/emulators/virtualbox-ose-kmod/files/patch-src-VBox-Runtime-r0drv-freebsd-the-freebsd-kernel.h
deleted file mode 100644
index 4332049487c3..000000000000
--- a/emulators/virtualbox-ose-kmod/files/patch-src-VBox-Runtime-r0drv-freebsd-the-freebsd-kernel.h
+++ /dev/null
@@ -1,11 +0,0 @@
---- src/VBox/Runtime/r0drv/freebsd/the-freebsd-kernel.h.orig 2009-09-11 14:48:47.000000000 +0200
-+++ src/VBox/Runtime/r0drv/freebsd/the-freebsd-kernel.h 2009-09-11 14:48:54.000000000 +0200
-@@ -76,7 +76,7 @@
- # define SLEEPQ_TIMEDWAIT_SIG(EventInt) sleepq_timedwait_sig(EventInt, 0)
- # define SLEEPQ_WAIT(EventInt) sleepq_wait(EventInt, 0)
- # define SLEEPQ_WAIT_SIG(EventInt) sleepq_wait_sig(EventInt, 0)
--#elif
-+#else
- # define SLEEPQ_TIMEDWAIT(EventInt) sleepq_timedwait(EventInt)
- # define SLEEPQ_TIMEDWAIT_SIG(EventInt) sleepq_timedwait_sig(EventInt)
- # define SLEEPQ_WAIT(EventInt) sleepq_wait(EventInt)
diff --git a/emulators/virtualbox-ose-kmod/files/patch-src-VBox-apps-adpctl_VBoxNetAdpCtl.cpp b/emulators/virtualbox-ose-kmod/files/patch-src-VBox-apps-adpctl_VBoxNetAdpCtl.cpp
deleted file mode 100644
index 955bf7a3a151..000000000000
--- a/emulators/virtualbox-ose-kmod/files/patch-src-VBox-apps-adpctl_VBoxNetAdpCtl.cpp
+++ /dev/null
@@ -1,207 +0,0 @@
---- src/apps/adpctl/VBoxNetAdpCtl.cpp.r22902 2009-04-10 14:03:59.000000000 +0200
-+++ src/apps/adpctl/VBoxNetAdpCtl.cpp 2009-09-16 14:07:11.000000000 +0200
-@@ -1,4 +1,4 @@
--/* $Id: VBoxNetAdpCtl.cpp 18864 2009-04-10 12:03:59Z vboxsync $ */
-+/* $Id: VBoxNetAdpCtl.cpp 23064 2009-09-16 12:07:11Z vboxsync $ */
- /** @file
- * Apps - VBoxAdpCtl, Configuration tool for vboxnetX adapters.
- */
-@@ -24,7 +24,6 @@
- /*******************************************************************************
- * Header Files *
- *******************************************************************************/
--#include <assert.h>
- #include <stdio.h>
- #include <stdlib.h>
- #include <string.h>
-@@ -36,11 +35,12 @@
- # include <sys/ioccom.h>
- #endif
-
--/* @todo Error codes must be moved to some header file */
--#define ADPCTLERR_NO_CTL_DEV 3
--#define ADPCTLERR_IOCTL_FAILED 4
-+/** @todo Error codes must be moved to some header file */
-+#define ADPCTLERR_BAD_NAME 2
-+#define ADPCTLERR_NO_CTL_DEV 3
-+#define ADPCTLERR_IOCTL_FAILED 4
-
--/* @todo These are duplicates from src/VBox/HostDrivers/VBoxNetAdp/VBoxNetAdpInternal.h */
-+/** @todo These are duplicates from src/VBox/HostDrivers/VBoxNetAdp/VBoxNetAdpInternal.h */
- #define VBOXNETADP_CTL_DEV_NAME "/dev/vboxnetctl"
- #define VBOXNETADP_NAME "vboxnet"
- #define VBOXNETADP_MAX_NAME_LEN 32
-@@ -85,6 +85,7 @@
- pcszArg5, /* [network mask] */
- NULL /* terminator */
- };
-+ char * const envp[] = { (char*)"LC_ALL=C", NULL };
- int rc = EXIT_SUCCESS;
- pid_t childPid = fork();
- switch (childPid)
-@@ -94,7 +95,7 @@
- rc = EXIT_FAILURE;
- break;
- case 0: /* Child process. */
-- if (execv(VBOXADPCTL_IFCONFIG_PATH, (char * const*)argv) == -1)
-+ if (execve(VBOXADPCTL_IFCONFIG_PATH, (char * const*)argv, envp) == -1)
- rc = EXIT_FAILURE;
- break;
- default: /* Parent process. */
-@@ -108,15 +109,39 @@
- #define MAX_ADDRESSES 128
- #define MAX_ADDRLEN 64
-
--static bool removeAddresses(const char *pszAdapterName)
-+static bool removeAddresses(char *pszAdapterName)
- {
-- char szCmd[1024], szBuf[1024];
-+ char szBuf[1024];
- char aszAddresses[MAX_ADDRESSES][MAX_ADDRLEN];
-+ int rc;
-+ int fds[2];
-+ char * const argv[] = { VBOXADPCTL_IFCONFIG_PATH, pszAdapterName, NULL };
-+ char * const envp[] = { (char*)"LC_ALL=C", NULL };
-
- memset(aszAddresses, 0, sizeof(aszAddresses));
-- snprintf(szCmd, sizeof(szCmd), VBOXADPCTL_IFCONFIG_PATH " %s", pszAdapterName);
-- FILE *fp = popen(szCmd, "r");
-
-+ rc = pipe(fds);
-+ if (rc < 0)
-+ return false;
-+
-+ pid_t pid = fork();
-+ if (pid < 0)
-+ return false;
-+
-+ if (pid == 0)
-+ {
-+ /* child */
-+ close(fds[0]);
-+ close(STDOUT_FILENO);
-+ rc = dup2(fds[1], STDOUT_FILENO);
-+ if (rc >= 0)
-+ execve(VBOXADPCTL_IFCONFIG_PATH, argv, envp);
-+ return false;
-+ }
-+
-+ /* parent */
-+ close(fds[1]);
-+ FILE *fp = fdopen(fds[0], "r");
- if (!fp)
- return false;
-
-@@ -124,9 +149,6 @@
- for (cAddrs = 0; cAddrs < MAX_ADDRESSES && fgets(szBuf, sizeof(szBuf), fp);)
- {
- int cbSkipWS = strspn(szBuf, " \t");
--#if 0 /* Don't use this! assert() breaks the mac build. Use IPRT or be a rectangular building thing. */
-- assert(cbSkipWS < 20);
--#endif
- char *pszWord = strtok(szBuf + cbSkipWS, " ");
- /* We are concerned with IPv6 address lines only. */
- if (!pszWord || strcmp(pszWord, "inet6"))
-@@ -143,11 +165,12 @@
- continue;
- strncpy(aszAddresses[cAddrs++], pszWord, MAX_ADDRLEN-1);
- }
-- pclose(fp);
-+ fclose(fp);
-
- for (int i = 0; i < cAddrs; i++)
- {
-- if (executeIfconfig(pszAdapterName, "inet6", VBOXADPCTL_DEL_CMD, aszAddresses[i]) != EXIT_SUCCESS)
-+ if (executeIfconfig(pszAdapterName, "inet6",
-+ VBOXADPCTL_DEL_CMD, aszAddresses[i]) != EXIT_SUCCESS)
- return false;
- }
-
-@@ -166,19 +189,41 @@
- int rc = ioctl(fd, uCmd, pData);
- if (rc == -1)
- {
-- perror("VBoxNetAdpCtl: ioctl failed for " VBOXNETADP_CTL_DEV_NAME);
-+ perror("VBoxNetAdpCtl: ioctl failed for " VBOXNETADP_CTL_DEV_NAME);
- rc = ADPCTLERR_IOCTL_FAILED;
- }
--
-+
- close(fd);
--
-+
- return rc;
- }
-
-+int checkAdapterName(const char *pcszNameIn, char *pszNameOut)
-+{
-+ int iAdapterIndex = -1;
-+
-+ if ( strlen(pcszNameIn) >= VBOXNETADP_MAX_NAME_LEN
-+ || sscanf(pcszNameIn, "vboxnet%d", &iAdapterIndex) != 1
-+ || iAdapterIndex < 0 || iAdapterIndex > 99 )
-+ {
-+ fprintf(stderr, "Setting configuration for %s is not supported.\n", pcszNameIn);
-+ return ADPCTLERR_BAD_NAME;
-+ }
-+ sprintf(pszNameOut, "vboxnet%d", iAdapterIndex);
-+ if (strcmp(pszNameOut, pcszNameIn))
-+ {
-+ fprintf(stderr, "Invalid adapter name %s.\n", pcszNameIn);
-+ return ADPCTLERR_BAD_NAME;
-+ }
-+
-+ return 0;
-+}
-+
- int main(int argc, char *argv[])
-
- {
-- const char *pszAdapterName;
-+ char szAdapterName[VBOXNETADP_MAX_NAME_LEN];
-+ char *pszAdapterName;
- const char *pszAddress;
- const char *pszNetworkMask = NULL;
- const char *pszOption = NULL;
-@@ -216,13 +261,18 @@
- pszAddress = argv[2];
- if (strcmp("remove", pszAddress) == 0)
- {
-- strncpy(Req.szName, pszAdapterName, sizeof(Req.szName));
-+ rc = checkAdapterName(pszAdapterName, szAdapterName);
-+ if (rc)
-+ return rc;
-+ memset(&Req, '\0', sizeof(Req));
-+ snprintf(Req.szName, sizeof(Req.szName), "%s", szAdapterName);
- return doIOCtl(VBOXNETADP_CTL_REMOVE, &Req);
- }
- break;
- case 2:
- if (strcmp("add", argv[1]) == 0)
- {
-+ memset(&Req, '\0', sizeof(Req));
- rc = doIOCtl(VBOXNETADP_CTL_ADD, &Req);
- if (rc == 0)
- puts(Req.szName);
-@@ -237,11 +287,11 @@
- return 1;
- }
-
-- if (strncmp("vboxnet", pszAdapterName, 7))
-- {
-- fprintf(stderr, "Setting configuration for %s is not supported.\n", pszAdapterName);
-- return 2;
-- }
-+ rc = checkAdapterName(pszAdapterName, szAdapterName);
-+ if (rc)
-+ return rc;
-+
-+ pszAdapterName = szAdapterName;
-
- if (fRemove)
- {
-@@ -276,3 +326,4 @@
- }
- return rc;
- }
-+
diff --git a/emulators/virtualbox-ose-kmod/files/pkg-install.in b/emulators/virtualbox-ose-kmod/files/pkg-install.in
deleted file mode 100644
index 5d5268d8e8ce..000000000000
--- a/emulators/virtualbox-ose-kmod/files/pkg-install.in
+++ /dev/null
@@ -1,22 +0,0 @@
-#!/bin/sh
-
-case $2 in
-POST-INSTALL)
- GROUP=%%VBOXGROUP%%
- GID=%%VBOXGID%%
- PW=/usr/sbin/pw
-
- if ${PW} group show "${GROUP}" 2>/dev/null; then
- echo "You already have a group \"${GROUP}\", so I will use it."
- else
- if ${PW} groupadd ${GROUP} -g ${GID}; then
- echo "Added group \"${GROUP}\"."
- else
- echo "Adding group \"${GROUP}\" failed..."
- exit 1
- fi
- fi
-
- exit 0
- ;;
-esac
diff --git a/emulators/virtualbox-ose-kmod/files/vboxnet.in b/emulators/virtualbox-ose-kmod/files/vboxnet.in
new file mode 100644
index 000000000000..69cb0e402521
--- /dev/null
+++ b/emulators/virtualbox-ose-kmod/files/vboxnet.in
@@ -0,0 +1,71 @@
+#!/bin/sh
+#
+# $FreeBSD$
+#
+
+# PROVIDE: vboxnet
+# REQUIRE: FILESYSTEMS
+# BEFORE: netif
+# KEYWORD: nojail
+
+#
+# Add the following lines to /etc/rc.conf.local or /etc/rc.conf
+# to enable this service:
+#
+# vboxnet_enable (bool): Set to NO by default.
+# Set it to YES to load network related kernel modules on startup
+
+. %%RC_SUBR%%
+
+name="vboxnet"
+rcvar=${name}_enable
+start_cmd="vboxnet_start"
+stop_cmd="vboxnet_stop"
+
+vboxnet_start()
+{
+ if ! kldstat -q -m ng_vboxnetflt;
+ then
+ if ! kldload vboxnetflt > /dev/null 2>&1;
+ then
+ warn "Can't load vboxnetflt module."
+ return 1
+ fi
+ fi
+
+ if ! kldstat -q -m vboxnetadp;
+ then
+ if ! kldload vboxnetadp > /dev/null 2>&1;
+ then
+ warn "Can't load vboxnetadp module."
+ return 1
+ fi
+ fi
+}
+
+vboxnet_stop()
+{
+ if kldstat -q -m vboxnetadp;
+ then
+ if ! kldunload vboxnetadp > /dev/null 2>&1;
+ then
+ warn "Can't unload vboxnetadp module."
+ return 1
+ fi
+ fi
+
+ if kldstat -q -m ng_vboxnetflt;
+ then
+ if ! kldunload vboxnetflt > /dev/null 2>&1;
+ then
+ warn "Can't unload vboxnetflt module."
+ return 1
+ fi
+ fi
+}
+
+load_rc_config $name
+
+: ${vboxnet_enable="NO"}
+
+run_rc_command "$1"
diff --git a/emulators/virtualbox-ose-kmod/pkg-message b/emulators/virtualbox-ose-kmod/pkg-message
deleted file mode 100644
index 91b8b16427cd..000000000000
--- a/emulators/virtualbox-ose-kmod/pkg-message
+++ /dev/null
@@ -1,26 +0,0 @@
-=============================================================================
-
-VirtualBox was installed.
-
-You need to load the vboxdrv kernel module and a mounted /proc filesystem.
-
-% mount -t procfs proc /proc
-% kldload vboxdrv
-
-For bridged networking you also need to load the vboxnetflt kernel module.
-
-% kldload vboxnetflt
-
-You also have to add all users to your vboxusers group in order to use vbox.
-
-% pw groupmod vboxusers -m jerry
-
-Running VirtualBox as non-root user may fail with a fatal error
-NS_ERROR_FACTORY_NOT_REGISTERED. In this case delete /tmp/.vbox-*-ipc file.
-
-Check wiki page for known issues and troubleshooting:
-http://wiki.freebsd.org/VirtualBox
-
-Please report any problems to emulation@. Thanks!
-
-=============================================================================
diff --git a/emulators/virtualbox-ose-kmod/pkg-plist b/emulators/virtualbox-ose-kmod/pkg-plist
index f8ade22c00a7..f4567ba3fc9a 100644
--- a/emulators/virtualbox-ose-kmod/pkg-plist
+++ b/emulators/virtualbox-ose-kmod/pkg-plist
@@ -1,598 +1,4 @@
-%%X11%%bin/VBoxBFE
-bin/VBoxHeadless
-bin/VBoxManage
-bin/VBoxNetAdpCtl
-bin/VBoxNetDHCP
-%%X11%%bin/VBoxSDL
-bin/VBoxSVC
-%%X11%%bin/VBoxTestOGL
-bin/VBoxXPCOMIPCD
-%%QT4%%bin/VirtualBox
-%%X11%%lib/virtualbox/VBoxBFE
-%%X11%%lib/virtualbox/VBoxBFE.so
-lib/virtualbox/VBoxDD.so
-lib/virtualbox/VBoxDD2.so
-lib/virtualbox/VBoxDDU.so
-lib/virtualbox/VBoxGuestPropSvc.so
-lib/virtualbox/VBoxHeadless
-lib/virtualbox/VBoxHeadless.so
-%%QT4%%lib/virtualbox/VBoxKeyboard.so
-lib/virtualbox/VBoxManage
-lib/virtualbox/VBoxNetAdpCtl
-lib/virtualbox/VBoxNetDHCP
-lib/virtualbox/VBoxNetDHCP.so
-%%X11%%lib/virtualbox/VBoxOGLhostcrutil.so
-%%X11%%lib/virtualbox/VBoxOGLhosterrorspu.so
-%%X11%%lib/virtualbox/VBoxOGLrenderspu.so
-lib/virtualbox/VBoxPython.so
-lib/virtualbox/VBoxREM.so
-%%X11%%lib/virtualbox/VBoxTestOGL
-%%I386%%lib/virtualbox/VBoxREM32.so
-%%I386%%lib/virtualbox/VBoxREM64.so
-lib/virtualbox/VBoxRT.so
-%%X11%%lib/virtualbox/VBoxSDL
-%%X11%%lib/virtualbox/VBoxSDL.so
-lib/virtualbox/VBoxSVC
-lib/virtualbox/VBoxSharedClipboard.so
-%%X11%%lib/virtualbox/VBoxSharedCrOpenGL.so
-lib/virtualbox/VBoxSharedFolders.so
-lib/virtualbox/VBoxVMM.so
-lib/virtualbox/VBoxXPCOM.so
-lib/virtualbox/VBoxXPCOMC.so
-lib/virtualbox/VBoxXPCOMIPCD
-%%QT4%%lib/virtualbox/VirtualBox
-%%QT4%%lib/virtualbox/VirtualBox.so
-lib/virtualbox/VBoxDD2GC.gc
-lib/virtualbox/VBoxDDGC.gc
-lib/virtualbox/VMMGC.gc
-lib/virtualbox/VBoxDD2R0.r0
-lib/virtualbox/VBoxDDR0.r0
-%%GUESTADDITIONS%%lib/virtualbox/additions/VBoxGuestAdditions.iso
-%%GUESTADDITIONS%%lib/virtualbox/additions/VBoxGuestAdditions_%%GUEST_VER%%.iso
-lib/virtualbox/VBoxPython%%PYTHON_VERU%%.so
-lib/virtualbox/VMMR0.r0
-lib/virtualbox/components/VirtualBox_XPCOM.xpt
-lib/virtualbox/components/VBoxXPCOMIPCC.so
-lib/virtualbox/components/VBoxSVCM.so
-lib/virtualbox/components/VBoxC.so
-lib/virtualbox/components/VBoxXPCOMBase.xpt
-%%NLS%%%%DATADIR%%/nls/VirtualBox_ar.qm
-%%NLS%%%%DATADIR%%/nls/VirtualBox_bg.qm
-%%NLS%%%%DATADIR%%/nls/VirtualBox_ca.qm
-%%NLS%%%%DATADIR%%/nls/VirtualBox_cs.qm
-%%NLS%%%%DATADIR%%/nls/VirtualBox_de.qm
-%%NLS%%%%DATADIR%%/nls/VirtualBox_el.qm
-%%NLS%%%%DATADIR%%/nls/VirtualBox_es.qm
-%%NLS%%%%DATADIR%%/nls/VirtualBox_eu.qm
-%%NLS%%%%DATADIR%%/nls/VirtualBox_fi.qm
-%%NLS%%%%DATADIR%%/nls/VirtualBox_fr.qm
-%%NLS%%%%DATADIR%%/nls/VirtualBox_hu.qm
-%%NLS%%%%DATADIR%%/nls/VirtualBox_id.qm
-%%NLS%%%%DATADIR%%/nls/VirtualBox_it.qm
-%%NLS%%%%DATADIR%%/nls/VirtualBox_ja.qm
-%%NLS%%%%DATADIR%%/nls/VirtualBox_km_KH.qm
-%%NLS%%%%DATADIR%%/nls/VirtualBox_ko.qm
-%%NLS%%%%DATADIR%%/nls/VirtualBox_nl.qm
-%%NLS%%%%DATADIR%%/nls/VirtualBox_pl.qm
-%%NLS%%%%DATADIR%%/nls/VirtualBox_pt.qm
-%%NLS%%%%DATADIR%%/nls/VirtualBox_pt_BR.qm
-%%NLS%%%%DATADIR%%/nls/VirtualBox_ro.qm
-%%NLS%%%%DATADIR%%/nls/VirtualBox_ru.qm
-%%NLS%%%%DATADIR%%/nls/VirtualBox_sk.qm
-%%NLS%%%%DATADIR%%/nls/VirtualBox_sr.qm
-%%NLS%%%%DATADIR%%/nls/VirtualBox_sv.qm
-%%NLS%%%%DATADIR%%/nls/VirtualBox_tr.qm
-%%NLS%%%%DATADIR%%/nls/VirtualBox_uk.qm
-%%NLS%%%%DATADIR%%/nls/VirtualBox_zh_CN.qm
-%%NLS%%%%DATADIR%%/nls/VirtualBox_zh_TW.qm
-%%NLS%%%%DATADIR%%/nls/qt_ar.qm
-%%NLS%%%%DATADIR%%/nls/qt_bg.qm
-%%NLS%%%%DATADIR%%/nls/qt_ca.qm
-%%NLS%%%%DATADIR%%/nls/qt_cs.qm
-%%NLS%%%%DATADIR%%/nls/qt_de.qm
-%%NLS%%%%DATADIR%%/nls/qt_el.qm
-%%NLS%%%%DATADIR%%/nls/qt_es.qm
-%%NLS%%%%DATADIR%%/nls/qt_eu.qm
-%%NLS%%%%DATADIR%%/nls/qt_fi.qm
-%%NLS%%%%DATADIR%%/nls/qt_fr.qm
-%%NLS%%%%DATADIR%%/nls/qt_hu.qm
-%%NLS%%%%DATADIR%%/nls/qt_id.qm
-%%NLS%%%%DATADIR%%/nls/qt_it.qm
-%%NLS%%%%DATADIR%%/nls/qt_ja.qm
-%%NLS%%%%DATADIR%%/nls/qt_km_KH.qm
-%%NLS%%%%DATADIR%%/nls/qt_ko.qm
-%%NLS%%%%DATADIR%%/nls/qt_nl.qm
-%%NLS%%%%DATADIR%%/nls/qt_pl.qm
-%%NLS%%%%DATADIR%%/nls/qt_pt.qm
-%%NLS%%%%DATADIR%%/nls/qt_pt_BR.qm
-%%NLS%%%%DATADIR%%/nls/qt_ro.qm
-%%NLS%%%%DATADIR%%/nls/qt_ru.qm
-%%NLS%%%%DATADIR%%/nls/qt_sk.qm
-%%NLS%%%%DATADIR%%/nls/qt_sr.qm
-%%NLS%%%%DATADIR%%/nls/qt_sv.qm
-%%NLS%%%%DATADIR%%/nls/qt_tr.qm
-%%NLS%%%%DATADIR%%/nls/qt_uk.qm
-%%NLS%%%%DATADIR%%/nls/qt_zh_CN.qm
-%%NLS%%%%DATADIR%%/nls/qt_zh_TW.qm
-%%QT4%%share/applications/virtualbox.desktop
-%%QT4%%share/icons/hicolor/48x48/apps/VBox.png
-%%DATADIR%%/idl/nsIDebug.idl
-%%DATADIR%%/idl/nsIInterfaceRequestor.idl
-%%DATADIR%%/idl/nsIMemory.idl
-%%DATADIR%%/idl/nsIProgrammingLanguage.idl
-%%DATADIR%%/idl/nsISupports.idl
-%%DATADIR%%/idl/nsITraceRefcnt.idl
-%%DATADIR%%/idl/nsIWeakReference.idl
-%%DATADIR%%/idl/nsIConsoleMessage.idl
-%%DATADIR%%/idl/nsIConsoleService.idl
-%%DATADIR%%/idl/nsIConsoleListener.idl
-%%DATADIR%%/idl/nsIErrorService.idl
-%%DATADIR%%/idl/nsIException.idl
-%%DATADIR%%/idl/nsIExceptionService.idl
-%%DATADIR%%/idl/nsrootidl.idl
-%%DATADIR%%/idl/nsIClassInfo.idl
-%%DATADIR%%/idl/nsIFactory.idl
-%%DATADIR%%/idl/nsIModule.idl
-%%DATADIR%%/idl/nsIComponentRegistrar.idl
-%%DATADIR%%/idl/nsIServiceManager.idl
-%%DATADIR%%/idl/nsIComponentManager.idl
-%%DATADIR%%/idl/nsICategoryManager.idl
-%%DATADIR%%/idl/nsINativeComponentLoader.idl
-%%DATADIR%%/idl/nsIComponentLoader.idl
-%%DATADIR%%/idl/nsIComponentManagerObsolete.idl
-%%DATADIR%%/idl/nsISupportsArray.idl
-%%DATADIR%%/idl/nsIComponentLoaderManager.idl
-%%DATADIR%%/idl/nsICollection.idl
-%%DATADIR%%/idl/nsISerializable.idl
-%%DATADIR%%/idl/nsIEnumerator.idl
-%%DATADIR%%/idl/nsISimpleEnumerator.idl
-%%DATADIR%%/idl/nsIObserverService.idl
-%%DATADIR%%/idl/nsIObserver.idl
-%%DATADIR%%/idl/nsIAtom.idl
-%%DATADIR%%/idl/nsIAtomService.idl
-%%DATADIR%%/idl/nsIProperties.idl
-%%DATADIR%%/idl/nsIPersistentProperties2.idl
-%%DATADIR%%/idl/nsIRecyclingAllocator.idl
-%%DATADIR%%/idl/nsIStringEnumerator.idl
-%%DATADIR%%/idl/nsISupportsPrimitives.idl
-%%DATADIR%%/idl/nsISupportsIterators.idl
-%%DATADIR%%/idl/nsITimelineService.idl
-%%DATADIR%%/idl/nsIVariant.idl
-%%DATADIR%%/idl/nsIArray.idl
-%%DATADIR%%/idl/nsIPropertyBag.idl
-%%DATADIR%%/idl/nsIHashable.idl
-%%DATADIR%%/idl/nsIDirectoryService.idl
-%%DATADIR%%/idl/nsIDirectoryEnumerator.idl
-%%DATADIR%%/idl/nsIFile.idl
-%%DATADIR%%/idl/nsILocalFile.idl
-%%DATADIR%%/idl/nsIInputStream.idl
-%%DATADIR%%/idl/nsILocalFileMac.idl
-%%DATADIR%%/idl/nsIObjectInputStream.idl
-%%DATADIR%%/idl/nsIBinaryInputStream.idl
-%%DATADIR%%/idl/nsIObjectOutputStream.idl
-%%DATADIR%%/idl/nsIBinaryOutputStream.idl
-%%DATADIR%%/idl/nsIStreamBufferAccess.idl
-%%DATADIR%%/idl/nsIOutputStream.idl
-%%DATADIR%%/idl/nsIByteArrayInputStream.idl
-%%DATADIR%%/idl/nsIFastLoadFileControl.idl
-%%DATADIR%%/idl/nsISeekableStream.idl
-%%DATADIR%%/idl/nsIInputStreamTee.idl
-%%DATADIR%%/idl/nsIFastLoadService.idl
-%%DATADIR%%/idl/nsIMultiplexInputStream.idl
-%%DATADIR%%/idl/nsIPipe.idl
-%%DATADIR%%/idl/nsIAsyncInputStream.idl
-%%DATADIR%%/idl/nsIAsyncOutputStream.idl
-%%DATADIR%%/idl/nsIScriptableInputStream.idl
-%%DATADIR%%/idl/nsIStorageStream.idl
-%%DATADIR%%/idl/nsILineInputStream.idl
-%%DATADIR%%/idl/nsIStringStream.idl
-%%DATADIR%%/idl/nsIProxyObjectManager.idl
-%%DATADIR%%/idl/nsIEventQueue.idl
-%%DATADIR%%/idl/nsIEventQueueService.idl
-%%DATADIR%%/idl/nsIRunnable.idl
-%%DATADIR%%/idl/nsIThread.idl
-%%DATADIR%%/idl/nsIEventTarget.idl
-%%DATADIR%%/idl/nsIEnvironment.idl
-%%DATADIR%%/idl/nsITimer.idl
-%%DATADIR%%/idl/nsITimerInternal.idl
-%%DATADIR%%/idl/nsITimerManager.idl
-%%DATADIR%%/idl/nsIInterfaceInfo.idl
-%%DATADIR%%/idl/nsIProcess.idl
-%%DATADIR%%/idl/nsIXPTLoader.idl
-%%DATADIR%%/idl/nsIInterfaceInfoManager.idl
-%%DATADIR%%/idl/ipcIMessageObserver.idl
-%%DATADIR%%/idl/ipcIService.idl
-%%DATADIR%%/idl/ipcIClientObserver.idl
-%%DATADIR%%/idl/ipcILockService.idl
-%%DATADIR%%/idl/ipcIDConnectService.idl
-%%DATADIR%%/idl/ipcITransactionService.idl
-%%DATADIR%%/idl/ipcITransactionObserver.idl
-%%DATADIR%%/idl/VirtualBox_XPCOM.idl
-%%DATADIR%%/samples/tstVBoxAPILinux.cpp
-%%DATADIR%%/samples/Makefile
-include/virtualbox/VBoxCAPI_v2_2.h
-include/virtualbox/VBoxCAPI_v3_0.h
-include/virtualbox/VBoxCAPI_v3_1.h
-include/virtualbox/VirtualBox_XPCOM.h
-include/virtualbox/ipcIClientObserver.h
-include/virtualbox/ipcIDConnectService.h
-include/virtualbox/ipcILockService.h
-include/virtualbox/ipcIMessageObserver.h
-include/virtualbox/ipcIService.h
-include/virtualbox/ipcITransactionObserver.h
-include/virtualbox/ipcITransactionService.h
-include/virtualbox/ipcd/ipcCID.h
-include/virtualbox/ipcd/ipcLockCID.h
-include/virtualbox/ipcd/ipcMessageReader.h
-include/virtualbox/ipcd/ipcMessageWriter.h
-include/virtualbox/ipcd/ipcModule.h
-include/virtualbox/ipcd/ipcModuleUtil.h
-include/virtualbox/ipcd/ipcdclient.h
-include/virtualbox/nsIArray.h
-include/virtualbox/nsIAsyncInputStream.h
-include/virtualbox/nsIAsyncOutputStream.h
-include/virtualbox/nsIAtom.h
-include/virtualbox/nsIAtomService.h
-include/virtualbox/nsIBinaryInputStream.h
-include/virtualbox/nsIBinaryOutputStream.h
-include/virtualbox/nsIByteArrayInputStream.h
-include/virtualbox/nsICategoryManager.h
-include/virtualbox/nsIClassInfo.h
-include/virtualbox/nsICollection.h
-include/virtualbox/nsIComponentLoader.h
-include/virtualbox/nsIComponentLoaderManager.h
-include/virtualbox/nsIComponentManager.h
-include/virtualbox/nsIComponentManagerObsolete.h
-include/virtualbox/nsIComponentRegistrar.h
-include/virtualbox/nsIConsoleListener.h
-include/virtualbox/nsIConsoleMessage.h
-include/virtualbox/nsIConsoleService.h
-include/virtualbox/nsIDebug.h
-include/virtualbox/nsIDirectoryEnumerator.h
-include/virtualbox/nsIDirectoryService.h
-include/virtualbox/nsIEnumerator.h
-include/virtualbox/nsIEnvironment.h
-include/virtualbox/nsIErrorService.h
-include/virtualbox/nsIEventQueue.h
-include/virtualbox/nsIEventQueueService.h
-include/virtualbox/nsIEventTarget.h
-include/virtualbox/nsIException.h
-include/virtualbox/nsIExceptionService.h
-include/virtualbox/nsIFactory.h
-include/virtualbox/nsIFastLoadFileControl.h
-include/virtualbox/nsIFastLoadService.h
-include/virtualbox/nsIFile.h
-include/virtualbox/nsIHashable.h
-include/virtualbox/nsIInputStream.h
-include/virtualbox/nsIInputStreamTee.h
-include/virtualbox/nsIInterfaceInfo.h
-include/virtualbox/nsIInterfaceInfoManager.h
-include/virtualbox/nsIInterfaceRequestor.h
-include/virtualbox/nsILineInputStream.h
-include/virtualbox/nsILocalFile.h
-include/virtualbox/nsILocalFileMac.h
-include/virtualbox/nsIMemory.h
-include/virtualbox/nsIModule.h
-include/virtualbox/nsIMultiplexInputStream.h
-include/virtualbox/nsINativeComponentLoader.h
-include/virtualbox/nsIObjectInputStream.h
-include/virtualbox/nsIObjectOutputStream.h
-include/virtualbox/nsIObserver.h
-include/virtualbox/nsIObserverService.h
-include/virtualbox/nsIOutputStream.h
-include/virtualbox/nsIPersistentProperties2.h
-include/virtualbox/nsIPipe.h
-include/virtualbox/nsIProcess.h
-include/virtualbox/nsIProgrammingLanguage.h
-include/virtualbox/nsIProperties.h
-include/virtualbox/nsIPropertyBag.h
-include/virtualbox/nsIProxyObjectManager.h
-include/virtualbox/nsIRecyclingAllocator.h
-include/virtualbox/nsIRunnable.h
-include/virtualbox/nsIScriptableInputStream.h
-include/virtualbox/nsISeekableStream.h
-include/virtualbox/nsISerializable.h
-include/virtualbox/nsIServiceManager.h
-include/virtualbox/nsISimpleEnumerator.h
-include/virtualbox/nsIStorageStream.h
-include/virtualbox/nsIStreamBufferAccess.h
-include/virtualbox/nsIStringEnumerator.h
-include/virtualbox/nsIStringStream.h
-include/virtualbox/nsISupports.h
-include/virtualbox/nsISupportsArray.h
-include/virtualbox/nsISupportsIterators.h
-include/virtualbox/nsISupportsPrimitives.h
-include/virtualbox/nsIThread.h
-include/virtualbox/nsITimelineService.h
-include/virtualbox/nsITimer.h
-include/virtualbox/nsITimerInternal.h
-include/virtualbox/nsITimerManager.h
-include/virtualbox/nsITraceRefcnt.h
-include/virtualbox/nsIVariant.h
-include/virtualbox/nsIWeakReference.h
-include/virtualbox/nsIXPTLoader.h
-include/virtualbox/nsprpub/nspr.h
-include/virtualbox/nsprpub/plarena.h
-include/virtualbox/nsprpub/plarenas.h
-include/virtualbox/nsprpub/plbase64.h
-include/virtualbox/nsprpub/plerror.h
-include/virtualbox/nsprpub/plgetopt.h
-include/virtualbox/nsprpub/plhash.h
-include/virtualbox/nsprpub/plresolv.h
-include/virtualbox/nsprpub/plstr.h
-include/virtualbox/nsprpub/pratom.h
-include/virtualbox/nsprpub/prbit.h
-include/virtualbox/nsprpub/prclist.h
-include/virtualbox/nsprpub/prcmon.h
-include/virtualbox/nsprpub/prcountr.h
-include/virtualbox/nsprpub/prcvar.h
-include/virtualbox/nsprpub/prdtoa.h
-include/virtualbox/nsprpub/prenv.h
-include/virtualbox/nsprpub/prerr.h
-include/virtualbox/nsprpub/prerror.h
-include/virtualbox/nsprpub/prinet.h
-include/virtualbox/nsprpub/prinit.h
-include/virtualbox/nsprpub/prinrval.h
-include/virtualbox/nsprpub/prio.h
-include/virtualbox/nsprpub/pripcsem.h
-include/virtualbox/nsprpub/prlink.h
-include/virtualbox/nsprpub/md/_iprt_atomic.h
-include/virtualbox/nsprpub/md/_darwin.h
-include/virtualbox/nsprpub/md/_freebsd.h
-include/virtualbox/nsprpub/md/_l4v2.h
-include/virtualbox/nsprpub/md/_linux.h
-include/virtualbox/nsprpub/md/_macos.h
-include/virtualbox/nsprpub/md/_netbsd.h
-include/virtualbox/nsprpub/md/_openbsd.h
-include/virtualbox/nsprpub/md/_os2_errors.h
-include/virtualbox/nsprpub/md/_os2.h
-include/virtualbox/nsprpub/md/_pcos.h
-include/virtualbox/nsprpub/md/_solaris.h
-include/virtualbox/nsprpub/md/_unix_errors.h
-include/virtualbox/nsprpub/md/_unixos.h
-include/virtualbox/nsprpub/md/_pth.h
-include/virtualbox/nsprpub/md/prosdep.h
-include/virtualbox/nsprpub/md/_freebsd.cfg
-include/virtualbox/nsprpub/md/_linux.cfg
-include/virtualbox/nsprpub/md/_darwin.cfg
-include/virtualbox/nsprpub/md/_netbsd.cfg
-include/virtualbox/nsprpub/md/_openbsd.cfg
-include/virtualbox/nsprpub/md/_os2.cfg
-include/virtualbox/nsprpub/md/_solaris32.cfg
-include/virtualbox/nsprpub/md/_l4v2.cfg
-include/virtualbox/nsprpub/md/_solaris64.cfg
-include/virtualbox/nsprpub/prlock.h
-include/virtualbox/nsprpub/prlog.h
-include/virtualbox/nsprpub/prlong.h
-include/virtualbox/nsprpub/prmem.h
-include/virtualbox/nsprpub/prmon.h
-include/virtualbox/nsprpub/prmwait.h
-include/virtualbox/nsprpub/prnetdb.h
-include/virtualbox/nsprpub/prolock.h
-include/virtualbox/nsprpub/prpdce.h
-include/virtualbox/nsprpub/prprf.h
-include/virtualbox/nsprpub/prproces.h
-include/virtualbox/nsprpub/prrng.h
-include/virtualbox/nsprpub/prrwlock.h
-include/virtualbox/nsprpub/prshm.h
-include/virtualbox/nsprpub/prshma.h
-include/virtualbox/nsprpub/prsystem.h
-include/virtualbox/nsprpub/prthread.h
-include/virtualbox/nsprpub/prtime.h
-include/virtualbox/nsprpub/prtpool.h
-include/virtualbox/nsprpub/prtrace.h
-include/virtualbox/nsprpub/prtypes.h
-include/virtualbox/nsprpub/prvrsion.h
-include/virtualbox/nsprpub/prwin16.h
-include/virtualbox/nsprpub/prcpucfg.h
-include/virtualbox/nsprpub/obsolete/pralarm.h
-include/virtualbox/nsprpub/obsolete/probslet.h
-include/virtualbox/nsprpub/obsolete/protypes.h
-include/virtualbox/nsprpub/obsolete/prsem.h
-include/virtualbox/nsprpub/private/pprio.h
-include/virtualbox/nsprpub/private/pprthred.h
-include/virtualbox/nsprpub/private/prpriv.h
-include/virtualbox/nsrootidl.h
-include/virtualbox/string/nsAString.h
-include/virtualbox/string/nsAlgorithm.h
-include/virtualbox/string/nsCharTraits.h
-include/virtualbox/string/nsDependentString.h
-include/virtualbox/string/nsDependentSubstring.h
-include/virtualbox/string/nsEmbedString.h
-include/virtualbox/string/nsLiteralString.h
-include/virtualbox/string/nsObsoleteAString.h
-include/virtualbox/string/nsPrintfCString.h
-include/virtualbox/string/nsPromiseFlatString.h
-include/virtualbox/string/nsReadableUtils.h
-include/virtualbox/string/nsString.h
-include/virtualbox/string/nsStringAPI.h
-include/virtualbox/string/nsStringFwd.h
-include/virtualbox/string/nsStringIterator.h
-include/virtualbox/string/nsSubstring.h
-include/virtualbox/string/nsSubstringTuple.h
-include/virtualbox/string/nsTAString.h
-include/virtualbox/string/nsTString.h
-include/virtualbox/string/nsTDependentString.h
-include/virtualbox/string/nsTDependentSubstring.h
-include/virtualbox/string/nsTObsoleteAString.h
-include/virtualbox/string/nsTPromiseFlatString.h
-include/virtualbox/string/nsTSubstring.h
-include/virtualbox/string/nsTSubstringTuple.h
-include/virtualbox/string/nsUTF8Utils.h
-include/virtualbox/string/nsXPIDLString.h
-include/virtualbox/string/string-template-def-char.h
-include/virtualbox/string/string-template-def-unichar.h
-include/virtualbox/string/string-template-undef.h
-include/virtualbox/xpcom/nsAgg.h
-include/virtualbox/xpcom/nsAppDirectoryServiceDefs.h
-include/virtualbox/xpcom/nsArray.h
-include/virtualbox/xpcom/nsArrayEnumerator.h
-include/virtualbox/xpcom/nsAtomService.h
-include/virtualbox/xpcom/nsAutoBuffer.h
-include/virtualbox/xpcom/nsAutoLock.h
-include/virtualbox/xpcom/nsAutoPtr.h
-include/virtualbox/xpcom/nsBaseHashtable.h
-include/virtualbox/xpcom/nsCOMArray.h
-include/virtualbox/xpcom/nsCRT.h
-include/virtualbox/xpcom/nsCategoryManagerUtils.h
-include/virtualbox/xpcom/nsCheapSets.h
-include/virtualbox/xpcom/nsClassHashtable.h
-include/virtualbox/xpcom/nsCom.h
-include/virtualbox/xpcom/nsComponentManagerObsolete.h
-include/virtualbox/xpcom/nsComponentManagerUtils.h
-include/virtualbox/xpcom/nsCppSharedAllocator.h
-include/virtualbox/xpcom/nsID.h
-include/virtualbox/xpcom/nsDataHashtable.h
-include/virtualbox/xpcom/nsDebugImpl.h
-include/virtualbox/xpcom/nsDeque.h
-include/virtualbox/xpcom/nsDirectoryService.h
-include/virtualbox/xpcom/nsDirectoryServiceDefs.h
-include/virtualbox/xpcom/nsDirectoryServiceUtils.h
-include/virtualbox/xpcom/nsDoubleHashtable.h
-include/virtualbox/xpcom/nsEnumeratorUtils.h
-include/virtualbox/xpcom/nsError.h
-include/virtualbox/xpcom/nsEscape.h
-include/virtualbox/xpcom/nsEventQueueUtils.h
-include/virtualbox/xpcom/nsFastLoadPtr.h
-include/virtualbox/xpcom/nsFastLoadService.h
-include/virtualbox/xpcom/nsFixedSizeAllocator.h
-include/virtualbox/xpcom/nsHashKeys.h
-include/virtualbox/xpcom/nsHashSets.h
-include/virtualbox/xpcom/nsHashtable.h
-include/virtualbox/xpcom/nsIAllocator.h
-include/virtualbox/xpcom/nsIByteBuffer.h
-include/virtualbox/xpcom/nsIID.h
-include/virtualbox/xpcom/nsIServiceManagerObsolete.h
-include/virtualbox/xpcom/nsIServiceManagerUtils.h
-include/virtualbox/xpcom/nsISupportsBase.h
-include/virtualbox/xpcom/nsISupportsObsolete.h
-include/virtualbox/xpcom/nsIUnicharBuffer.h
-include/virtualbox/xpcom/nsIUnicharInputStream.h
-include/virtualbox/xpcom/nsInt64.h
-include/virtualbox/xpcom/nsInterfaceHashtable.h
-include/virtualbox/xpcom/nsLinebreakConverter.h
-include/virtualbox/xpcom/nsLocalFile.h
-include/virtualbox/xpcom/nsLocalFileUnix.h
-include/virtualbox/xpcom/nsLocalFileOS2.h
-include/virtualbox/xpcom/nsLocalFileOSX.h
-include/virtualbox/xpcom/nsModule.h
-include/virtualbox/xpcom/nsMultiplexInputStream.h
-include/virtualbox/xpcom/nsNativeCharsetUtils.h
-include/virtualbox/xpcom/nsProcess.h
-include/virtualbox/xpcom/nsNativeComponentLoader.h
-include/virtualbox/xpcom/nsObserverService.h
-include/virtualbox/xpcom/nsObsoleteModuleLoading.h
-include/virtualbox/xpcom/nsProxiedService.h
-include/virtualbox/xpcom/nsProxyEvent.h
-include/virtualbox/xpcom/nsProxyRelease.h
-include/virtualbox/xpcom/nsQuickSort.h
-include/virtualbox/xpcom/nsRecyclingAllocator.h
-include/virtualbox/xpcom/nsRefPtrHashtable.h
-include/virtualbox/xpcom/nsScriptableInputStream.h
-include/virtualbox/xpcom/nsStaticAtom.h
-include/virtualbox/xpcom/nsStaticComponent.h
-include/virtualbox/xpcom/nsStaticNameTable.h
-include/virtualbox/xpcom/nsStorageStream.h
-include/virtualbox/xpcom/nsStreamUtils.h
-include/virtualbox/xpcom/nsStringEnumerator.h
-include/virtualbox/xpcom/nsStringIO.h
-include/virtualbox/xpcom/nsTHashtable.h
-include/virtualbox/xpcom/nsStringStream.h
-include/virtualbox/xpcom/nsSupportsArray.h
-include/virtualbox/xpcom/nsSupportsPrimitives.h
-include/virtualbox/xpcom/nsTextFormatter.h
-include/virtualbox/xpcom/nsTime.h
-include/virtualbox/xpcom/nsTraceRefcntImpl.h
-include/virtualbox/xpcom/nsUnitConversion.h
-include/virtualbox/xpcom/nsValueArray.h
-include/virtualbox/xpcom/nsVariant.h
-include/virtualbox/xpcom/nsVoidArray.h
-include/virtualbox/xpcom/nsWeakPtr.h
-include/virtualbox/xpcom/nsXPCOM.h
-include/virtualbox/xpcom/nsXPCOMCID.h
-include/virtualbox/xpcom/nscore.h
-include/virtualbox/xpcom/pldhash.h
-include/virtualbox/xpcom/plevent.h
-include/virtualbox/xpcom/xcDll.h
-include/virtualbox/xpcom/xpt_arena.h
-include/virtualbox/xpcom/xpt_struct.h
-include/virtualbox/xpcom/xpt_xdr.h
-include/virtualbox/xpcom/xptcall.h
-include/virtualbox/xpcom/xptcstubsdecl.inc
-include/virtualbox/xpcom/xptcstubsdef.inc
-include/virtualbox/xpcom/xptinfo.h
-include/virtualbox/xpcom/nsIInterfaceRequestorUtils.h
-include/virtualbox/xpcom/nsISupportsImpl.h
-include/virtualbox/xpcom/nsISupportsUtils.h
-include/virtualbox/xpcom/nsIWeakReferenceUtils.h
-include/virtualbox/xpcom/nsCOMPtr.h
-include/virtualbox/xpcom/nsDebug.h
-include/virtualbox/xpcom/nsGenericFactory.h
-include/virtualbox/xpcom/nsIGenericFactory.h
-include/virtualbox/xpcom/nsMemory.h
-include/virtualbox/xpcom/nsTraceRefcnt.h
-include/virtualbox/xpcom/nsWeakReference.h
-include/virtualbox/xpcom/nsXPCOMGlue.h
-include/virtualbox/xpcom/xpcom-config.h
-%%PYTHON_SITELIBDIR%%/vboxapi/__init__.py
-%%PYTHON_SITELIBDIR%%/vboxapi/__init__.pyc
-%%PYTHON_SITELIBDIR%%/vboxapi/VirtualBox_constants.py
-%%PYTHON_SITELIBDIR%%/vboxapi/VirtualBox_constants.pyc
-%%PYTHON_SITELIBDIR%%/vboxapi-1.0-py%%PYTHON_VER%%.egg-info
-%%PYTHON_SITELIBDIR%%/xpcom/__init__.py
-%%PYTHON_SITELIBDIR%%/xpcom/__init__.pyc
-%%PYTHON_SITELIBDIR%%/xpcom/components.py
-%%PYTHON_SITELIBDIR%%/xpcom/components.pyc
-%%PYTHON_SITELIBDIR%%/xpcom/file.py
-%%PYTHON_SITELIBDIR%%/xpcom/file.pyc
-%%PYTHON_SITELIBDIR%%/xpcom/nsError.py
-%%PYTHON_SITELIBDIR%%/xpcom/nsError.pyc
-%%PYTHON_SITELIBDIR%%/xpcom/primitives.py
-%%PYTHON_SITELIBDIR%%/xpcom/primitives.pyc
-%%PYTHON_SITELIBDIR%%/xpcom/vboxxpcom.py
-%%PYTHON_SITELIBDIR%%/xpcom/vboxxpcom.pyc
-%%PYTHON_SITELIBDIR%%/xpcom/xpcom_consts.py
-%%PYTHON_SITELIBDIR%%/xpcom/xpcom_consts.pyc
-%%PYTHON_SITELIBDIR%%/xpcom/xpt.py
-%%PYTHON_SITELIBDIR%%/xpcom/xpt.pyc
-%%PYTHON_SITELIBDIR%%/xpcom/client/__init__.py
-%%PYTHON_SITELIBDIR%%/xpcom/client/__init__.pyc
-%%PYTHON_SITELIBDIR%%/xpcom/server/__init__.py
-%%PYTHON_SITELIBDIR%%/xpcom/server/__init__.pyc
-%%PYTHON_SITELIBDIR%%/xpcom/server/enumerator.py
-%%PYTHON_SITELIBDIR%%/xpcom/server/enumerator.pyc
-%%PYTHON_SITELIBDIR%%/xpcom/server/factory.py
-%%PYTHON_SITELIBDIR%%/xpcom/server/factory.pyc
-%%PYTHON_SITELIBDIR%%/xpcom/server/loader.py
-%%PYTHON_SITELIBDIR%%/xpcom/server/loader.pyc
-%%PYTHON_SITELIBDIR%%/xpcom/server/module.py
-%%PYTHON_SITELIBDIR%%/xpcom/server/module.pyc
-%%PYTHON_SITELIBDIR%%/xpcom/server/policy.py
-%%PYTHON_SITELIBDIR%%/xpcom/server/policy.pyc
-@dirrm %%PYTHON_SITELIBDIR%%/xpcom/server
-@dirrm %%PYTHON_SITELIBDIR%%/xpcom/client
-@dirrm %%PYTHON_SITELIBDIR%%/xpcom
-@dirrm %%PYTHON_SITELIBDIR%%/vboxapi
-@dirrm include/virtualbox/xpcom
-@dirrm include/virtualbox/string
-@dirrm include/virtualbox/nsprpub/private
-@dirrm include/virtualbox/nsprpub/obsolete
-@dirrm include/virtualbox/nsprpub/md
-@dirrm include/virtualbox/nsprpub
-@dirrm include/virtualbox/ipcd
-@dirrm include/virtualbox
-%%NLS%%@dirrm %%DATADIR%%/nls
-@dirrm %%DATADIR%%/samples
-@dirrm %%DATADIR%%/idl
-@dirrm %%DATADIR%%
-%%QT4%%@dirrmtry share/icons/hicolor/48x48/apps
-%%QT4%%@dirrmtry share/icons/hicolor/48x48
-%%QT4%%@dirrmtry share/icons/hicolor
-%%QT4%%@dirrmtry share/icons
-%%QT4%%@dirrmtry share/applications
-@dirrm lib/virtualbox/components
-%%GUESTADDITIONS%%@dirrm lib/virtualbox/additions
-@dirrm lib/virtualbox
+@comment $FreeBSD$
@cwd /
%%KMODDIR%%/vboxdrv.ko
%%KMODDIR%%/vboxnetadp.ko
diff --git a/emulators/virtualbox-ose-legacy/Makefile b/emulators/virtualbox-ose-legacy/Makefile
index 46617a1b64b8..8b12ae5b785f 100644
--- a/emulators/virtualbox-ose-legacy/Makefile
+++ b/emulators/virtualbox-ose-legacy/Makefile
@@ -1,21 +1,20 @@
-# New ports collection makefile for: virtualbox
+# New ports collection makefile for: virtualbox-ose
# Date created: 2009-05-02
# Whom: Bernhard Froehlich <decke@bluelife.at>
#
# $FreeBSD$
#
-PORTNAME= virtualbox
-DISTVERSION= 3.0.51r22902
-PORTREVISION= 3
-CATEGORIES= emulators kld
+PORTNAME= virtualbox-ose
+DISTVERSION= 3.1.2
+CATEGORIES= emulators
MASTER_SITES= http://tmp.chruetertee.ch/ \
http://freebsd.unixfreunde.de/sources/ \
http://disasterarea.chruetertee.ch/ \
http://mirror.4bit.ws/ \
http://dlc.sun.com/virtualbox/${VBOX_GUEST_VER}/:guestadditions
-DISTFILES= ${DISTNAME}${EXTRACT_SUFX} ${GADISTFILES}
-EXTRACT_ONLY= ${DISTNAME}${EXTRACT_SUFX}
+DISTFILES= VirtualBox-${DISTVERSION}-OSE${EXTRACT_SUFX} ${GADISTFILES}
+EXTRACT_ONLY= VirtualBox-${DISTVERSION}-OSE${EXTRACT_SUFX}
#for discussion please use emulation@FreeBSD.org
MAINTAINER= vbox@FreeBSD.org
@@ -28,10 +27,11 @@ BUILD_DEPENDS= yasm:${PORTSDIR}/devel/yasm \
LIB_DEPENDS= png.5:${PORTSDIR}/graphics/png \
xslt.2:${PORTSDIR}/textproc/libxslt \
curl.5:${PORTSDIR}/ftp/curl
+RUN_DEPENDS= /boot/modules/vboxdrv.ko:${PORTSDIR}/emulators/virtualbox-ose-kmod
+WRKSRC= ${WRKDIR}/VirtualBox-${PORTVERSION}_OSE
ONLY_FOR_ARCHS= i386 amd64
USE_GNOME= libidl
-USE_CDRTOOLS= yes
USE_BZIP2= yes
USE_PYTHON= yes
USE_PYDISTUTILS= easy_install
@@ -48,7 +48,7 @@ CONFLICTS= bcc-[0-9]*
VBOXGROUP?= vboxusers
VBOXGID?= 920
VBOX_FRONTENDS= VBoxHeadless
-VBOX_GUEST_VER= 3.0.6
+VBOX_GUEST_VER= ${PORTVERSION}
SUB_FILES= pkg-install
@@ -66,12 +66,10 @@ OPTIONS= QT4 "Build with QT4 Frontend" on \
.include <bsd.port.options.mk>
-PLIST_SUB+= KMODDIR=${KMODDIR:C,^/,,} \
- PYTHON_VER=${PYTHON_VER} \
+PLIST_SUB+= PYTHON_VER=${PYTHON_VER} \
PYTHON_VERU=${PYTHON_VER:S/./_/} \
GUEST_VER=${VBOX_GUEST_VER}
-KMODDIR= /boot/modules
KMK_BUILDTYPE= release
KMK_CONFIG= VBOX_LIBPATH_X11=${LOCALBASE} VBOX_FREEBSD_SRC=${SRC_BASE}/sys
KMK_FLAGS=
@@ -130,6 +128,8 @@ CONFIGURE_ARGS+=--disable-dbus
.if !defined(WITH_PULSEAUDIO)
CONFIGURE_ARGS+=--disable-pulse
+.else
+LIB_DEPENDS+= pulse.0:${PORTSDIR}/audio/pulseaudio
.endif
.if !defined(WITHOUT_NLS)
@@ -138,10 +138,6 @@ PLIST_SUB+= NLS=""
PLIST_SUB+= NLS="@comment "
.endif
-.if !exists(${SRC_BASE}/sys/kern/bus_if.m)
-IGNORE= requires kernel sources for the kernel module
-.endif
-
.if ${OSVERSION} < 700000
BROKEN= Does not compile on FreeBSD 6.X
.endif
@@ -172,7 +168,9 @@ post-patch:
@${ECHO} 'VBOX_PATH_APP_PRIVATE = ${DATADIR}' >> ${WRKSRC}/LocalConfig.kmk
@${ECHO} 'VBOX_PATH_APP_DOCS = ${DOCSDIR}' >> ${WRKSRC}/LocalConfig.kmk
@${ECHO} 'VBOX_WITH_INSTALLER = 1' >> ${WRKSRC}/LocalConfig.kmk
- @${ECHO} 'VBOX_WITH_TESTCASES=' >> ${WRKSRC}/LocalConfig.kmk
+ @${ECHO} 'VBOX_WITH_VBOXDRV = ' >> ${WRKSRC}/LocalConfig.kmk
+ @${ECHO} 'VBOX_WITH_NETFLT = 1' >> ${WRKSRC}/LocalConfig.kmk
+ @${ECHO} 'VBOX_WITH_NETADP = ' >> ${WRKSRC}/LocalConfig.kmk
.if defined(WITHOUT_X11)
@${ECHO} 'VBOX_WITH_X11_ADDITIONS=' >> ${WRKSRC}/LocalConfig.kmk
.endif
@@ -191,11 +189,6 @@ do-build:
cd ${WRKSRC} && ${SH} env.sh && ${KMK_CONFIG} ${LOCALBASE}/bin/kmk ${KMK_FLAGS}
do-install:
- ${MKDIR} ${KMODDIR}
-.for f in vboxdrv.ko vboxnetadp.ko vboxnetflt.ko
- ${INSTALL_KLD} ${WRKSRC}/out/${KMK_ARCH}/${KMK_BUILDTYPE}/bin/${f} ${KMODDIR}
-.endfor
-
${MKDIR} ${DATADIR}
(cd ${WRKSRC}/out/${KMK_ARCH}/${KMK_BUILDTYPE}/bin/sdk/bindings/xpcom && ${COPYTREE_SHARE} "idl samples" ${DATADIR})
diff --git a/emulators/virtualbox-ose-legacy/distinfo b/emulators/virtualbox-ose-legacy/distinfo
index 492de57d1c4a..e1b840762c30 100644
--- a/emulators/virtualbox-ose-legacy/distinfo
+++ b/emulators/virtualbox-ose-legacy/distinfo
@@ -1,6 +1,6 @@
-MD5 (virtualbox-3.0.51r22902.tar.bz2) = c2fbfd0eca2d2c9e6ad5f029cf75def0
-SHA256 (virtualbox-3.0.51r22902.tar.bz2) = ccbc88276f9e1944005d1c2f3661ec6d7113b22801ecbbb72d422aa0ab2b0a2a
-SIZE (virtualbox-3.0.51r22902.tar.bz2) = 51742256
-MD5 (VBoxGuestAdditions_3.0.6.iso) = 8d033b4f66db1a3e5b914da1717e9c21
-SHA256 (VBoxGuestAdditions_3.0.6.iso) = d6a8b61ef1004637c8be3a70612bb0e101f552d7eb0a9a376ff1ad264baf6a3c
-SIZE (VBoxGuestAdditions_3.0.6.iso) = 32786432
+MD5 (VirtualBox-3.1.2-OSE.tar.bz2) = e7808f16114f5b1a65aa2df1aa33e1a7
+SHA256 (VirtualBox-3.1.2-OSE.tar.bz2) = 293f582e37eda29efdb53c6468481b446e1964592f5728656b74664f4d32f2b1
+SIZE (VirtualBox-3.1.2-OSE.tar.bz2) = 55553394
+MD5 (VBoxGuestAdditions_3.1.2.iso) = d1ac5c53fb889338849134e07a6bc16f
+SHA256 (VBoxGuestAdditions_3.1.2.iso) = 0180a76f011f3992a70e5168d24ce04a08a23fc94858140096a8fa175e742489
+SIZE (VBoxGuestAdditions_3.1.2.iso) = 33337344
diff --git a/emulators/virtualbox-ose-legacy/files/patch-configure b/emulators/virtualbox-ose-legacy/files/patch-configure
index c6532c3db606..a4aaf507ccc9 100644
--- a/emulators/virtualbox-ose-legacy/files/patch-configure
+++ b/emulators/virtualbox-ose-legacy/files/patch-configure
@@ -1,15 +1,33 @@
---- configure.orgi 2009-05-31 13:43:50.000000000 +0200
-+++ configure 2009-05-31 13:45:47.000000000 +0200
-@@ -102,7 +102,7 @@
- XSLTPROC="xsltproc"
+--- configure.orig 2009-12-17 15:23:05.000000000 +0100
++++ configure 2009-12-21 14:25:45.000000000 +0100
+@@ -107,7 +107,7 @@
GENISOIMAGE="genisoimage"
MKISOFS="mkisofs"
+ INCCRYPTO=""
-LIBCRYPTO="-lcrypto"
+LIBCRYPTO="-lcrypto -lssl"
LIBPTHREAD="-lpthread"
LIBCAP="-lcap"
GSOAP=""
-@@ -1698,7 +1698,7 @@
+@@ -125,6 +125,8 @@
+ if [ "$OS" = "freebsd" ]; then
+ INCCURL="-I/usr/local/include"
+ LIBCURL="-L/usr/local/lib -lcurl"
++ INCPULSE="-I/usr/local/include"
++ LIBPULSE="-L/usr/local/lib"
+ else
+ INCCURL=""
+ LIBCURL="-lcurl"
+@@ -1181,7 +1183,7 @@
+ #endif
+ }
+ EOF
+- if test_compile "-lpulse" pulse pulse; then
++ if test_compile "$INCPULSE $LIBPULSE -lpulse" pulse pulse; then
+ test_execute
+ fi
+ }
+@@ -1773,7 +1775,7 @@
cat $ODIR.tmp_src.cc >> $LOG
echo "using the following command line:" >> $LOG
echo "$CXX -O -Wall -o $ODIR.tmp_out $ODIR.tmp_src.cc -I$p/include/$d $p/$b/lib$d.so" >> $LOG
@@ -18,3 +36,31 @@
if [ $? -eq 0 ]; then
found=1
break
+@@ -2315,6 +2317,15 @@
+ [ $WITH_QT4 -eq 1 ] && check_qt4
+ [ $WITH_PYTHON -eq 1 ] && check_python
+
++# PulseAudio
++if [ "$OS" = "linux" -o "$OS" = "freebsd" ]; then
++ if [ $WITH_PULSE -eq 1 ]; then
++ check_pulse
++ else
++ cnf_append "VBOX_WITH_PULSE" ""
++ fi
++fi
++
+ # Linux-specific
+ if [ "$OS" = "linux" ]; then
+ # don't check for the static libstdc++ in the PUEL version as we build the
+@@ -2332,11 +2343,6 @@
+ else
+ cnf_append "VBOX_WITH_ALSA" ""
+ fi
+- if [ $WITH_PULSE -eq 1 ]; then
+- check_pulse
+- else
+- cnf_append "VBOX_WITH_PULSE" ""
+- fi
+ if [ $WITH_DBUS -eq 0 ]; then
+ cnf_append "VBOX_WITH_DBUS" ""
+ fi
diff --git a/emulators/virtualbox-ose-legacy/files/patch-src-VBox-Additions-x11-VBoxClient-Makefile.kmk b/emulators/virtualbox-ose-legacy/files/patch-src-VBox-Additions-x11-VBoxClient-Makefile.kmk
new file mode 100644
index 000000000000..cc5553f7736d
--- /dev/null
+++ b/emulators/virtualbox-ose-legacy/files/patch-src-VBox-Additions-x11-VBoxClient-Makefile.kmk
@@ -0,0 +1,20 @@
+Index: src/VBox/Additions/x11/VBoxClient/Makefile.kmk
+===================================================================
+--- src/VBox/Additions/x11/VBoxClient/Makefile.kmk (revision 25472)
++++ src/VBox/Additions/x11/VBoxClient/Makefile.kmk (revision 25473)
+@@ -43,11 +43,14 @@
+ $(VBOX_LIBPATH32_X11)
+ VBoxClient_LIBS.freebsd = \
+ iconv
++VBoxClient_LIBS.linux = \
++ dl
++VBoxClient_LIBS.solaris = \
++ dl
+ VBoxClient_LIBS = \
+ $(VBOX_LIB_IPRT_GUEST_R3) \
+ $(VBOX_LIB_VBGL_R3) \
+ $(VBOX_LIB_IPRT_GUEST_R3) \
+- dl \
+ X11 \
+ Xt
+ # These are static replacements for gcc-specific parts of libstdc++
diff --git a/emulators/virtualbox-ose-legacy/files/patch-src-VBox-Devices-Audio-audio.c b/emulators/virtualbox-ose-legacy/files/patch-src-VBox-Devices-Audio-audio.c
new file mode 100644
index 000000000000..16a3f8a69f73
--- /dev/null
+++ b/emulators/virtualbox-ose-legacy/files/patch-src-VBox-Devices-Audio-audio.c
@@ -0,0 +1,14 @@
+--- src/VBox/Devices/Audio/audio.c.orig 2009-12-15 14:54:13.000000000 +0900
++++ src/VBox/Devices/Audio/audio.c 2009-12-15 14:53:54.000000000 +0900
+@@ -73,6 +73,11 @@
+ &pulse_audio_driver,
+ # endif
+ #endif /* RT_OS_LINUX */
++#ifdef RT_OS_FREEBSD
++# ifdef VBOX_WITH_PULSE
++ &pulse_audio_driver,
++# endif
++#endif
+ #ifdef RT_OS_DARWIN
+ &coreaudio_audio_driver,
+ #endif
diff --git a/emulators/virtualbox-ose-legacy/files/patch-src-VBox-Devices-Makefile.kmk b/emulators/virtualbox-ose-legacy/files/patch-src-VBox-Devices-Makefile.kmk
index d404c8aee176..b76f318af457 100644
--- a/emulators/virtualbox-ose-legacy/files/patch-src-VBox-Devices-Makefile.kmk
+++ b/emulators/virtualbox-ose-legacy/files/patch-src-VBox-Devices-Makefile.kmk
@@ -1,15 +1,13 @@
---- src/VBox/Devices/Makefile.kmk.orig 2009-11-01 22:50:39.000000000 +0100
-+++ src/VBox/Devices/Makefile.kmk 2009-11-01 22:50:52.000000000 +0100
-@@ -31,8 +31,10 @@
- include $(PATH_SUB_CURRENT)/PC/VMI/Makefile.kmk
- endif
- include $(PATH_SUB_CURRENT)/Graphics/BIOS/Makefile.kmk
--include $(PATH_SUB_CURRENT)/testcase/Makefile.kmk
--include $(PATH_SUB_CURRENT)/Storage/testcase/Makefile.kmk
-+ifdef VBOX_WITH_TESTCASES
-+ include $(PATH_SUB_CURRENT)/testcase/Makefile.kmk
-+ include $(PATH_SUB_CURRENT)/Storage/testcase/Makefile.kmk
-+endif
- ifndef VBOX_OSE
- include $(PATH_SUB_CURRENT)/Storage/VBoxHDDFormats/Makefile.kmk
+--- src/VBox/Devices/Makefile.kmk.orig 2009-12-17 15:27:43.000000000 +0100
++++ src/VBox/Devices/Makefile.kmk 2009-12-21 14:29:56.000000000 +0100
+@@ -970,6 +970,10 @@
+ Drivers_SOURCES.linux+= \
+ Audio/pulseaudio.c \
+ Audio/pulse_stubs.c
++ Drivers_DEFS.freebsd += VBOX_WITH_PULSE
++ Drivers_SOURCES.freebsd+= \
++ Audio/pulseaudio.c \
++ Audio/pulse_stubs.c
endif
+
+ ifdef VBOX_WITH_USB
diff --git a/emulators/virtualbox-ose-legacy/files/patch-src-VBox-Frontends-VBoxManage-VBoxManageHelp.cpp b/emulators/virtualbox-ose-legacy/files/patch-src-VBox-Frontends-VBoxManage-VBoxManageHelp.cpp
new file mode 100644
index 000000000000..ffe2a20ceb63
--- /dev/null
+++ b/emulators/virtualbox-ose-legacy/files/patch-src-VBox-Frontends-VBoxManage-VBoxManageHelp.cpp
@@ -0,0 +1,37 @@
+--- src/VBox/Frontends/VBoxManage/VBoxManageHelp.cpp.orig 2009-12-15 15:16:21.000000000 +0900
++++ src/VBox/Frontends/VBoxManage/VBoxManageHelp.cpp 2009-12-15 15:14:01.000000000 +0900
+@@ -41,6 +41,11 @@
+ #else
+ bool fSolaris = false;
+ #endif
++#ifdef RT_OS_FREEBSD
++ bool fFreeBSD = true;
++#else
++ bool fFreeBSD = false;
++#endif
+ #ifdef RT_OS_DARWIN
+ bool fDarwin = true;
+ #else
+@@ -62,6 +67,7 @@
+ fLinux = true;
+ fWin = true;
+ fSolaris = true;
++ fFreeBSD = true;
+ fDarwin = true;
+ fVRDP = true;
+ fVBoxSDL = true;
+@@ -227,6 +233,14 @@
+ #endif
+ );
+ }
++ if (fFreeBSD)
++ {
++ RTPrintf( "|oss"
++#ifdef VBOX_WITH_PULSE
++ "|pulse"
++#endif
++ );
++ }
+ if (fDarwin)
+ {
+ RTPrintf( "|coreaudio");
diff --git a/emulators/virtualbox-ose-legacy/files/patch-src-VBox-Frontends-VBoxManage-VBoxManageModifyVM.cpp b/emulators/virtualbox-ose-legacy/files/patch-src-VBox-Frontends-VBoxManage-VBoxManageModifyVM.cpp
new file mode 100644
index 000000000000..38111c6205d4
--- /dev/null
+++ b/emulators/virtualbox-ose-legacy/files/patch-src-VBox-Frontends-VBoxManage-VBoxManageModifyVM.cpp
@@ -0,0 +1,23 @@
+--- src/VBox/Frontends/VBoxManage/VBoxManageModifyVM.cpp.orig 2009-09-09 23:39:46.000000000 +0900
++++ src/VBox/Frontends/VBoxManage/VBoxManageModifyVM.cpp 2009-12-15 15:22:27.000000000 +0900
+@@ -1478,6 +1478,20 @@
+ # endif
+
+ #endif /* !RT_OS_SOLARIS */
++#ifdef RT_OS_FREEBSD
++ else if (!strcmp(ValueUnion.psz, "oss"))
++ {
++ CHECK_ERROR(audioAdapter, COMSETTER(AudioDriver)(AudioDriverType_OSS));
++ CHECK_ERROR(audioAdapter, COMSETTER(Enabled)(true));
++ }
++# ifdef VBOX_WITH_PULSE
++ else if (!strcmp(ValueUnion.psz, "pulse"))
++ {
++ CHECK_ERROR(audioAdapter, COMSETTER(AudioDriver)(AudioDriverType_Pulse));
++ CHECK_ERROR(audioAdapter, COMSETTER(Enabled)(true));
++ }
++# endif
++#endif /* !RT_OS_FREEBSD */
+ #ifdef RT_OS_DARWIN
+ else if (!strcmp(ValueUnion.psz, "coreaudio"))
+ {
diff --git a/emulators/virtualbox-ose-legacy/files/patch-src-VBox-HostDrivers-Makefile.kmk b/emulators/virtualbox-ose-legacy/files/patch-src-VBox-HostDrivers-Makefile.kmk
new file mode 100644
index 000000000000..5e9024588b8a
--- /dev/null
+++ b/emulators/virtualbox-ose-legacy/files/patch-src-VBox-HostDrivers-Makefile.kmk
@@ -0,0 +1,27 @@
+--- src/VBox/HostDrivers/Makefile.kmk.orig 2009-10-05 11:17:45.000000000 +0200
++++ src/VBox/HostDrivers/Makefile.kmk 2009-10-05 11:18:08.000000000 +0200
+@@ -40,7 +40,7 @@
+ endif
+ endif
+
+- if1of ($(KBUILD_TARGET),linux freebsd)
++ if1of ($(KBUILD_TARGET),linux)
+ #
+ # Install the Makefile for module compliation on Linux and FreeBSD hosts
+ #
+@@ -51,6 +51,7 @@
+ HostDrivers-src_SOURCES.freebsd = freebsd/Makefile
+ endif
+
++if 0
+ if1of ($(KBUILD_TARGET),freebsd)
+ #
+ # Install the export_modules script for tar'ing the module sources on FreeBSD hosts
+@@ -60,6 +61,7 @@
+ HostDrivers-sh_MODE = a+rx,u+w
+ HostDrivers-sh_SOURCES.freebsd = freebsd/export_modules
+ endif
++endif
+ endif # !VBOX_ONLY_DOCS
+
+ # Let kBuild generate the rules.
diff --git a/emulators/virtualbox-ose-legacy/files/patch-src-VBox-HostDrivers-Support-SUPR3HardenedMain.cpp b/emulators/virtualbox-ose-legacy/files/patch-src-VBox-HostDrivers-Support-SUPR3HardenedMain.cpp
new file mode 100644
index 000000000000..4a89fec97dfa
--- /dev/null
+++ b/emulators/virtualbox-ose-legacy/files/patch-src-VBox-HostDrivers-Support-SUPR3HardenedMain.cpp
@@ -0,0 +1,33 @@
+--- src/VBox/HostDrivers/Support/SUPR3HardenedMain.cpp (revision 25471)
++++ src/VBox/HostDrivers/Support/SUPR3HardenedMain.cpp (revision 25472)
+@@ -66,6 +66,9 @@
+ # ifndef CAP_TO_MASK
+ # define CAP_TO_MASK(cap) RT_BIT(cap)
+ # endif
++# elif defined(RT_OS_FREEBSD)
++# include <sys/param.h>
++# include <sys/sysctl.h>
+ # elif defined(RT_OS_SOLARIS)
+ # include <priv.h>
+ # endif
+@@ -325,7 +328,19 @@
+ sprintf(szFileBuf, "/proc/%ld/path/a.out", (long)getpid());
+ int cchLink = readlink(szFileBuf, &g_szSupLibHardenedExePath[0], sizeof(g_szSupLibHardenedExePath) - 1);
+ # else /* RT_OS_FREEBSD: */
+- int cchLink = readlink("/proc/curproc/file", &g_szSupLibHardenedExePath[0], sizeof(g_szSupLibHardenedExePath) - 1);
++ int aiName[4];
++ size_t cbPath;
++
++ aiName[0] = CTL_KERN;
++ aiName[1] = KERN_PROC;
++ aiName[2] = KERN_PROC_PATHNAME;
++ aiName[3] = getpid();
++
++ cbPath = sizeof(g_szSupLibHardenedExePath) - 1;
++ if(sysctl(aiName, RT_ELEMENTS(aiName), g_szSupLibHardenedExePath, &cbPath, NULL, 0) < 0)
++ supR3HardenedFatal("supR3HardenedExecDir: sysctl failed\n");
++
++ int cchLink = strlen(g_szSupLibHardenedExePath);
+ # endif
+ if (cchLink < 0 || cchLink == sizeof(g_szSupLibHardenedExePath) - 1)
+ supR3HardenedFatal("supR3HardenedExecDir: couldn't read \"%s\", errno=%d cchLink=%d\n",
diff --git a/emulators/virtualbox-ose-legacy/files/patch-src-VBox-HostDrivers-VBoxNetAdp-freebsd-VBoxNetAdp-freebsd.c b/emulators/virtualbox-ose-legacy/files/patch-src-VBox-HostDrivers-VBoxNetAdp-freebsd-VBoxNetAdp-freebsd.c
deleted file mode 100644
index 0e223c4b9039..000000000000
--- a/emulators/virtualbox-ose-legacy/files/patch-src-VBox-HostDrivers-VBoxNetAdp-freebsd-VBoxNetAdp-freebsd.c
+++ /dev/null
@@ -1,11 +0,0 @@
---- src/VBox/HostDrivers/VBoxNetAdp/freebsd/VBoxNetAdp-freebsd.c.orig 2009-12-07 12:20:44.000000000 +0100
-+++ src/VBox/HostDrivers/VBoxNetAdp/freebsd/VBoxNetAdp-freebsd.c 2009-12-07 12:21:00.000000000 +0100
-@@ -92,7 +92,7 @@
- DECLARE_MODULE(vboxnetadp, g_VBoxNetAdpFreeBSDModule, SI_SUB_PSEUDO, SI_ORDER_ANY);
- MODULE_VERSION(vboxnetadp, 1);
- MODULE_DEPEND(vboxnetadp, vboxdrv, 1, 1, 1);
--MODULE_DEPEND(vboxnetadp, ng_vboxnetflt, 1, 1, 1);
-+MODULE_DEPEND(vboxnetadp, vboxnetflt, 1, 1, 1);
-
- /**
- * Module event handler
diff --git a/emulators/virtualbox-ose-legacy/files/patch-src-VBox-HostDrivers-VBoxNetFlt-VBoxNetFltInternal.h b/emulators/virtualbox-ose-legacy/files/patch-src-VBox-HostDrivers-VBoxNetFlt-VBoxNetFltInternal.h
deleted file mode 100644
index 250a1960a7f4..000000000000
--- a/emulators/virtualbox-ose-legacy/files/patch-src-VBox-HostDrivers-VBoxNetFlt-VBoxNetFltInternal.h
+++ /dev/null
@@ -1,28 +0,0 @@
-Index: src/VBox/HostDrivers/VBoxNetFlt/VBoxNetFltInternal.h
-===================================================================
---- src/VBox/HostDrivers/VBoxNetFlt/VBoxNetFltInternal.h (revision 23391)
-+++ src/VBox/HostDrivers/VBoxNetFlt/VBoxNetFltInternal.h (working copy)
-@@ -206,6 +206,14 @@
- hook_p output;
- /** Original interface flags */
- unsigned int flags;
-+ /** Input queue */
-+ struct ifqueue inq;
-+ /** Output queue */
-+ struct ifqueue outq;
-+ /** Input task */
-+ struct task tskin;
-+ /** Output task */
-+ struct task tskout;
- /** The MAC address of the interface. */
- RTMAC Mac;
- /** @} */
-@@ -241,6 +249,8 @@
- # endif
- #elif defined(RT_OS_LINUX)
- uint8_t abPadding[320];
-+#elif defined(RT_OS_FREEBSD)
-+ uint8_t abPadding[320];
- #else
- uint8_t abPadding[128];
- #endif
diff --git a/emulators/virtualbox-ose-legacy/files/patch-src-VBox-HostDrivers-VBoxNetFlt-freebsd-VBoxNetFlt-freebsd.c b/emulators/virtualbox-ose-legacy/files/patch-src-VBox-HostDrivers-VBoxNetFlt-freebsd-VBoxNetFlt-freebsd.c
deleted file mode 100644
index f23fedbf0ec0..000000000000
--- a/emulators/virtualbox-ose-legacy/files/patch-src-VBox-HostDrivers-VBoxNetFlt-freebsd-VBoxNetFlt-freebsd.c
+++ /dev/null
@@ -1,384 +0,0 @@
-Index: src/VBox/HostDrivers/VBoxNetFlt/freebsd/VBoxNetFlt-freebsd.c
-===================================================================
---- src/VBox/HostDrivers/VBoxNetFlt/freebsd/VBoxNetFlt-freebsd.c (revision 23391)
-+++ src/VBox/HostDrivers/VBoxNetFlt/freebsd/VBoxNetFlt-freebsd.c (working copy)
-@@ -43,6 +43,8 @@
- #include <sys/socket.h>
- #include <sys/sockio.h>
- #include <sys/syscallsubr.h>
-+#include <sys/queue.h>
-+#include <sys/taskqueue.h>
-
- #include <net/if.h>
- #include <net/if_var.h>
-@@ -78,8 +80,6 @@
- static ng_rcvdata_t ng_vboxnetflt_rcvdata;
- static ng_disconnect_t ng_vboxnetflt_disconnect;
- static int ng_vboxnetflt_mod_event(module_t mod, int event, void *data);
--static int ng_vboxnetflt_rcv_in(hook_p node, item_p item);
--static int ng_vboxnetflt_rcv_out(hook_p node, item_p item);
-
- /** Netgraph node type */
- #define NG_VBOXNETFLT_NODE_TYPE "vboxnetflt"
-@@ -112,8 +112,8 @@
- {
- .version = NG_ABI_VERSION,
- .name = NG_VBOXNETFLT_NODE_TYPE,
-- .mod_event = vboxnetflt_modevent,
-- .constructor = ng_vboxnetflt_constructor,
-+ .mod_event = vboxnetflt_modevent,
-+ .constructor = ng_vboxnetflt_constructor,
- .rcvmsg = ng_vboxnetflt_rcvmsg,
- .shutdown = ng_vboxnetflt_shutdown,
- .newhook = ng_vboxnetflt_newhook,
-@@ -122,7 +122,7 @@
- .cmdlist = ng_vboxnetflt_cmdlist,
- };
- NETGRAPH_INIT(vboxnetflt, &ng_vboxnetflt_typestruct);
--MODULE_VERSION(ng_vboxnetflt, 1);
-+MODULE_VERSION(vboxnetflt, 1);
- MODULE_DEPEND(ng_vboxnetflt, vboxdrv, 1, 1, 1);
-
- /**
-@@ -267,16 +267,12 @@
- if (strcmp(name, NG_VBOXNETFLT_HOOK_IN) == 0)
- {
- #if __FreeBSD_version >= 800000
-- NG_HOOK_SET_RCVDATA(hook, ng_vboxnetflt_rcv_in);
- NG_HOOK_SET_TO_INBOUND(hook);
- #endif
- pThis->u.s.input = hook;
- }
- else if (strcmp(name, NG_VBOXNETFLT_HOOK_OUT) == 0)
- {
--#if __FreeBSD_version >= 800000
-- NG_HOOK_SET_RCVDATA(hook, ng_vboxnetflt_rcv_out);
--#endif
- pThis->u.s.output = hook;
- }
- else
-@@ -310,161 +306,171 @@
-
- /**
- * Handle data on netgraph hooks.
-+ * Frames processing is deferred to a taskqueue because this might
-+ * be called with non-sleepable locks held and code paths inside
-+ * the virtual switch might sleep.
- */
- static int ng_vboxnetflt_rcvdata(hook_p hook, item_p item)
- {
- const node_p node = NG_HOOK_NODE(hook);
- PVBOXNETFLTINS pThis = NG_NODE_PRIVATE(node);
-+ struct ifnet *ifp = pThis->u.s.ifp;
- struct mbuf *m;
-+ struct m_tag *mtag;
-+ bool fActive;
-
-+ fActive = ASMAtomicUoReadBool(&pThis->fActive);
-+
-+ NGI_GET_M(item, m);
-+ NG_FREE_ITEM(item);
-+
-+ /* Locate tag to see if processing should be skipped for this frame */
-+ mtag = m_tag_locate(m, MTAG_VBOX, PACKET_TAG_VBOX, NULL);
-+ if (mtag != NULL)
-+ {
-+ m_tag_unlink(m, mtag);
-+ m_tag_free(mtag);
-+ }
-+
-+ /*
-+ * Handle incoming hook. This is connected to the
-+ * input path of the interface, thus handling incoming frames.
-+ */
- if (pThis->u.s.input == hook)
-- return ng_vboxnetflt_rcv_in(hook, item);
-+ {
-+ if (mtag != NULL || !fActive)
-+ {
-+ ether_demux(ifp, m);
-+ return (0);
-+ }
-+ mtx_lock_spin(&pThis->u.s.inq.ifq_mtx);
-+ _IF_ENQUEUE(&pThis->u.s.inq, m);
-+ mtx_unlock_spin(&pThis->u.s.inq.ifq_mtx);
-+ taskqueue_enqueue_fast(taskqueue_fast, &pThis->u.s.tskin);
-+ }
-+ /**
-+ * Handle mbufs on the outgoing hook, frames going to the interface
-+ */
- else if (pThis->u.s.output == hook)
-- return ng_vboxnetflt_rcv_out(hook, item);
-+ {
-+ if (mtag != NULL || !fActive)
-+ return ether_output_frame(ifp, m);
-+ mtx_lock_spin(&pThis->u.s.outq.ifq_mtx);
-+ _IF_ENQUEUE(&pThis->u.s.outq, m);
-+ mtx_unlock_spin(&pThis->u.s.outq.ifq_mtx);
-+ taskqueue_enqueue_fast(taskqueue_fast, &pThis->u.s.tskout);
-+ }
- else
- {
-- NGI_GET_M(item, m);
-- NG_FREE_ITEM(item);
-+ m_freem(m);
- }
- return (0);
- }
-
-+static int ng_vboxnetflt_shutdown(node_p node)
-+{
-+ PVBOXNETFLTINS pThis = NG_NODE_PRIVATE(node);
-+ bool fActive;
-+
-+ /* Prevent node shutdown if we're active */
-+ fActive = ASMAtomicUoReadBool(&pThis->fActive);
-+ if (fActive)
-+ return (EBUSY);
-+ NG_NODE_UNREF(node);
-+ return (0);
-+}
-+
-+static int ng_vboxnetflt_disconnect(hook_p hook)
-+{
-+ return (0);
-+}
-+
- /**
-- * Handle incoming hook. This is connected to the
-- * input path of the interface, thus handling incoming frames.
-+ * Input processing task, handles incoming frames
- */
--static int ng_vboxnetflt_rcv_in(hook_p hook, item_p item)
-+static void vboxNetFltFreeBSDinput(void *arg, int pending)
- {
-+ PVBOXNETFLTINS pThis = (PVBOXNETFLTINS)arg;
- struct mbuf *m, *m0;
-- struct m_tag *mtag;
-- const node_p node = NG_HOOK_NODE(hook);
-- PVBOXNETFLTINS pThis = NG_NODE_PRIVATE(node);
- struct ifnet *ifp = pThis->u.s.ifp;
-- bool fActive, fDropIt = false;
- unsigned int cSegs = 0;
-+ bool fDropIt = false, fActive;
- PINTNETSG pSG;
-
-- NGI_GET_M(item, m);
-- NG_FREE_ITEM(item);
--
-- fActive = ASMAtomicUoReadBool(&pThis->fActive);
-- if (!fActive)
-- goto out;
--
-- mtag = m_tag_locate(m, MTAG_VBOX, PACKET_TAG_VBOX, NULL);
-- if (mtag != NULL)
-- {
-- m_tag_unlink(m, mtag);
-- m_tag_free(mtag);
-- goto out;
-- }
- vboxNetFltRetain(pThis, true /* fBusy */);
--
-- for (m0 = m; m0 != NULL; m0 = m0->m_next)
-+ for (;;)
- {
-- if (m0->m_len > 0)
-- cSegs++;
-- }
-+ mtx_lock_spin(&pThis->u.s.inq.ifq_mtx);
-+ _IF_DEQUEUE(&pThis->u.s.inq, m);
-+ mtx_unlock_spin(&pThis->u.s.inq.ifq_mtx);
-+ if (m == NULL)
-+ break;
-
-+ for (m0 = m; m0 != NULL; m0 = m0->m_next)
-+ if (m0->m_len > 0)
-+ cSegs++;
-+
- #ifdef PADD_RUNT_FRAMES_FROM_HOST
-- if (m_length(m, NULL) < 60)
-- cSegs++;
-+ if (m_length(m, NULL) < 60)
-+ cSegs++;
- #endif
-
-- /* Create a copy of the mbuf and hand it to the virtual switch */
-- pSG = RTMemTmpAlloc(RT_OFFSETOF(INTNETSG, aSegs[cSegs]));
-- vboxNetFltFreeBSDMBufToSG(pThis, m, pSG, cSegs, 0);
-- fDropIt = pThis->pSwitchPort->pfnRecv(pThis->pSwitchPort, pSG, INTNETTRUNKDIR_WIRE);
-- RTMemTmpFree(pSG);
-+ /* Create a copy and deliver to the virtual switch */
-+ pSG = RTMemTmpAlloc(RT_OFFSETOF(INTNETSG, aSegs[cSegs]));
-+ vboxNetFltFreeBSDMBufToSG(pThis, m, pSG, cSegs, 0);
-+ fDropIt = pThis->pSwitchPort->pfnRecv(pThis->pSwitchPort, pSG, INTNETTRUNKDIR_HOST);
-+ RTMemTmpFree(pSG);
-+ if (fDropIt)
-+ m_freem(m);
-+ else
-+ ether_demux(ifp, m);
-+ }
- vboxNetFltRelease(pThis, true /* fBusy */);
--
--out:
-- /* Only deliver it to the host stack if the destination weren't a guest */
-- if (fDropIt)
-- {
-- m_freem(m);
-- return (0);
-- }
-- ether_demux(ifp, m);
-- return (0);
- }
-
- /**
-- * Handle mbufs on the outgoing hook, frames going to the interface
-+ * Output processing task, handles outgoing frames
- */
--static int ng_vboxnetflt_rcv_out(hook_p hook, item_p item)
-+static void vboxNetFltFreeBSDoutput(void *arg, int pending)
- {
-+ PVBOXNETFLTINS pThis = (PVBOXNETFLTINS)arg;
- struct mbuf *m, *m0;
-- struct m_tag *mtag;
-- const node_p node = NG_HOOK_NODE(hook);
-- PVBOXNETFLTINS pThis = NG_NODE_PRIVATE(node);
- struct ifnet *ifp = pThis->u.s.ifp;
- unsigned int cSegs = 0;
- bool fDropIt = false, fActive;
- PINTNETSG pSG;
-
-- NGI_GET_M(item, m);
-- NG_FREE_ITEM(item);
--
-- fActive = ASMAtomicUoReadBool(&pThis->fActive);
-- if (!fActive)
-- return ether_output_frame(ifp, m);
--
- vboxNetFltRetain(pThis, true /* fBusy */);
-- /* Pass directly to interface if the packet originated from us */
-- mtag = m_tag_locate(m, MTAG_VBOX, PACKET_TAG_VBOX, NULL);
-- if (mtag != NULL)
-+ for (;;)
- {
-- m_tag_unlink(m, mtag);
-- m_tag_free(mtag);
-- goto out;
-- }
-+ mtx_lock_spin(&pThis->u.s.outq.ifq_mtx);
-+ _IF_DEQUEUE(&pThis->u.s.outq, m);
-+ mtx_unlock_spin(&pThis->u.s.outq.ifq_mtx);
-+ if (m == NULL)
-+ break;
-
-- for (m0 = m; m0 != NULL; m0 = m0->m_next)
-- {
-- if (m0->m_len > 0)
-- cSegs++;
-- }
-+ for (m0 = m; m0 != NULL; m0 = m0->m_next)
-+ if (m0->m_len > 0)
-+ cSegs++;
-
- #ifdef PADD_RUNT_FRAMES_FROM_HOST
-- if (m_length(m, NULL) < 60)
-- cSegs++;
-+ if (m_length(m, NULL) < 60)
-+ cSegs++;
- #endif
-- /* Create a copy and deliver to the virtual switch */
-- pSG = RTMemTmpAlloc(RT_OFFSETOF(INTNETSG, aSegs[cSegs]));
-- vboxNetFltFreeBSDMBufToSG(pThis, m, pSG, cSegs, 0);
-- fDropIt = pThis->pSwitchPort->pfnRecv(pThis->pSwitchPort, pSG, INTNETTRUNKDIR_HOST);
-- RTMemTmpFree(pSG);
-+ /* Create a copy and deliver to the virtual switch */
-+ pSG = RTMemTmpAlloc(RT_OFFSETOF(INTNETSG, aSegs[cSegs]));
-+ vboxNetFltFreeBSDMBufToSG(pThis, m, pSG, cSegs, 0);
-+ fDropIt = pThis->pSwitchPort->pfnRecv(pThis->pSwitchPort, pSG, INTNETTRUNKDIR_HOST);
-+ RTMemTmpFree(pSG);
-
--out:
-+ if (fDropIt)
-+ m_freem(m);
-+ else
-+ ether_output_frame(ifp, m);
-+ }
- vboxNetFltRelease(pThis, true /* fBusy */);
-- if (fDropIt)
-- {
-- m_freem(m);
-- return (0);
-- }
--
-- return ether_output_frame(ifp, m);
- }
-
--static int ng_vboxnetflt_shutdown(node_p node)
--{
-- PVBOXNETFLTINS pThis = NG_NODE_PRIVATE(node);
-- bool fActive;
--
-- /* Prevent node shutdown if we're active */
-- fActive = ASMAtomicUoReadBool(&pThis->fActive);
-- if (fActive)
-- return (EBUSY);
-- NG_NODE_UNREF(node);
-- return (0);
--}
--
--static int ng_vboxnetflt_disconnect(hook_p hook)
--{
-- return (0);
--}
--
- /**
- * Called to deliver a frame to either the host, the wire or both.
- */
-@@ -536,13 +542,23 @@
-
- /* Create a new netgraph node for this instance */
- if (ng_make_node_common(&ng_vboxnetflt_typestruct, &node) != 0)
-- return VERR_INTERNAL_ERROR;
-+ return VERR_INTERNAL_ERROR;
-
- RTSpinlockAcquire(pThis->hSpinlock, &Tmp);
- ASMAtomicUoWritePtr((void * volatile *)&pThis->u.s.ifp, ifp);
- pThis->u.s.node = node;
- bcopy(IF_LLADDR(ifp), &pThis->u.s.Mac, ETHER_ADDR_LEN);
- ASMAtomicUoWriteBool(&pThis->fDisconnectedFromHost, false);
-+ /* Initialize deferred input queue */
-+ bzero(&pThis->u.s.inq, sizeof(struct ifqueue));
-+ mtx_init(&pThis->u.s.inq.ifq_mtx, "vboxnetflt inq", NULL, MTX_SPIN);
-+ TASK_INIT(&pThis->u.s.tskin, 0, vboxNetFltFreeBSDinput, pThis);
-+
-+ /* Initialize deferred output queue */
-+ bzero(&pThis->u.s.outq, sizeof(struct ifqueue));
-+ mtx_init(&pThis->u.s.outq.ifq_mtx, "vboxnetflt outq", NULL, MTX_SPIN);
-+ TASK_INIT(&pThis->u.s.tskout, 0, vboxNetFltFreeBSDoutput, pThis);
-+
- RTSpinlockRelease(pThis->hSpinlock, &Tmp);
-
- NG_NODE_SET_PRIVATE(node, pThis);
-@@ -571,7 +587,10 @@
- }
-
- if (ifp0 != NULL)
-+ {
-+ vboxNetFltOsDeleteInstance(pThis);
- vboxNetFltOsInitInstance(pThis, NULL);
-+ }
-
- return !ASMAtomicUoReadBool(&pThis->fDisconnectedFromHost);
- }
-@@ -579,6 +598,12 @@
- void vboxNetFltOsDeleteInstance(PVBOXNETFLTINS pThis)
- {
-
-+ taskqueue_drain(taskqueue_fast, &pThis->u.s.tskin);
-+ taskqueue_drain(taskqueue_fast, &pThis->u.s.tskout);
-+
-+ mtx_destroy(&pThis->u.s.inq.ifq_mtx);
-+ mtx_destroy(&pThis->u.s.outq.ifq_mtx);
-+
- if (pThis->u.s.node != NULL)
- ng_rmnode_self(pThis->u.s.node);
- pThis->u.s.node = NULL;
diff --git a/emulators/virtualbox-ose-legacy/files/patch-src-VBox-Installer-Makefile.kmk b/emulators/virtualbox-ose-legacy/files/patch-src-VBox-Installer-Makefile.kmk
new file mode 100644
index 000000000000..7f226b633c9b
--- /dev/null
+++ b/emulators/virtualbox-ose-legacy/files/patch-src-VBox-Installer-Makefile.kmk
@@ -0,0 +1,15 @@
+--- src/VBox/Installer/Makefile.kmk.orig 2009-10-05 14:31:40.000000000 +0200
++++ src/VBox/Installer/Makefile.kmk 2009-10-05 14:32:09.000000000 +0200
+@@ -38,10 +38,12 @@
+ if "$(KBUILD_TARGET)" == "win" && "$(KBUILD_HOST)" == "win"
+ include $(PATH_SUB_CURRENT)/win/Makefile.kmk
+ endif
++if 0
+ if "$(KBUILD_TARGET)" == "freebsd" && "$(KBUILD_HOST)" == "freebsd"
+ include $(PATH_SUB_CURRENT)/freebsd/Makefile.kmk
+ endif
+ endif
++endif
+
+ include $(PATH_SUB_CURRENT)/common/Makefile.kmk
+
diff --git a/emulators/virtualbox-ose-legacy/files/patch-src-VBox-Main-AudioAdapterImpl.cpp b/emulators/virtualbox-ose-legacy/files/patch-src-VBox-Main-AudioAdapterImpl.cpp
new file mode 100644
index 000000000000..f47f49c97b0e
--- /dev/null
+++ b/emulators/virtualbox-ose-legacy/files/patch-src-VBox-Main-AudioAdapterImpl.cpp
@@ -0,0 +1,14 @@
+--- src/VBox/Main/AudioAdapterImpl.cpp.orig 2009-12-15 14:45:08.000000000 +0900
++++ src/VBox/Main/AudioAdapterImpl.cpp 2009-12-15 14:45:42.000000000 +0900
+@@ -261,6 +261,11 @@
+ #if defined (RT_OS_LINUX) || defined (RT_OS_FREEBSD) || defined(VBOX_WITH_SOLARIS_OSS)
+ case AudioDriverType_OSS:
+ #endif
++#ifdef RT_OS_FREEBSD
++# ifdef VBOX_WITH_PULSE
++ case AudioDriverType_Pulse:
++# endif
++#endif
+ #ifdef RT_OS_DARWIN
+ case AudioDriverType_CoreAudio:
+ #endif
diff --git a/emulators/virtualbox-ose-legacy/files/patch-src-VBox-Main-ConsoleImpl.cpp b/emulators/virtualbox-ose-legacy/files/patch-src-VBox-Main-ConsoleImpl.cpp
new file mode 100644
index 000000000000..cb67a48f5a44
--- /dev/null
+++ b/emulators/virtualbox-ose-legacy/files/patch-src-VBox-Main-ConsoleImpl.cpp
@@ -0,0 +1,11 @@
+--- src/VBox/Main/ConsoleImpl.cpp.orig
++++ src/VBox/Main/ConsoleImpl.cpp
+@@ -6168,7 +6168,7 @@ Console::usbDetachCallback(Console *that
+ }
+
+ #endif /* VBOX_WITH_USB */
+-#if (defined(RT_OS_LINUX) || defined(RT_OS_FREEBSD)) && !defined(VBOX_WITH_NETFLT)
++#if ((defined(RT_OS_LINUX) && !defined(VBOX_WITH_NETFLT)) || defined(RT_OS_FREEBSD))
+
+ /**
+ * Helper function to handle host interface device creation and attachment.
diff --git a/emulators/virtualbox-ose-legacy/files/patch-src-VBox-Main-ConsoleImpl2.cpp b/emulators/virtualbox-ose-legacy/files/patch-src-VBox-Main-ConsoleImpl2.cpp
new file mode 100644
index 000000000000..4373abea3487
--- /dev/null
+++ b/emulators/virtualbox-ose-legacy/files/patch-src-VBox-Main-ConsoleImpl2.cpp
@@ -0,0 +1,103 @@
+--- src/VBox/Main/ConsoleImpl2.cpp.orig 2009-12-15 14:48:58.000000000 +0900
++++ src/VBox/Main/ConsoleImpl2.cpp 2009-12-15 14:48:42.000000000 +0900
+@@ -86,6 +86,7 @@
+ # include <sys/ioctl.h>
+ # include <sys/socket.h>
+ # include <net/if.h>
++# include <net80211/ieee80211_ioctl.h>
+ #endif
+
+ #if defined(RT_OS_WINDOWS) && defined(VBOX_WITH_NETFLT)
+@@ -1605,6 +1605,15 @@
+ break;
+ }
+ #endif
++#ifdef RT_OS_FREEBSD
++# ifdef VBOX_WITH_PULSE
++ case AudioDriverType_Pulse:
++ {
++ rc = CFGMR3InsertString(pCfg, "AudioDriver", "pulse"); RC_CHECK();
++ break;
++ }
++# endif
++#endif
+ #ifdef RT_OS_DARWIN
+ case AudioDriverType_CoreAudio:
+ {
+@@ -2394,6 +2394,42 @@ DECLCALLBACK(int) Console::configConstru
+ /* we're not releasing the INetCfg stuff here since we use it later to figure out whether it is wireless */
+
+ # elif defined(RT_OS_LINUX) || defined(RT_OS_FREEBSD)
++# if defined(RT_OS_FREEBSD)
++ /*
++ * If we bridge to a tap interface open it the `old' direct way.
++ * This works and performs better than bridging a physical
++ * interface via the current FreeBSD vboxnetflt implementation.
++ */
++ if (!strncmp(pszHifName, "tap", sizeof "tap" - 1)) {
++ hrc = pThis->attachToTapInterface(aNetworkAdapter);
++ if (FAILED(hrc))
++ {
++ switch (hrc)
++ {
++ case VERR_ACCESS_DENIED:
++ return VMSetError(pVM, VERR_HOSTIF_INIT_FAILED, RT_SRC_POS, N_(
++ "Failed to open '/dev/%s' for read/write access. Please check the "
++ "permissions of that node, and that the net.link.tap.user_open "
++ "sysctl is set. Either run 'chmod 0666 /dev/%s' or "
++ "change the group of that node to vboxusers and make yourself "
++ "a member of that group. Make sure that these changes are permanent."), pszHifName, pszHifName);
++ default:
++ AssertMsgFailed(("Could not attach to tap interface! Bad!\n"));
++ return VMSetError(pVM, VERR_HOSTIF_INIT_FAILED, RT_SRC_POS, N_(
++ "Failed to initialize Host Interface Networking"));
++ }
++ }
++
++ Assert ((int)pThis->maTapFD[uInstance] >= 0);
++ if ((int)pThis->maTapFD[uInstance] >= 0)
++ {
++ rc = CFGMR3InsertString(pLunL0, "Driver", "HostInterface"); RC_CHECK();
++ rc = CFGMR3InsertNode(pLunL0, "Config", &pCfg); RC_CHECK();
++ rc = CFGMR3InsertInteger(pCfg, "FileHandle", pThis->maTapFD[uInstance]); RC_CHECK();
++ }
++ break;
++ }
++# endif
+ /** @todo Check for malformed names. */
+ const char *pszTrunk = pszHifName;
+
+@@ -2495,6 +2496,33 @@ DECLCALLBACK(int) Console::configConstru
+ }
+ else
+ Log(("Failed to open wireless socket\n"));
++# elif defined(RT_OS_FREEBSD)
++ int iSock = socket(AF_INET, SOCK_DGRAM, 0);
++ if (iSock >= 0)
++ {
++ struct ieee80211req ireq;
++ uint8_t data[32];
++
++ (void) memset(&ireq, 0, sizeof(ireq));
++ (void) strncpy(ireq.i_name, pszHifName, sizeof(ireq.i_name));
++ ireq.i_type = IEEE80211_IOC_SSID;
++ ireq.i_val = -1;
++ ireq.i_data = data;
++ ireq.i_len = sizeof(data);
++
++ bool fSharedMacOnWire = ioctl(iSock, SIOCG80211, &ireq) >= 0;
++ close(iSock);
++ if (fSharedMacOnWire)
++ {
++ rc = CFGMR3InsertInteger(pCfg, "SharedMacOnWire", true);
++ RC_CHECK();
++ Log(("Set SharedMacOnWire\n"));
++ }
++ else
++ Log(("Failed to get wireless name\n"));
++ }
++ else
++ Log(("Failed to open wireless socket\n"));
+ # elif defined(RT_OS_WINDOWS)
+ # define DEVNAME_PREFIX L"\\\\.\\"
+ /* we are getting the medium type via IOCTL_NDIS_QUERY_GLOBAL_STATS Io Control
diff --git a/emulators/virtualbox-ose-legacy/files/patch-src-VBox-Main-include-ConsoleImpl.h b/emulators/virtualbox-ose-legacy/files/patch-src-VBox-Main-include-ConsoleImpl.h
new file mode 100644
index 000000000000..2471480886d8
--- /dev/null
+++ b/emulators/virtualbox-ose-legacy/files/patch-src-VBox-Main-include-ConsoleImpl.h
@@ -0,0 +1,20 @@
+--- src/VBox/Main/include/ConsoleImpl.h.orig
++++ src/VBox/Main/include/ConsoleImpl.h
+@@ -410,7 +410,7 @@ private:
+
+ HRESULT callTapSetupApplication(bool isStatic, RTFILE tapFD, Bstr &tapDevice,
+ Bstr &tapSetupApplication);
+-#if (defined(RT_OS_LINUX) || defined(RT_OS_FREEBSD)) && !defined(VBOX_WITH_NETFLT)
++#if ((defined(RT_OS_LINUX) && !defined(VBOX_WITH_NETFLT)) || defined(RT_OS_FREEBSD))
+ HRESULT attachToTapInterface(INetworkAdapter *networkAdapter);
+ HRESULT detachFromTapInterface(INetworkAdapter *networkAdapter);
+ #endif
+@@ -582,7 +582,7 @@ private:
+ PPDMLED mapNetworkLeds[SchemaDefs::NetworkAdapterCount];
+ PPDMLED mapSharedFolderLed;
+ PPDMLED mapUSBLed[2];
+-#if !defined(VBOX_WITH_NETFLT) && (defined(RT_OS_LINUX) || defined(RT_OS_FREEBSD))
++#if ((defined(RT_OS_LINUX) && !defined(VBOX_WITH_NETFLT)) || defined(RT_OS_FREEBSD))
+ Utf8Str maTAPDeviceName[8];
+ RTFILE maTapFD[8];
+ #endif
diff --git a/emulators/virtualbox-ose-legacy/files/patch-src-VBox-Runtime-VBox-log-vbox.cpp b/emulators/virtualbox-ose-legacy/files/patch-src-VBox-Runtime-VBox-log-vbox.cpp
new file mode 100644
index 000000000000..005a25e4a79a
--- /dev/null
+++ b/emulators/virtualbox-ose-legacy/files/patch-src-VBox-Runtime-VBox-log-vbox.cpp
@@ -0,0 +1,82 @@
+--- src/VBox/Runtime/VBox/log-vbox.cpp (revision 25471)
++++ src/VBox/Runtime/VBox/log-vbox.cpp (revision 25472)
+@@ -135,6 +135,12 @@
+ # include <Windows.h>
+ # elif defined(RT_OS_LINUX)
+ # include <unistd.h>
++# elif defined(RT_OS_FREEBSD)
++# include <sys/param.h>
++# include <sys/sysctl.h>
++# include <sys/user.h>
++# include <stdlib.h>
++# include <unistd.h>
+ # elif defined(RT_OS_SOLARIS)
+ # define _STRUCTURED_PROC 1
+ # undef _FILE_OFFSET_BITS /* procfs doesn't like this */
+@@ -157,6 +163,7 @@
+ # include <iprt/path.h>
+ # include <iprt/process.h>
+ # include <iprt/string.h>
++# include <iprt/mem.h>
+ # include <stdio.h>
+ #endif
+
+@@ -339,12 +346,8 @@
+ fclose(pFile);
+ }
+
+-# elif defined(RT_OS_LINUX) || defined(RT_OS_FREEBSD)
+-# ifdef RT_OS_LINUX
++# elif defined(RT_OS_LINUX)
+ FILE *pFile = fopen("/proc/self/cmdline", "r");
+-# else /* RT_OS_FREEBSD: */
+- FILE *pFile = fopen("/proc/curproc/cmdline", "r");
+-# endif
+ if (pFile)
+ {
+ /* braindead */
+@@ -370,7 +373,44 @@
+ RTLogLoggerEx(pLogger, 0, ~0U, "\n");
+ fclose(pFile);
+ }
++# elif defined(RT_OS_FREEBSD)
++ char *pszArgFileBuf = NULL;
++ int aiName[4];
++ size_t cchArgs;
+
++ aiName[0] = CTL_KERN;
++ aiName[1] = KERN_PROC;
++ aiName[2] = KERN_PROC_ARGS;
++ aiName[3] = -1;
++
++ /* Retrieve the required length first */
++ cchArgs = 0;
++ int rcBSD = sysctl(aiName, RT_ELEMENTS(aiName), NULL, &cchArgs, NULL, 0);
++
++ if (cchArgs > 0)
++ {
++ pszArgFileBuf = (char *)RTMemAllocZ(cchArgs + 1 /* Safety */);
++ if (pszArgFileBuf)
++ {
++ /* Retrieve the argument list */
++ rcBSD = sysctl(aiName, RT_ELEMENTS(aiName), pszArgFileBuf, &cchArgs, NULL, 0);
++ if (!rcBSD)
++ {
++ /*
++ * cmdline is a flattened argument list so we need
++ * to convert all \0 to blanks
++ */
++ for(size_t i = 0; i < cchArgs - 1; i++)
++ {
++ if(pszArgFileBuf[i] == '\0')
++ pszArgFileBuf[i] = ' ';
++ }
++
++ RTLogLoggerEx(pLogger, 0, ~0U, "Commandline: %s\n", pszArgFileBuf);
++ }
++ RTMemFree(pszArgFileBuf);
++ }
++ }
+ # elif defined(RT_OS_L4) || defined(RT_OS_OS2) || defined(RT_OS_DARWIN)
+ /* commandline? */
+ # else
diff --git a/emulators/virtualbox-ose-legacy/files/patch-src-VBox-Runtime-r0drv-freebsd-spinlock-r0drv-freebsd.c b/emulators/virtualbox-ose-legacy/files/patch-src-VBox-Runtime-r0drv-freebsd-spinlock-r0drv-freebsd.c
deleted file mode 100644
index c7c56d5814ee..000000000000
--- a/emulators/virtualbox-ose-legacy/files/patch-src-VBox-Runtime-r0drv-freebsd-spinlock-r0drv-freebsd.c
+++ /dev/null
@@ -1,14 +0,0 @@
-Index: src/VBox/Runtime/r0drv/freebsd/spinlock-r0drv-freebsd.c
-@@ -171,7 +171,12 @@ RTDECL(void) RTSpinlockAcquire(RTSPINLOC
- AssertPtr(pThis);
- Assert(pThis->u32Magic == RTSPINLOCK_MAGIC);
- #ifdef RT_STRICT
-+#if 0
-+ /* This can't work because at least RTPowerNotificationRegister calls
-+ * RTSpinlockAcquire with *pTmp allocated on the stack.
-+ */
- Assert(pTmp->uFlags == 0);
-+#endif
- pTmp->uFlags = 42;
- #endif
-
diff --git a/emulators/virtualbox-ose-legacy/files/patch-src-VBox-Runtime-r0drv-freebsd-the-freebsd-kernel.h b/emulators/virtualbox-ose-legacy/files/patch-src-VBox-Runtime-r0drv-freebsd-the-freebsd-kernel.h
deleted file mode 100644
index 4332049487c3..000000000000
--- a/emulators/virtualbox-ose-legacy/files/patch-src-VBox-Runtime-r0drv-freebsd-the-freebsd-kernel.h
+++ /dev/null
@@ -1,11 +0,0 @@
---- src/VBox/Runtime/r0drv/freebsd/the-freebsd-kernel.h.orig 2009-09-11 14:48:47.000000000 +0200
-+++ src/VBox/Runtime/r0drv/freebsd/the-freebsd-kernel.h 2009-09-11 14:48:54.000000000 +0200
-@@ -76,7 +76,7 @@
- # define SLEEPQ_TIMEDWAIT_SIG(EventInt) sleepq_timedwait_sig(EventInt, 0)
- # define SLEEPQ_WAIT(EventInt) sleepq_wait(EventInt, 0)
- # define SLEEPQ_WAIT_SIG(EventInt) sleepq_wait_sig(EventInt, 0)
--#elif
-+#else
- # define SLEEPQ_TIMEDWAIT(EventInt) sleepq_timedwait(EventInt)
- # define SLEEPQ_TIMEDWAIT_SIG(EventInt) sleepq_timedwait_sig(EventInt)
- # define SLEEPQ_WAIT(EventInt) sleepq_wait(EventInt)
diff --git a/emulators/virtualbox-ose-legacy/files/patch-src-VBox-Runtime-r3-freebsd-rtProcInitExePath-freebsd.cpp b/emulators/virtualbox-ose-legacy/files/patch-src-VBox-Runtime-r3-freebsd-rtProcInitExePath-freebsd.cpp
new file mode 100644
index 000000000000..2332212ead14
--- /dev/null
+++ b/emulators/virtualbox-ose-legacy/files/patch-src-VBox-Runtime-r3-freebsd-rtProcInitExePath-freebsd.cpp
@@ -0,0 +1,81 @@
+--- src/VBox/Runtime/r3/freebsd/rtProcInitExePath-freebsd.cpp (revision 25471)
++++ src/VBox/Runtime/r3/freebsd/rtProcInitExePath-freebsd.cpp (revision 25472)
+@@ -32,6 +32,8 @@
+ * Header Files *
+ *******************************************************************************/
+ #define LOG_GROUP RTLOGGROUP_PROCESS
++#include <sys/param.h>
++#include <sys/sysctl.h>
+ #include <unistd.h>
+ #include <errno.h>
+ #include <dlfcn.h>
+@@ -47,17 +49,20 @@
+
+ DECLHIDDEN(int) rtProcInitExePath(char *pszPath, size_t cchPath)
+ {
+- /*
+- * Read the /proc/curproc/file link, convert to native and return it.
+- */
+- int cchLink = readlink("/proc/curproc/file", pszPath, cchPath - 1);
+- if (cchLink > 0 && (size_t)cchLink <= cchPath - 1)
+- {
+- pszPath[cchLink] = '\0';
++ int aiName[4];
++ size_t cchExePath;
+
++ aiName[0] = CTL_KERN;
++ aiName[1] = KERN_PROC;
++ aiName[2] = KERN_PROC_PATHNAME;
++ aiName[3] = getpid();
++
++ cchExePath = cchPath - 1;
++ if(sysctl(aiName, RT_ELEMENTS(aiName), pszPath, &cchExePath, NULL, 0) == 0)
++ {
+ char *pszTmp = NULL;
+ int rc = rtPathFromNative(&pszTmp, pszPath);
+- AssertMsgRCReturn(rc, ("rc=%Rrc pszLink=\"%s\"\nhex: %.*Rhsx\n", rc, pszPath, cchLink, pszPath), rc);
++ AssertMsgRCReturn(rc, ("rc=%Rrc pszLink=\"%s\"\nhex: %.*Rhsx\n", rc, pszPath, cchExePath, pszPath), rc);
+
+ size_t cch = strlen(pszTmp);
+ AssertReturn(cch <= cchPath, VERR_BUFFER_OVERFLOW);
+@@ -68,39 +73,8 @@
+ return VINF_SUCCESS;
+ }
+
+- int err = errno;
+-
+- /*
+- * Fall back on the dynamic linker since /proc is optional.
+- */
+- void *hExe = dlopen(NULL, 0);
+- if (hExe)
+- {
+- struct link_map const *pLinkMap = 0;
+- if (dlinfo(hExe, RTLD_DI_LINKMAP, &pLinkMap) == 0)
+- {
+- const char *pszImageName = pLinkMap->l_name;
+- if (*pszImageName == '/') /* this may not always be absolute, despite the docs. :-( */
+- {
+- char *pszTmp = NULL;
+- int rc = rtPathFromNative(&pszTmp, pszImageName);
+- AssertMsgRCReturn(rc, ("rc=%Rrc pszImageName=\"%s\"\n", rc, pszImageName), rc);
+-
+- size_t cch = strlen(pszTmp);
+- AssertReturn(cch <= cchPath, VERR_BUFFER_OVERFLOW);
+-
+- memcpy(pszPath, pszTmp, cch + 1);
+- RTStrFree(pszTmp);
+-
+- return VINF_SUCCESS;
+- }
+- /** @todo Try search the PATH for the file name or append the current
+- * directory, which ever makes sense... */
+- }
+- }
+-
+- int rc = RTErrConvertFromErrno(err);
+- AssertMsgFailed(("rc=%Rrc err=%d cchLink=%d hExe=%p\n", rc, err, cchLink, hExe));
++ int rc = RTErrConvertFromErrno(errno);
++ AssertMsgFailed(("rc=%Rrc errno=%d cchLink=%d\n", rc, errno, cchExePath));
+ return rc;
+ }
diff --git a/emulators/virtualbox-ose-legacy/files/patch-src-VBox-apps-adpctl_VBoxNetAdpCtl.cpp b/emulators/virtualbox-ose-legacy/files/patch-src-VBox-apps-adpctl_VBoxNetAdpCtl.cpp
deleted file mode 100644
index 955bf7a3a151..000000000000
--- a/emulators/virtualbox-ose-legacy/files/patch-src-VBox-apps-adpctl_VBoxNetAdpCtl.cpp
+++ /dev/null
@@ -1,207 +0,0 @@
---- src/apps/adpctl/VBoxNetAdpCtl.cpp.r22902 2009-04-10 14:03:59.000000000 +0200
-+++ src/apps/adpctl/VBoxNetAdpCtl.cpp 2009-09-16 14:07:11.000000000 +0200
-@@ -1,4 +1,4 @@
--/* $Id: VBoxNetAdpCtl.cpp 18864 2009-04-10 12:03:59Z vboxsync $ */
-+/* $Id: VBoxNetAdpCtl.cpp 23064 2009-09-16 12:07:11Z vboxsync $ */
- /** @file
- * Apps - VBoxAdpCtl, Configuration tool for vboxnetX adapters.
- */
-@@ -24,7 +24,6 @@
- /*******************************************************************************
- * Header Files *
- *******************************************************************************/
--#include <assert.h>
- #include <stdio.h>
- #include <stdlib.h>
- #include <string.h>
-@@ -36,11 +35,12 @@
- # include <sys/ioccom.h>
- #endif
-
--/* @todo Error codes must be moved to some header file */
--#define ADPCTLERR_NO_CTL_DEV 3
--#define ADPCTLERR_IOCTL_FAILED 4
-+/** @todo Error codes must be moved to some header file */
-+#define ADPCTLERR_BAD_NAME 2
-+#define ADPCTLERR_NO_CTL_DEV 3
-+#define ADPCTLERR_IOCTL_FAILED 4
-
--/* @todo These are duplicates from src/VBox/HostDrivers/VBoxNetAdp/VBoxNetAdpInternal.h */
-+/** @todo These are duplicates from src/VBox/HostDrivers/VBoxNetAdp/VBoxNetAdpInternal.h */
- #define VBOXNETADP_CTL_DEV_NAME "/dev/vboxnetctl"
- #define VBOXNETADP_NAME "vboxnet"
- #define VBOXNETADP_MAX_NAME_LEN 32
-@@ -85,6 +85,7 @@
- pcszArg5, /* [network mask] */
- NULL /* terminator */
- };
-+ char * const envp[] = { (char*)"LC_ALL=C", NULL };
- int rc = EXIT_SUCCESS;
- pid_t childPid = fork();
- switch (childPid)
-@@ -94,7 +95,7 @@
- rc = EXIT_FAILURE;
- break;
- case 0: /* Child process. */
-- if (execv(VBOXADPCTL_IFCONFIG_PATH, (char * const*)argv) == -1)
-+ if (execve(VBOXADPCTL_IFCONFIG_PATH, (char * const*)argv, envp) == -1)
- rc = EXIT_FAILURE;
- break;
- default: /* Parent process. */
-@@ -108,15 +109,39 @@
- #define MAX_ADDRESSES 128
- #define MAX_ADDRLEN 64
-
--static bool removeAddresses(const char *pszAdapterName)
-+static bool removeAddresses(char *pszAdapterName)
- {
-- char szCmd[1024], szBuf[1024];
-+ char szBuf[1024];
- char aszAddresses[MAX_ADDRESSES][MAX_ADDRLEN];
-+ int rc;
-+ int fds[2];
-+ char * const argv[] = { VBOXADPCTL_IFCONFIG_PATH, pszAdapterName, NULL };
-+ char * const envp[] = { (char*)"LC_ALL=C", NULL };
-
- memset(aszAddresses, 0, sizeof(aszAddresses));
-- snprintf(szCmd, sizeof(szCmd), VBOXADPCTL_IFCONFIG_PATH " %s", pszAdapterName);
-- FILE *fp = popen(szCmd, "r");
-
-+ rc = pipe(fds);
-+ if (rc < 0)
-+ return false;
-+
-+ pid_t pid = fork();
-+ if (pid < 0)
-+ return false;
-+
-+ if (pid == 0)
-+ {
-+ /* child */
-+ close(fds[0]);
-+ close(STDOUT_FILENO);
-+ rc = dup2(fds[1], STDOUT_FILENO);
-+ if (rc >= 0)
-+ execve(VBOXADPCTL_IFCONFIG_PATH, argv, envp);
-+ return false;
-+ }
-+
-+ /* parent */
-+ close(fds[1]);
-+ FILE *fp = fdopen(fds[0], "r");
- if (!fp)
- return false;
-
-@@ -124,9 +149,6 @@
- for (cAddrs = 0; cAddrs < MAX_ADDRESSES && fgets(szBuf, sizeof(szBuf), fp);)
- {
- int cbSkipWS = strspn(szBuf, " \t");
--#if 0 /* Don't use this! assert() breaks the mac build. Use IPRT or be a rectangular building thing. */
-- assert(cbSkipWS < 20);
--#endif
- char *pszWord = strtok(szBuf + cbSkipWS, " ");
- /* We are concerned with IPv6 address lines only. */
- if (!pszWord || strcmp(pszWord, "inet6"))
-@@ -143,11 +165,12 @@
- continue;
- strncpy(aszAddresses[cAddrs++], pszWord, MAX_ADDRLEN-1);
- }
-- pclose(fp);
-+ fclose(fp);
-
- for (int i = 0; i < cAddrs; i++)
- {
-- if (executeIfconfig(pszAdapterName, "inet6", VBOXADPCTL_DEL_CMD, aszAddresses[i]) != EXIT_SUCCESS)
-+ if (executeIfconfig(pszAdapterName, "inet6",
-+ VBOXADPCTL_DEL_CMD, aszAddresses[i]) != EXIT_SUCCESS)
- return false;
- }
-
-@@ -166,19 +189,41 @@
- int rc = ioctl(fd, uCmd, pData);
- if (rc == -1)
- {
-- perror("VBoxNetAdpCtl: ioctl failed for " VBOXNETADP_CTL_DEV_NAME);
-+ perror("VBoxNetAdpCtl: ioctl failed for " VBOXNETADP_CTL_DEV_NAME);
- rc = ADPCTLERR_IOCTL_FAILED;
- }
--
-+
- close(fd);
--
-+
- return rc;
- }
-
-+int checkAdapterName(const char *pcszNameIn, char *pszNameOut)
-+{
-+ int iAdapterIndex = -1;
-+
-+ if ( strlen(pcszNameIn) >= VBOXNETADP_MAX_NAME_LEN
-+ || sscanf(pcszNameIn, "vboxnet%d", &iAdapterIndex) != 1
-+ || iAdapterIndex < 0 || iAdapterIndex > 99 )
-+ {
-+ fprintf(stderr, "Setting configuration for %s is not supported.\n", pcszNameIn);
-+ return ADPCTLERR_BAD_NAME;
-+ }
-+ sprintf(pszNameOut, "vboxnet%d", iAdapterIndex);
-+ if (strcmp(pszNameOut, pcszNameIn))
-+ {
-+ fprintf(stderr, "Invalid adapter name %s.\n", pcszNameIn);
-+ return ADPCTLERR_BAD_NAME;
-+ }
-+
-+ return 0;
-+}
-+
- int main(int argc, char *argv[])
-
- {
-- const char *pszAdapterName;
-+ char szAdapterName[VBOXNETADP_MAX_NAME_LEN];
-+ char *pszAdapterName;
- const char *pszAddress;
- const char *pszNetworkMask = NULL;
- const char *pszOption = NULL;
-@@ -216,13 +261,18 @@
- pszAddress = argv[2];
- if (strcmp("remove", pszAddress) == 0)
- {
-- strncpy(Req.szName, pszAdapterName, sizeof(Req.szName));
-+ rc = checkAdapterName(pszAdapterName, szAdapterName);
-+ if (rc)
-+ return rc;
-+ memset(&Req, '\0', sizeof(Req));
-+ snprintf(Req.szName, sizeof(Req.szName), "%s", szAdapterName);
- return doIOCtl(VBOXNETADP_CTL_REMOVE, &Req);
- }
- break;
- case 2:
- if (strcmp("add", argv[1]) == 0)
- {
-+ memset(&Req, '\0', sizeof(Req));
- rc = doIOCtl(VBOXNETADP_CTL_ADD, &Req);
- if (rc == 0)
- puts(Req.szName);
-@@ -237,11 +287,11 @@
- return 1;
- }
-
-- if (strncmp("vboxnet", pszAdapterName, 7))
-- {
-- fprintf(stderr, "Setting configuration for %s is not supported.\n", pszAdapterName);
-- return 2;
-- }
-+ rc = checkAdapterName(pszAdapterName, szAdapterName);
-+ if (rc)
-+ return rc;
-+
-+ pszAdapterName = szAdapterName;
-
- if (fRemove)
- {
-@@ -276,3 +326,4 @@
- }
- return rc;
- }
-+
diff --git a/emulators/virtualbox-ose-legacy/files/patch-src-settings-vm-VBoxVMSettingsAudio.cpp b/emulators/virtualbox-ose-legacy/files/patch-src-settings-vm-VBoxVMSettingsAudio.cpp
new file mode 100644
index 000000000000..707189e1cac7
--- /dev/null
+++ b/emulators/virtualbox-ose-legacy/files/patch-src-settings-vm-VBoxVMSettingsAudio.cpp
@@ -0,0 +1,12 @@
+--- src/VBox/Frontends/VirtualBox/src/settings/vm/VBoxVMSettingsAudio.cpp.orig 2009-12-17 15:28:01.000000000 +0100
++++ src/VBox/Frontends/VirtualBox/src/settings/vm/VBoxVMSettingsAudio.cpp 2009-12-21 14:14:35.000000000 +0100
+@@ -89,6 +89,9 @@
+ #endif
+ #if defined Q_OS_LINUX || defined Q_OS_FREEBSD
+ mCbAudioDriver->addItem (vboxGlobal().toString (KAudioDriverType_OSS));
++# ifdef VBOX_WITH_PULSE
++ mCbAudioDriver->addItem (vboxGlobal().toString (KAudioDriverType_Pulse));
++# endif
+ #endif
+ #if defined Q_OS_LINUX
+ # ifdef VBOX_WITH_ALSA
diff --git a/emulators/virtualbox-ose-legacy/pkg-message b/emulators/virtualbox-ose-legacy/pkg-message
index 91b8b16427cd..a5c046c48a13 100644
--- a/emulators/virtualbox-ose-legacy/pkg-message
+++ b/emulators/virtualbox-ose-legacy/pkg-message
@@ -2,14 +2,15 @@
VirtualBox was installed.
-You need to load the vboxdrv kernel module and a mounted /proc filesystem.
+You need to load the vboxdrv kernel module via /boot/loader.conf:
-% mount -t procfs proc /proc
-% kldload vboxdrv
+vboxdrv_load="YES"
-For bridged networking you also need to load the vboxnetflt kernel module.
+For bridged networking please add the following line to your /etc/rc.conf:
-% kldload vboxnetflt
+vboxnet_enable="YES"
+
+Reboot the machine to load the needed kernel modules.
You also have to add all users to your vboxusers group in order to use vbox.
diff --git a/emulators/virtualbox-ose-legacy/pkg-plist b/emulators/virtualbox-ose-legacy/pkg-plist
index f8ade22c00a7..797ae3012595 100644
--- a/emulators/virtualbox-ose-legacy/pkg-plist
+++ b/emulators/virtualbox-ose-legacy/pkg-plist
@@ -45,6 +45,7 @@ lib/virtualbox/VBoxXPCOMIPCD
lib/virtualbox/VBoxDD2GC.gc
lib/virtualbox/VBoxDDGC.gc
lib/virtualbox/VMMGC.gc
+lib/virtualbox/tstMicroGC.gc
lib/virtualbox/VBoxDD2R0.r0
lib/virtualbox/VBoxDDR0.r0
%%GUESTADDITIONS%%lib/virtualbox/additions/VBoxGuestAdditions.iso
@@ -60,12 +61,15 @@ lib/virtualbox/components/VBoxXPCOMBase.xpt
%%NLS%%%%DATADIR%%/nls/VirtualBox_bg.qm
%%NLS%%%%DATADIR%%/nls/VirtualBox_ca.qm
%%NLS%%%%DATADIR%%/nls/VirtualBox_cs.qm
+%%NLS%%%%DATADIR%%/nls/VirtualBox_da.qm
%%NLS%%%%DATADIR%%/nls/VirtualBox_de.qm
%%NLS%%%%DATADIR%%/nls/VirtualBox_el.qm
+%%NLS%%%%DATADIR%%/nls/VirtualBox_en.qm
%%NLS%%%%DATADIR%%/nls/VirtualBox_es.qm
%%NLS%%%%DATADIR%%/nls/VirtualBox_eu.qm
%%NLS%%%%DATADIR%%/nls/VirtualBox_fi.qm
%%NLS%%%%DATADIR%%/nls/VirtualBox_fr.qm
+%%NLS%%%%DATADIR%%/nls/VirtualBox_gl_ES.qm
%%NLS%%%%DATADIR%%/nls/VirtualBox_hu.qm
%%NLS%%%%DATADIR%%/nls/VirtualBox_id.qm
%%NLS%%%%DATADIR%%/nls/VirtualBox_it.qm
@@ -89,12 +93,15 @@ lib/virtualbox/components/VBoxXPCOMBase.xpt
%%NLS%%%%DATADIR%%/nls/qt_bg.qm
%%NLS%%%%DATADIR%%/nls/qt_ca.qm
%%NLS%%%%DATADIR%%/nls/qt_cs.qm
+%%NLS%%%%DATADIR%%/nls/qt_da.qm
%%NLS%%%%DATADIR%%/nls/qt_de.qm
%%NLS%%%%DATADIR%%/nls/qt_el.qm
+%%NLS%%%%DATADIR%%/nls/qt_en.qm
%%NLS%%%%DATADIR%%/nls/qt_es.qm
%%NLS%%%%DATADIR%%/nls/qt_eu.qm
%%NLS%%%%DATADIR%%/nls/qt_fi.qm
%%NLS%%%%DATADIR%%/nls/qt_fr.qm
+%%NLS%%%%DATADIR%%/nls/qt_gl_ES.qm
%%NLS%%%%DATADIR%%/nls/qt_hu.qm
%%NLS%%%%DATADIR%%/nls/qt_id.qm
%%NLS%%%%DATADIR%%/nls/qt_it.qm
@@ -593,7 +600,3 @@ include/virtualbox/xpcom/xpcom-config.h
@dirrm lib/virtualbox/components
%%GUESTADDITIONS%%@dirrm lib/virtualbox/additions
@dirrm lib/virtualbox
-@cwd /
-%%KMODDIR%%/vboxdrv.ko
-%%KMODDIR%%/vboxnetadp.ko
-%%KMODDIR%%/vboxnetflt.ko
diff --git a/emulators/virtualbox-ose/Makefile b/emulators/virtualbox-ose/Makefile
index 46617a1b64b8..8b12ae5b785f 100644
--- a/emulators/virtualbox-ose/Makefile
+++ b/emulators/virtualbox-ose/Makefile
@@ -1,21 +1,20 @@
-# New ports collection makefile for: virtualbox
+# New ports collection makefile for: virtualbox-ose
# Date created: 2009-05-02
# Whom: Bernhard Froehlich <decke@bluelife.at>
#
# $FreeBSD$
#
-PORTNAME= virtualbox
-DISTVERSION= 3.0.51r22902
-PORTREVISION= 3
-CATEGORIES= emulators kld
+PORTNAME= virtualbox-ose
+DISTVERSION= 3.1.2
+CATEGORIES= emulators
MASTER_SITES= http://tmp.chruetertee.ch/ \
http://freebsd.unixfreunde.de/sources/ \
http://disasterarea.chruetertee.ch/ \
http://mirror.4bit.ws/ \
http://dlc.sun.com/virtualbox/${VBOX_GUEST_VER}/:guestadditions
-DISTFILES= ${DISTNAME}${EXTRACT_SUFX} ${GADISTFILES}
-EXTRACT_ONLY= ${DISTNAME}${EXTRACT_SUFX}
+DISTFILES= VirtualBox-${DISTVERSION}-OSE${EXTRACT_SUFX} ${GADISTFILES}
+EXTRACT_ONLY= VirtualBox-${DISTVERSION}-OSE${EXTRACT_SUFX}
#for discussion please use emulation@FreeBSD.org
MAINTAINER= vbox@FreeBSD.org
@@ -28,10 +27,11 @@ BUILD_DEPENDS= yasm:${PORTSDIR}/devel/yasm \
LIB_DEPENDS= png.5:${PORTSDIR}/graphics/png \
xslt.2:${PORTSDIR}/textproc/libxslt \
curl.5:${PORTSDIR}/ftp/curl
+RUN_DEPENDS= /boot/modules/vboxdrv.ko:${PORTSDIR}/emulators/virtualbox-ose-kmod
+WRKSRC= ${WRKDIR}/VirtualBox-${PORTVERSION}_OSE
ONLY_FOR_ARCHS= i386 amd64
USE_GNOME= libidl
-USE_CDRTOOLS= yes
USE_BZIP2= yes
USE_PYTHON= yes
USE_PYDISTUTILS= easy_install
@@ -48,7 +48,7 @@ CONFLICTS= bcc-[0-9]*
VBOXGROUP?= vboxusers
VBOXGID?= 920
VBOX_FRONTENDS= VBoxHeadless
-VBOX_GUEST_VER= 3.0.6
+VBOX_GUEST_VER= ${PORTVERSION}
SUB_FILES= pkg-install
@@ -66,12 +66,10 @@ OPTIONS= QT4 "Build with QT4 Frontend" on \
.include <bsd.port.options.mk>
-PLIST_SUB+= KMODDIR=${KMODDIR:C,^/,,} \
- PYTHON_VER=${PYTHON_VER} \
+PLIST_SUB+= PYTHON_VER=${PYTHON_VER} \
PYTHON_VERU=${PYTHON_VER:S/./_/} \
GUEST_VER=${VBOX_GUEST_VER}
-KMODDIR= /boot/modules
KMK_BUILDTYPE= release
KMK_CONFIG= VBOX_LIBPATH_X11=${LOCALBASE} VBOX_FREEBSD_SRC=${SRC_BASE}/sys
KMK_FLAGS=
@@ -130,6 +128,8 @@ CONFIGURE_ARGS+=--disable-dbus
.if !defined(WITH_PULSEAUDIO)
CONFIGURE_ARGS+=--disable-pulse
+.else
+LIB_DEPENDS+= pulse.0:${PORTSDIR}/audio/pulseaudio
.endif
.if !defined(WITHOUT_NLS)
@@ -138,10 +138,6 @@ PLIST_SUB+= NLS=""
PLIST_SUB+= NLS="@comment "
.endif
-.if !exists(${SRC_BASE}/sys/kern/bus_if.m)
-IGNORE= requires kernel sources for the kernel module
-.endif
-
.if ${OSVERSION} < 700000
BROKEN= Does not compile on FreeBSD 6.X
.endif
@@ -172,7 +168,9 @@ post-patch:
@${ECHO} 'VBOX_PATH_APP_PRIVATE = ${DATADIR}' >> ${WRKSRC}/LocalConfig.kmk
@${ECHO} 'VBOX_PATH_APP_DOCS = ${DOCSDIR}' >> ${WRKSRC}/LocalConfig.kmk
@${ECHO} 'VBOX_WITH_INSTALLER = 1' >> ${WRKSRC}/LocalConfig.kmk
- @${ECHO} 'VBOX_WITH_TESTCASES=' >> ${WRKSRC}/LocalConfig.kmk
+ @${ECHO} 'VBOX_WITH_VBOXDRV = ' >> ${WRKSRC}/LocalConfig.kmk
+ @${ECHO} 'VBOX_WITH_NETFLT = 1' >> ${WRKSRC}/LocalConfig.kmk
+ @${ECHO} 'VBOX_WITH_NETADP = ' >> ${WRKSRC}/LocalConfig.kmk
.if defined(WITHOUT_X11)
@${ECHO} 'VBOX_WITH_X11_ADDITIONS=' >> ${WRKSRC}/LocalConfig.kmk
.endif
@@ -191,11 +189,6 @@ do-build:
cd ${WRKSRC} && ${SH} env.sh && ${KMK_CONFIG} ${LOCALBASE}/bin/kmk ${KMK_FLAGS}
do-install:
- ${MKDIR} ${KMODDIR}
-.for f in vboxdrv.ko vboxnetadp.ko vboxnetflt.ko
- ${INSTALL_KLD} ${WRKSRC}/out/${KMK_ARCH}/${KMK_BUILDTYPE}/bin/${f} ${KMODDIR}
-.endfor
-
${MKDIR} ${DATADIR}
(cd ${WRKSRC}/out/${KMK_ARCH}/${KMK_BUILDTYPE}/bin/sdk/bindings/xpcom && ${COPYTREE_SHARE} "idl samples" ${DATADIR})
diff --git a/emulators/virtualbox-ose/distinfo b/emulators/virtualbox-ose/distinfo
index 492de57d1c4a..e1b840762c30 100644
--- a/emulators/virtualbox-ose/distinfo
+++ b/emulators/virtualbox-ose/distinfo
@@ -1,6 +1,6 @@
-MD5 (virtualbox-3.0.51r22902.tar.bz2) = c2fbfd0eca2d2c9e6ad5f029cf75def0
-SHA256 (virtualbox-3.0.51r22902.tar.bz2) = ccbc88276f9e1944005d1c2f3661ec6d7113b22801ecbbb72d422aa0ab2b0a2a
-SIZE (virtualbox-3.0.51r22902.tar.bz2) = 51742256
-MD5 (VBoxGuestAdditions_3.0.6.iso) = 8d033b4f66db1a3e5b914da1717e9c21
-SHA256 (VBoxGuestAdditions_3.0.6.iso) = d6a8b61ef1004637c8be3a70612bb0e101f552d7eb0a9a376ff1ad264baf6a3c
-SIZE (VBoxGuestAdditions_3.0.6.iso) = 32786432
+MD5 (VirtualBox-3.1.2-OSE.tar.bz2) = e7808f16114f5b1a65aa2df1aa33e1a7
+SHA256 (VirtualBox-3.1.2-OSE.tar.bz2) = 293f582e37eda29efdb53c6468481b446e1964592f5728656b74664f4d32f2b1
+SIZE (VirtualBox-3.1.2-OSE.tar.bz2) = 55553394
+MD5 (VBoxGuestAdditions_3.1.2.iso) = d1ac5c53fb889338849134e07a6bc16f
+SHA256 (VBoxGuestAdditions_3.1.2.iso) = 0180a76f011f3992a70e5168d24ce04a08a23fc94858140096a8fa175e742489
+SIZE (VBoxGuestAdditions_3.1.2.iso) = 33337344
diff --git a/emulators/virtualbox-ose/files/patch-configure b/emulators/virtualbox-ose/files/patch-configure
index c6532c3db606..a4aaf507ccc9 100644
--- a/emulators/virtualbox-ose/files/patch-configure
+++ b/emulators/virtualbox-ose/files/patch-configure
@@ -1,15 +1,33 @@
---- configure.orgi 2009-05-31 13:43:50.000000000 +0200
-+++ configure 2009-05-31 13:45:47.000000000 +0200
-@@ -102,7 +102,7 @@
- XSLTPROC="xsltproc"
+--- configure.orig 2009-12-17 15:23:05.000000000 +0100
++++ configure 2009-12-21 14:25:45.000000000 +0100
+@@ -107,7 +107,7 @@
GENISOIMAGE="genisoimage"
MKISOFS="mkisofs"
+ INCCRYPTO=""
-LIBCRYPTO="-lcrypto"
+LIBCRYPTO="-lcrypto -lssl"
LIBPTHREAD="-lpthread"
LIBCAP="-lcap"
GSOAP=""
-@@ -1698,7 +1698,7 @@
+@@ -125,6 +125,8 @@
+ if [ "$OS" = "freebsd" ]; then
+ INCCURL="-I/usr/local/include"
+ LIBCURL="-L/usr/local/lib -lcurl"
++ INCPULSE="-I/usr/local/include"
++ LIBPULSE="-L/usr/local/lib"
+ else
+ INCCURL=""
+ LIBCURL="-lcurl"
+@@ -1181,7 +1183,7 @@
+ #endif
+ }
+ EOF
+- if test_compile "-lpulse" pulse pulse; then
++ if test_compile "$INCPULSE $LIBPULSE -lpulse" pulse pulse; then
+ test_execute
+ fi
+ }
+@@ -1773,7 +1775,7 @@
cat $ODIR.tmp_src.cc >> $LOG
echo "using the following command line:" >> $LOG
echo "$CXX -O -Wall -o $ODIR.tmp_out $ODIR.tmp_src.cc -I$p/include/$d $p/$b/lib$d.so" >> $LOG
@@ -18,3 +36,31 @@
if [ $? -eq 0 ]; then
found=1
break
+@@ -2315,6 +2317,15 @@
+ [ $WITH_QT4 -eq 1 ] && check_qt4
+ [ $WITH_PYTHON -eq 1 ] && check_python
+
++# PulseAudio
++if [ "$OS" = "linux" -o "$OS" = "freebsd" ]; then
++ if [ $WITH_PULSE -eq 1 ]; then
++ check_pulse
++ else
++ cnf_append "VBOX_WITH_PULSE" ""
++ fi
++fi
++
+ # Linux-specific
+ if [ "$OS" = "linux" ]; then
+ # don't check for the static libstdc++ in the PUEL version as we build the
+@@ -2332,11 +2343,6 @@
+ else
+ cnf_append "VBOX_WITH_ALSA" ""
+ fi
+- if [ $WITH_PULSE -eq 1 ]; then
+- check_pulse
+- else
+- cnf_append "VBOX_WITH_PULSE" ""
+- fi
+ if [ $WITH_DBUS -eq 0 ]; then
+ cnf_append "VBOX_WITH_DBUS" ""
+ fi
diff --git a/emulators/virtualbox-ose/files/patch-src-VBox-Additions-x11-VBoxClient-Makefile.kmk b/emulators/virtualbox-ose/files/patch-src-VBox-Additions-x11-VBoxClient-Makefile.kmk
new file mode 100644
index 000000000000..cc5553f7736d
--- /dev/null
+++ b/emulators/virtualbox-ose/files/patch-src-VBox-Additions-x11-VBoxClient-Makefile.kmk
@@ -0,0 +1,20 @@
+Index: src/VBox/Additions/x11/VBoxClient/Makefile.kmk
+===================================================================
+--- src/VBox/Additions/x11/VBoxClient/Makefile.kmk (revision 25472)
++++ src/VBox/Additions/x11/VBoxClient/Makefile.kmk (revision 25473)
+@@ -43,11 +43,14 @@
+ $(VBOX_LIBPATH32_X11)
+ VBoxClient_LIBS.freebsd = \
+ iconv
++VBoxClient_LIBS.linux = \
++ dl
++VBoxClient_LIBS.solaris = \
++ dl
+ VBoxClient_LIBS = \
+ $(VBOX_LIB_IPRT_GUEST_R3) \
+ $(VBOX_LIB_VBGL_R3) \
+ $(VBOX_LIB_IPRT_GUEST_R3) \
+- dl \
+ X11 \
+ Xt
+ # These are static replacements for gcc-specific parts of libstdc++
diff --git a/emulators/virtualbox-ose/files/patch-src-VBox-Devices-Audio-audio.c b/emulators/virtualbox-ose/files/patch-src-VBox-Devices-Audio-audio.c
new file mode 100644
index 000000000000..16a3f8a69f73
--- /dev/null
+++ b/emulators/virtualbox-ose/files/patch-src-VBox-Devices-Audio-audio.c
@@ -0,0 +1,14 @@
+--- src/VBox/Devices/Audio/audio.c.orig 2009-12-15 14:54:13.000000000 +0900
++++ src/VBox/Devices/Audio/audio.c 2009-12-15 14:53:54.000000000 +0900
+@@ -73,6 +73,11 @@
+ &pulse_audio_driver,
+ # endif
+ #endif /* RT_OS_LINUX */
++#ifdef RT_OS_FREEBSD
++# ifdef VBOX_WITH_PULSE
++ &pulse_audio_driver,
++# endif
++#endif
+ #ifdef RT_OS_DARWIN
+ &coreaudio_audio_driver,
+ #endif
diff --git a/emulators/virtualbox-ose/files/patch-src-VBox-Devices-Makefile.kmk b/emulators/virtualbox-ose/files/patch-src-VBox-Devices-Makefile.kmk
index d404c8aee176..b76f318af457 100644
--- a/emulators/virtualbox-ose/files/patch-src-VBox-Devices-Makefile.kmk
+++ b/emulators/virtualbox-ose/files/patch-src-VBox-Devices-Makefile.kmk
@@ -1,15 +1,13 @@
---- src/VBox/Devices/Makefile.kmk.orig 2009-11-01 22:50:39.000000000 +0100
-+++ src/VBox/Devices/Makefile.kmk 2009-11-01 22:50:52.000000000 +0100
-@@ -31,8 +31,10 @@
- include $(PATH_SUB_CURRENT)/PC/VMI/Makefile.kmk
- endif
- include $(PATH_SUB_CURRENT)/Graphics/BIOS/Makefile.kmk
--include $(PATH_SUB_CURRENT)/testcase/Makefile.kmk
--include $(PATH_SUB_CURRENT)/Storage/testcase/Makefile.kmk
-+ifdef VBOX_WITH_TESTCASES
-+ include $(PATH_SUB_CURRENT)/testcase/Makefile.kmk
-+ include $(PATH_SUB_CURRENT)/Storage/testcase/Makefile.kmk
-+endif
- ifndef VBOX_OSE
- include $(PATH_SUB_CURRENT)/Storage/VBoxHDDFormats/Makefile.kmk
+--- src/VBox/Devices/Makefile.kmk.orig 2009-12-17 15:27:43.000000000 +0100
++++ src/VBox/Devices/Makefile.kmk 2009-12-21 14:29:56.000000000 +0100
+@@ -970,6 +970,10 @@
+ Drivers_SOURCES.linux+= \
+ Audio/pulseaudio.c \
+ Audio/pulse_stubs.c
++ Drivers_DEFS.freebsd += VBOX_WITH_PULSE
++ Drivers_SOURCES.freebsd+= \
++ Audio/pulseaudio.c \
++ Audio/pulse_stubs.c
endif
+
+ ifdef VBOX_WITH_USB
diff --git a/emulators/virtualbox-ose/files/patch-src-VBox-Frontends-VBoxManage-VBoxManageHelp.cpp b/emulators/virtualbox-ose/files/patch-src-VBox-Frontends-VBoxManage-VBoxManageHelp.cpp
new file mode 100644
index 000000000000..ffe2a20ceb63
--- /dev/null
+++ b/emulators/virtualbox-ose/files/patch-src-VBox-Frontends-VBoxManage-VBoxManageHelp.cpp
@@ -0,0 +1,37 @@
+--- src/VBox/Frontends/VBoxManage/VBoxManageHelp.cpp.orig 2009-12-15 15:16:21.000000000 +0900
++++ src/VBox/Frontends/VBoxManage/VBoxManageHelp.cpp 2009-12-15 15:14:01.000000000 +0900
+@@ -41,6 +41,11 @@
+ #else
+ bool fSolaris = false;
+ #endif
++#ifdef RT_OS_FREEBSD
++ bool fFreeBSD = true;
++#else
++ bool fFreeBSD = false;
++#endif
+ #ifdef RT_OS_DARWIN
+ bool fDarwin = true;
+ #else
+@@ -62,6 +67,7 @@
+ fLinux = true;
+ fWin = true;
+ fSolaris = true;
++ fFreeBSD = true;
+ fDarwin = true;
+ fVRDP = true;
+ fVBoxSDL = true;
+@@ -227,6 +233,14 @@
+ #endif
+ );
+ }
++ if (fFreeBSD)
++ {
++ RTPrintf( "|oss"
++#ifdef VBOX_WITH_PULSE
++ "|pulse"
++#endif
++ );
++ }
+ if (fDarwin)
+ {
+ RTPrintf( "|coreaudio");
diff --git a/emulators/virtualbox-ose/files/patch-src-VBox-Frontends-VBoxManage-VBoxManageModifyVM.cpp b/emulators/virtualbox-ose/files/patch-src-VBox-Frontends-VBoxManage-VBoxManageModifyVM.cpp
new file mode 100644
index 000000000000..38111c6205d4
--- /dev/null
+++ b/emulators/virtualbox-ose/files/patch-src-VBox-Frontends-VBoxManage-VBoxManageModifyVM.cpp
@@ -0,0 +1,23 @@
+--- src/VBox/Frontends/VBoxManage/VBoxManageModifyVM.cpp.orig 2009-09-09 23:39:46.000000000 +0900
++++ src/VBox/Frontends/VBoxManage/VBoxManageModifyVM.cpp 2009-12-15 15:22:27.000000000 +0900
+@@ -1478,6 +1478,20 @@
+ # endif
+
+ #endif /* !RT_OS_SOLARIS */
++#ifdef RT_OS_FREEBSD
++ else if (!strcmp(ValueUnion.psz, "oss"))
++ {
++ CHECK_ERROR(audioAdapter, COMSETTER(AudioDriver)(AudioDriverType_OSS));
++ CHECK_ERROR(audioAdapter, COMSETTER(Enabled)(true));
++ }
++# ifdef VBOX_WITH_PULSE
++ else if (!strcmp(ValueUnion.psz, "pulse"))
++ {
++ CHECK_ERROR(audioAdapter, COMSETTER(AudioDriver)(AudioDriverType_Pulse));
++ CHECK_ERROR(audioAdapter, COMSETTER(Enabled)(true));
++ }
++# endif
++#endif /* !RT_OS_FREEBSD */
+ #ifdef RT_OS_DARWIN
+ else if (!strcmp(ValueUnion.psz, "coreaudio"))
+ {
diff --git a/emulators/virtualbox-ose/files/patch-src-VBox-HostDrivers-Makefile.kmk b/emulators/virtualbox-ose/files/patch-src-VBox-HostDrivers-Makefile.kmk
new file mode 100644
index 000000000000..5e9024588b8a
--- /dev/null
+++ b/emulators/virtualbox-ose/files/patch-src-VBox-HostDrivers-Makefile.kmk
@@ -0,0 +1,27 @@
+--- src/VBox/HostDrivers/Makefile.kmk.orig 2009-10-05 11:17:45.000000000 +0200
++++ src/VBox/HostDrivers/Makefile.kmk 2009-10-05 11:18:08.000000000 +0200
+@@ -40,7 +40,7 @@
+ endif
+ endif
+
+- if1of ($(KBUILD_TARGET),linux freebsd)
++ if1of ($(KBUILD_TARGET),linux)
+ #
+ # Install the Makefile for module compliation on Linux and FreeBSD hosts
+ #
+@@ -51,6 +51,7 @@
+ HostDrivers-src_SOURCES.freebsd = freebsd/Makefile
+ endif
+
++if 0
+ if1of ($(KBUILD_TARGET),freebsd)
+ #
+ # Install the export_modules script for tar'ing the module sources on FreeBSD hosts
+@@ -60,6 +61,7 @@
+ HostDrivers-sh_MODE = a+rx,u+w
+ HostDrivers-sh_SOURCES.freebsd = freebsd/export_modules
+ endif
++endif
+ endif # !VBOX_ONLY_DOCS
+
+ # Let kBuild generate the rules.
diff --git a/emulators/virtualbox-ose/files/patch-src-VBox-HostDrivers-Support-SUPR3HardenedMain.cpp b/emulators/virtualbox-ose/files/patch-src-VBox-HostDrivers-Support-SUPR3HardenedMain.cpp
new file mode 100644
index 000000000000..4a89fec97dfa
--- /dev/null
+++ b/emulators/virtualbox-ose/files/patch-src-VBox-HostDrivers-Support-SUPR3HardenedMain.cpp
@@ -0,0 +1,33 @@
+--- src/VBox/HostDrivers/Support/SUPR3HardenedMain.cpp (revision 25471)
++++ src/VBox/HostDrivers/Support/SUPR3HardenedMain.cpp (revision 25472)
+@@ -66,6 +66,9 @@
+ # ifndef CAP_TO_MASK
+ # define CAP_TO_MASK(cap) RT_BIT(cap)
+ # endif
++# elif defined(RT_OS_FREEBSD)
++# include <sys/param.h>
++# include <sys/sysctl.h>
+ # elif defined(RT_OS_SOLARIS)
+ # include <priv.h>
+ # endif
+@@ -325,7 +328,19 @@
+ sprintf(szFileBuf, "/proc/%ld/path/a.out", (long)getpid());
+ int cchLink = readlink(szFileBuf, &g_szSupLibHardenedExePath[0], sizeof(g_szSupLibHardenedExePath) - 1);
+ # else /* RT_OS_FREEBSD: */
+- int cchLink = readlink("/proc/curproc/file", &g_szSupLibHardenedExePath[0], sizeof(g_szSupLibHardenedExePath) - 1);
++ int aiName[4];
++ size_t cbPath;
++
++ aiName[0] = CTL_KERN;
++ aiName[1] = KERN_PROC;
++ aiName[2] = KERN_PROC_PATHNAME;
++ aiName[3] = getpid();
++
++ cbPath = sizeof(g_szSupLibHardenedExePath) - 1;
++ if(sysctl(aiName, RT_ELEMENTS(aiName), g_szSupLibHardenedExePath, &cbPath, NULL, 0) < 0)
++ supR3HardenedFatal("supR3HardenedExecDir: sysctl failed\n");
++
++ int cchLink = strlen(g_szSupLibHardenedExePath);
+ # endif
+ if (cchLink < 0 || cchLink == sizeof(g_szSupLibHardenedExePath) - 1)
+ supR3HardenedFatal("supR3HardenedExecDir: couldn't read \"%s\", errno=%d cchLink=%d\n",
diff --git a/emulators/virtualbox-ose/files/patch-src-VBox-HostDrivers-VBoxNetAdp-freebsd-VBoxNetAdp-freebsd.c b/emulators/virtualbox-ose/files/patch-src-VBox-HostDrivers-VBoxNetAdp-freebsd-VBoxNetAdp-freebsd.c
deleted file mode 100644
index 0e223c4b9039..000000000000
--- a/emulators/virtualbox-ose/files/patch-src-VBox-HostDrivers-VBoxNetAdp-freebsd-VBoxNetAdp-freebsd.c
+++ /dev/null
@@ -1,11 +0,0 @@
---- src/VBox/HostDrivers/VBoxNetAdp/freebsd/VBoxNetAdp-freebsd.c.orig 2009-12-07 12:20:44.000000000 +0100
-+++ src/VBox/HostDrivers/VBoxNetAdp/freebsd/VBoxNetAdp-freebsd.c 2009-12-07 12:21:00.000000000 +0100
-@@ -92,7 +92,7 @@
- DECLARE_MODULE(vboxnetadp, g_VBoxNetAdpFreeBSDModule, SI_SUB_PSEUDO, SI_ORDER_ANY);
- MODULE_VERSION(vboxnetadp, 1);
- MODULE_DEPEND(vboxnetadp, vboxdrv, 1, 1, 1);
--MODULE_DEPEND(vboxnetadp, ng_vboxnetflt, 1, 1, 1);
-+MODULE_DEPEND(vboxnetadp, vboxnetflt, 1, 1, 1);
-
- /**
- * Module event handler
diff --git a/emulators/virtualbox-ose/files/patch-src-VBox-HostDrivers-VBoxNetFlt-VBoxNetFltInternal.h b/emulators/virtualbox-ose/files/patch-src-VBox-HostDrivers-VBoxNetFlt-VBoxNetFltInternal.h
deleted file mode 100644
index 250a1960a7f4..000000000000
--- a/emulators/virtualbox-ose/files/patch-src-VBox-HostDrivers-VBoxNetFlt-VBoxNetFltInternal.h
+++ /dev/null
@@ -1,28 +0,0 @@
-Index: src/VBox/HostDrivers/VBoxNetFlt/VBoxNetFltInternal.h
-===================================================================
---- src/VBox/HostDrivers/VBoxNetFlt/VBoxNetFltInternal.h (revision 23391)
-+++ src/VBox/HostDrivers/VBoxNetFlt/VBoxNetFltInternal.h (working copy)
-@@ -206,6 +206,14 @@
- hook_p output;
- /** Original interface flags */
- unsigned int flags;
-+ /** Input queue */
-+ struct ifqueue inq;
-+ /** Output queue */
-+ struct ifqueue outq;
-+ /** Input task */
-+ struct task tskin;
-+ /** Output task */
-+ struct task tskout;
- /** The MAC address of the interface. */
- RTMAC Mac;
- /** @} */
-@@ -241,6 +249,8 @@
- # endif
- #elif defined(RT_OS_LINUX)
- uint8_t abPadding[320];
-+#elif defined(RT_OS_FREEBSD)
-+ uint8_t abPadding[320];
- #else
- uint8_t abPadding[128];
- #endif
diff --git a/emulators/virtualbox-ose/files/patch-src-VBox-HostDrivers-VBoxNetFlt-freebsd-VBoxNetFlt-freebsd.c b/emulators/virtualbox-ose/files/patch-src-VBox-HostDrivers-VBoxNetFlt-freebsd-VBoxNetFlt-freebsd.c
deleted file mode 100644
index f23fedbf0ec0..000000000000
--- a/emulators/virtualbox-ose/files/patch-src-VBox-HostDrivers-VBoxNetFlt-freebsd-VBoxNetFlt-freebsd.c
+++ /dev/null
@@ -1,384 +0,0 @@
-Index: src/VBox/HostDrivers/VBoxNetFlt/freebsd/VBoxNetFlt-freebsd.c
-===================================================================
---- src/VBox/HostDrivers/VBoxNetFlt/freebsd/VBoxNetFlt-freebsd.c (revision 23391)
-+++ src/VBox/HostDrivers/VBoxNetFlt/freebsd/VBoxNetFlt-freebsd.c (working copy)
-@@ -43,6 +43,8 @@
- #include <sys/socket.h>
- #include <sys/sockio.h>
- #include <sys/syscallsubr.h>
-+#include <sys/queue.h>
-+#include <sys/taskqueue.h>
-
- #include <net/if.h>
- #include <net/if_var.h>
-@@ -78,8 +80,6 @@
- static ng_rcvdata_t ng_vboxnetflt_rcvdata;
- static ng_disconnect_t ng_vboxnetflt_disconnect;
- static int ng_vboxnetflt_mod_event(module_t mod, int event, void *data);
--static int ng_vboxnetflt_rcv_in(hook_p node, item_p item);
--static int ng_vboxnetflt_rcv_out(hook_p node, item_p item);
-
- /** Netgraph node type */
- #define NG_VBOXNETFLT_NODE_TYPE "vboxnetflt"
-@@ -112,8 +112,8 @@
- {
- .version = NG_ABI_VERSION,
- .name = NG_VBOXNETFLT_NODE_TYPE,
-- .mod_event = vboxnetflt_modevent,
-- .constructor = ng_vboxnetflt_constructor,
-+ .mod_event = vboxnetflt_modevent,
-+ .constructor = ng_vboxnetflt_constructor,
- .rcvmsg = ng_vboxnetflt_rcvmsg,
- .shutdown = ng_vboxnetflt_shutdown,
- .newhook = ng_vboxnetflt_newhook,
-@@ -122,7 +122,7 @@
- .cmdlist = ng_vboxnetflt_cmdlist,
- };
- NETGRAPH_INIT(vboxnetflt, &ng_vboxnetflt_typestruct);
--MODULE_VERSION(ng_vboxnetflt, 1);
-+MODULE_VERSION(vboxnetflt, 1);
- MODULE_DEPEND(ng_vboxnetflt, vboxdrv, 1, 1, 1);
-
- /**
-@@ -267,16 +267,12 @@
- if (strcmp(name, NG_VBOXNETFLT_HOOK_IN) == 0)
- {
- #if __FreeBSD_version >= 800000
-- NG_HOOK_SET_RCVDATA(hook, ng_vboxnetflt_rcv_in);
- NG_HOOK_SET_TO_INBOUND(hook);
- #endif
- pThis->u.s.input = hook;
- }
- else if (strcmp(name, NG_VBOXNETFLT_HOOK_OUT) == 0)
- {
--#if __FreeBSD_version >= 800000
-- NG_HOOK_SET_RCVDATA(hook, ng_vboxnetflt_rcv_out);
--#endif
- pThis->u.s.output = hook;
- }
- else
-@@ -310,161 +306,171 @@
-
- /**
- * Handle data on netgraph hooks.
-+ * Frames processing is deferred to a taskqueue because this might
-+ * be called with non-sleepable locks held and code paths inside
-+ * the virtual switch might sleep.
- */
- static int ng_vboxnetflt_rcvdata(hook_p hook, item_p item)
- {
- const node_p node = NG_HOOK_NODE(hook);
- PVBOXNETFLTINS pThis = NG_NODE_PRIVATE(node);
-+ struct ifnet *ifp = pThis->u.s.ifp;
- struct mbuf *m;
-+ struct m_tag *mtag;
-+ bool fActive;
-
-+ fActive = ASMAtomicUoReadBool(&pThis->fActive);
-+
-+ NGI_GET_M(item, m);
-+ NG_FREE_ITEM(item);
-+
-+ /* Locate tag to see if processing should be skipped for this frame */
-+ mtag = m_tag_locate(m, MTAG_VBOX, PACKET_TAG_VBOX, NULL);
-+ if (mtag != NULL)
-+ {
-+ m_tag_unlink(m, mtag);
-+ m_tag_free(mtag);
-+ }
-+
-+ /*
-+ * Handle incoming hook. This is connected to the
-+ * input path of the interface, thus handling incoming frames.
-+ */
- if (pThis->u.s.input == hook)
-- return ng_vboxnetflt_rcv_in(hook, item);
-+ {
-+ if (mtag != NULL || !fActive)
-+ {
-+ ether_demux(ifp, m);
-+ return (0);
-+ }
-+ mtx_lock_spin(&pThis->u.s.inq.ifq_mtx);
-+ _IF_ENQUEUE(&pThis->u.s.inq, m);
-+ mtx_unlock_spin(&pThis->u.s.inq.ifq_mtx);
-+ taskqueue_enqueue_fast(taskqueue_fast, &pThis->u.s.tskin);
-+ }
-+ /**
-+ * Handle mbufs on the outgoing hook, frames going to the interface
-+ */
- else if (pThis->u.s.output == hook)
-- return ng_vboxnetflt_rcv_out(hook, item);
-+ {
-+ if (mtag != NULL || !fActive)
-+ return ether_output_frame(ifp, m);
-+ mtx_lock_spin(&pThis->u.s.outq.ifq_mtx);
-+ _IF_ENQUEUE(&pThis->u.s.outq, m);
-+ mtx_unlock_spin(&pThis->u.s.outq.ifq_mtx);
-+ taskqueue_enqueue_fast(taskqueue_fast, &pThis->u.s.tskout);
-+ }
- else
- {
-- NGI_GET_M(item, m);
-- NG_FREE_ITEM(item);
-+ m_freem(m);
- }
- return (0);
- }
-
-+static int ng_vboxnetflt_shutdown(node_p node)
-+{
-+ PVBOXNETFLTINS pThis = NG_NODE_PRIVATE(node);
-+ bool fActive;
-+
-+ /* Prevent node shutdown if we're active */
-+ fActive = ASMAtomicUoReadBool(&pThis->fActive);
-+ if (fActive)
-+ return (EBUSY);
-+ NG_NODE_UNREF(node);
-+ return (0);
-+}
-+
-+static int ng_vboxnetflt_disconnect(hook_p hook)
-+{
-+ return (0);
-+}
-+
- /**
-- * Handle incoming hook. This is connected to the
-- * input path of the interface, thus handling incoming frames.
-+ * Input processing task, handles incoming frames
- */
--static int ng_vboxnetflt_rcv_in(hook_p hook, item_p item)
-+static void vboxNetFltFreeBSDinput(void *arg, int pending)
- {
-+ PVBOXNETFLTINS pThis = (PVBOXNETFLTINS)arg;
- struct mbuf *m, *m0;
-- struct m_tag *mtag;
-- const node_p node = NG_HOOK_NODE(hook);
-- PVBOXNETFLTINS pThis = NG_NODE_PRIVATE(node);
- struct ifnet *ifp = pThis->u.s.ifp;
-- bool fActive, fDropIt = false;
- unsigned int cSegs = 0;
-+ bool fDropIt = false, fActive;
- PINTNETSG pSG;
-
-- NGI_GET_M(item, m);
-- NG_FREE_ITEM(item);
--
-- fActive = ASMAtomicUoReadBool(&pThis->fActive);
-- if (!fActive)
-- goto out;
--
-- mtag = m_tag_locate(m, MTAG_VBOX, PACKET_TAG_VBOX, NULL);
-- if (mtag != NULL)
-- {
-- m_tag_unlink(m, mtag);
-- m_tag_free(mtag);
-- goto out;
-- }
- vboxNetFltRetain(pThis, true /* fBusy */);
--
-- for (m0 = m; m0 != NULL; m0 = m0->m_next)
-+ for (;;)
- {
-- if (m0->m_len > 0)
-- cSegs++;
-- }
-+ mtx_lock_spin(&pThis->u.s.inq.ifq_mtx);
-+ _IF_DEQUEUE(&pThis->u.s.inq, m);
-+ mtx_unlock_spin(&pThis->u.s.inq.ifq_mtx);
-+ if (m == NULL)
-+ break;
-
-+ for (m0 = m; m0 != NULL; m0 = m0->m_next)
-+ if (m0->m_len > 0)
-+ cSegs++;
-+
- #ifdef PADD_RUNT_FRAMES_FROM_HOST
-- if (m_length(m, NULL) < 60)
-- cSegs++;
-+ if (m_length(m, NULL) < 60)
-+ cSegs++;
- #endif
-
-- /* Create a copy of the mbuf and hand it to the virtual switch */
-- pSG = RTMemTmpAlloc(RT_OFFSETOF(INTNETSG, aSegs[cSegs]));
-- vboxNetFltFreeBSDMBufToSG(pThis, m, pSG, cSegs, 0);
-- fDropIt = pThis->pSwitchPort->pfnRecv(pThis->pSwitchPort, pSG, INTNETTRUNKDIR_WIRE);
-- RTMemTmpFree(pSG);
-+ /* Create a copy and deliver to the virtual switch */
-+ pSG = RTMemTmpAlloc(RT_OFFSETOF(INTNETSG, aSegs[cSegs]));
-+ vboxNetFltFreeBSDMBufToSG(pThis, m, pSG, cSegs, 0);
-+ fDropIt = pThis->pSwitchPort->pfnRecv(pThis->pSwitchPort, pSG, INTNETTRUNKDIR_HOST);
-+ RTMemTmpFree(pSG);
-+ if (fDropIt)
-+ m_freem(m);
-+ else
-+ ether_demux(ifp, m);
-+ }
- vboxNetFltRelease(pThis, true /* fBusy */);
--
--out:
-- /* Only deliver it to the host stack if the destination weren't a guest */
-- if (fDropIt)
-- {
-- m_freem(m);
-- return (0);
-- }
-- ether_demux(ifp, m);
-- return (0);
- }
-
- /**
-- * Handle mbufs on the outgoing hook, frames going to the interface
-+ * Output processing task, handles outgoing frames
- */
--static int ng_vboxnetflt_rcv_out(hook_p hook, item_p item)
-+static void vboxNetFltFreeBSDoutput(void *arg, int pending)
- {
-+ PVBOXNETFLTINS pThis = (PVBOXNETFLTINS)arg;
- struct mbuf *m, *m0;
-- struct m_tag *mtag;
-- const node_p node = NG_HOOK_NODE(hook);
-- PVBOXNETFLTINS pThis = NG_NODE_PRIVATE(node);
- struct ifnet *ifp = pThis->u.s.ifp;
- unsigned int cSegs = 0;
- bool fDropIt = false, fActive;
- PINTNETSG pSG;
-
-- NGI_GET_M(item, m);
-- NG_FREE_ITEM(item);
--
-- fActive = ASMAtomicUoReadBool(&pThis->fActive);
-- if (!fActive)
-- return ether_output_frame(ifp, m);
--
- vboxNetFltRetain(pThis, true /* fBusy */);
-- /* Pass directly to interface if the packet originated from us */
-- mtag = m_tag_locate(m, MTAG_VBOX, PACKET_TAG_VBOX, NULL);
-- if (mtag != NULL)
-+ for (;;)
- {
-- m_tag_unlink(m, mtag);
-- m_tag_free(mtag);
-- goto out;
-- }
-+ mtx_lock_spin(&pThis->u.s.outq.ifq_mtx);
-+ _IF_DEQUEUE(&pThis->u.s.outq, m);
-+ mtx_unlock_spin(&pThis->u.s.outq.ifq_mtx);
-+ if (m == NULL)
-+ break;
-
-- for (m0 = m; m0 != NULL; m0 = m0->m_next)
-- {
-- if (m0->m_len > 0)
-- cSegs++;
-- }
-+ for (m0 = m; m0 != NULL; m0 = m0->m_next)
-+ if (m0->m_len > 0)
-+ cSegs++;
-
- #ifdef PADD_RUNT_FRAMES_FROM_HOST
-- if (m_length(m, NULL) < 60)
-- cSegs++;
-+ if (m_length(m, NULL) < 60)
-+ cSegs++;
- #endif
-- /* Create a copy and deliver to the virtual switch */
-- pSG = RTMemTmpAlloc(RT_OFFSETOF(INTNETSG, aSegs[cSegs]));
-- vboxNetFltFreeBSDMBufToSG(pThis, m, pSG, cSegs, 0);
-- fDropIt = pThis->pSwitchPort->pfnRecv(pThis->pSwitchPort, pSG, INTNETTRUNKDIR_HOST);
-- RTMemTmpFree(pSG);
-+ /* Create a copy and deliver to the virtual switch */
-+ pSG = RTMemTmpAlloc(RT_OFFSETOF(INTNETSG, aSegs[cSegs]));
-+ vboxNetFltFreeBSDMBufToSG(pThis, m, pSG, cSegs, 0);
-+ fDropIt = pThis->pSwitchPort->pfnRecv(pThis->pSwitchPort, pSG, INTNETTRUNKDIR_HOST);
-+ RTMemTmpFree(pSG);
-
--out:
-+ if (fDropIt)
-+ m_freem(m);
-+ else
-+ ether_output_frame(ifp, m);
-+ }
- vboxNetFltRelease(pThis, true /* fBusy */);
-- if (fDropIt)
-- {
-- m_freem(m);
-- return (0);
-- }
--
-- return ether_output_frame(ifp, m);
- }
-
--static int ng_vboxnetflt_shutdown(node_p node)
--{
-- PVBOXNETFLTINS pThis = NG_NODE_PRIVATE(node);
-- bool fActive;
--
-- /* Prevent node shutdown if we're active */
-- fActive = ASMAtomicUoReadBool(&pThis->fActive);
-- if (fActive)
-- return (EBUSY);
-- NG_NODE_UNREF(node);
-- return (0);
--}
--
--static int ng_vboxnetflt_disconnect(hook_p hook)
--{
-- return (0);
--}
--
- /**
- * Called to deliver a frame to either the host, the wire or both.
- */
-@@ -536,13 +542,23 @@
-
- /* Create a new netgraph node for this instance */
- if (ng_make_node_common(&ng_vboxnetflt_typestruct, &node) != 0)
-- return VERR_INTERNAL_ERROR;
-+ return VERR_INTERNAL_ERROR;
-
- RTSpinlockAcquire(pThis->hSpinlock, &Tmp);
- ASMAtomicUoWritePtr((void * volatile *)&pThis->u.s.ifp, ifp);
- pThis->u.s.node = node;
- bcopy(IF_LLADDR(ifp), &pThis->u.s.Mac, ETHER_ADDR_LEN);
- ASMAtomicUoWriteBool(&pThis->fDisconnectedFromHost, false);
-+ /* Initialize deferred input queue */
-+ bzero(&pThis->u.s.inq, sizeof(struct ifqueue));
-+ mtx_init(&pThis->u.s.inq.ifq_mtx, "vboxnetflt inq", NULL, MTX_SPIN);
-+ TASK_INIT(&pThis->u.s.tskin, 0, vboxNetFltFreeBSDinput, pThis);
-+
-+ /* Initialize deferred output queue */
-+ bzero(&pThis->u.s.outq, sizeof(struct ifqueue));
-+ mtx_init(&pThis->u.s.outq.ifq_mtx, "vboxnetflt outq", NULL, MTX_SPIN);
-+ TASK_INIT(&pThis->u.s.tskout, 0, vboxNetFltFreeBSDoutput, pThis);
-+
- RTSpinlockRelease(pThis->hSpinlock, &Tmp);
-
- NG_NODE_SET_PRIVATE(node, pThis);
-@@ -571,7 +587,10 @@
- }
-
- if (ifp0 != NULL)
-+ {
-+ vboxNetFltOsDeleteInstance(pThis);
- vboxNetFltOsInitInstance(pThis, NULL);
-+ }
-
- return !ASMAtomicUoReadBool(&pThis->fDisconnectedFromHost);
- }
-@@ -579,6 +598,12 @@
- void vboxNetFltOsDeleteInstance(PVBOXNETFLTINS pThis)
- {
-
-+ taskqueue_drain(taskqueue_fast, &pThis->u.s.tskin);
-+ taskqueue_drain(taskqueue_fast, &pThis->u.s.tskout);
-+
-+ mtx_destroy(&pThis->u.s.inq.ifq_mtx);
-+ mtx_destroy(&pThis->u.s.outq.ifq_mtx);
-+
- if (pThis->u.s.node != NULL)
- ng_rmnode_self(pThis->u.s.node);
- pThis->u.s.node = NULL;
diff --git a/emulators/virtualbox-ose/files/patch-src-VBox-Installer-Makefile.kmk b/emulators/virtualbox-ose/files/patch-src-VBox-Installer-Makefile.kmk
new file mode 100644
index 000000000000..7f226b633c9b
--- /dev/null
+++ b/emulators/virtualbox-ose/files/patch-src-VBox-Installer-Makefile.kmk
@@ -0,0 +1,15 @@
+--- src/VBox/Installer/Makefile.kmk.orig 2009-10-05 14:31:40.000000000 +0200
++++ src/VBox/Installer/Makefile.kmk 2009-10-05 14:32:09.000000000 +0200
+@@ -38,10 +38,12 @@
+ if "$(KBUILD_TARGET)" == "win" && "$(KBUILD_HOST)" == "win"
+ include $(PATH_SUB_CURRENT)/win/Makefile.kmk
+ endif
++if 0
+ if "$(KBUILD_TARGET)" == "freebsd" && "$(KBUILD_HOST)" == "freebsd"
+ include $(PATH_SUB_CURRENT)/freebsd/Makefile.kmk
+ endif
+ endif
++endif
+
+ include $(PATH_SUB_CURRENT)/common/Makefile.kmk
+
diff --git a/emulators/virtualbox-ose/files/patch-src-VBox-Main-AudioAdapterImpl.cpp b/emulators/virtualbox-ose/files/patch-src-VBox-Main-AudioAdapterImpl.cpp
new file mode 100644
index 000000000000..f47f49c97b0e
--- /dev/null
+++ b/emulators/virtualbox-ose/files/patch-src-VBox-Main-AudioAdapterImpl.cpp
@@ -0,0 +1,14 @@
+--- src/VBox/Main/AudioAdapterImpl.cpp.orig 2009-12-15 14:45:08.000000000 +0900
++++ src/VBox/Main/AudioAdapterImpl.cpp 2009-12-15 14:45:42.000000000 +0900
+@@ -261,6 +261,11 @@
+ #if defined (RT_OS_LINUX) || defined (RT_OS_FREEBSD) || defined(VBOX_WITH_SOLARIS_OSS)
+ case AudioDriverType_OSS:
+ #endif
++#ifdef RT_OS_FREEBSD
++# ifdef VBOX_WITH_PULSE
++ case AudioDriverType_Pulse:
++# endif
++#endif
+ #ifdef RT_OS_DARWIN
+ case AudioDriverType_CoreAudio:
+ #endif
diff --git a/emulators/virtualbox-ose/files/patch-src-VBox-Main-ConsoleImpl.cpp b/emulators/virtualbox-ose/files/patch-src-VBox-Main-ConsoleImpl.cpp
new file mode 100644
index 000000000000..cb67a48f5a44
--- /dev/null
+++ b/emulators/virtualbox-ose/files/patch-src-VBox-Main-ConsoleImpl.cpp
@@ -0,0 +1,11 @@
+--- src/VBox/Main/ConsoleImpl.cpp.orig
++++ src/VBox/Main/ConsoleImpl.cpp
+@@ -6168,7 +6168,7 @@ Console::usbDetachCallback(Console *that
+ }
+
+ #endif /* VBOX_WITH_USB */
+-#if (defined(RT_OS_LINUX) || defined(RT_OS_FREEBSD)) && !defined(VBOX_WITH_NETFLT)
++#if ((defined(RT_OS_LINUX) && !defined(VBOX_WITH_NETFLT)) || defined(RT_OS_FREEBSD))
+
+ /**
+ * Helper function to handle host interface device creation and attachment.
diff --git a/emulators/virtualbox-ose/files/patch-src-VBox-Main-ConsoleImpl2.cpp b/emulators/virtualbox-ose/files/patch-src-VBox-Main-ConsoleImpl2.cpp
new file mode 100644
index 000000000000..4373abea3487
--- /dev/null
+++ b/emulators/virtualbox-ose/files/patch-src-VBox-Main-ConsoleImpl2.cpp
@@ -0,0 +1,103 @@
+--- src/VBox/Main/ConsoleImpl2.cpp.orig 2009-12-15 14:48:58.000000000 +0900
++++ src/VBox/Main/ConsoleImpl2.cpp 2009-12-15 14:48:42.000000000 +0900
+@@ -86,6 +86,7 @@
+ # include <sys/ioctl.h>
+ # include <sys/socket.h>
+ # include <net/if.h>
++# include <net80211/ieee80211_ioctl.h>
+ #endif
+
+ #if defined(RT_OS_WINDOWS) && defined(VBOX_WITH_NETFLT)
+@@ -1605,6 +1605,15 @@
+ break;
+ }
+ #endif
++#ifdef RT_OS_FREEBSD
++# ifdef VBOX_WITH_PULSE
++ case AudioDriverType_Pulse:
++ {
++ rc = CFGMR3InsertString(pCfg, "AudioDriver", "pulse"); RC_CHECK();
++ break;
++ }
++# endif
++#endif
+ #ifdef RT_OS_DARWIN
+ case AudioDriverType_CoreAudio:
+ {
+@@ -2394,6 +2394,42 @@ DECLCALLBACK(int) Console::configConstru
+ /* we're not releasing the INetCfg stuff here since we use it later to figure out whether it is wireless */
+
+ # elif defined(RT_OS_LINUX) || defined(RT_OS_FREEBSD)
++# if defined(RT_OS_FREEBSD)
++ /*
++ * If we bridge to a tap interface open it the `old' direct way.
++ * This works and performs better than bridging a physical
++ * interface via the current FreeBSD vboxnetflt implementation.
++ */
++ if (!strncmp(pszHifName, "tap", sizeof "tap" - 1)) {
++ hrc = pThis->attachToTapInterface(aNetworkAdapter);
++ if (FAILED(hrc))
++ {
++ switch (hrc)
++ {
++ case VERR_ACCESS_DENIED:
++ return VMSetError(pVM, VERR_HOSTIF_INIT_FAILED, RT_SRC_POS, N_(
++ "Failed to open '/dev/%s' for read/write access. Please check the "
++ "permissions of that node, and that the net.link.tap.user_open "
++ "sysctl is set. Either run 'chmod 0666 /dev/%s' or "
++ "change the group of that node to vboxusers and make yourself "
++ "a member of that group. Make sure that these changes are permanent."), pszHifName, pszHifName);
++ default:
++ AssertMsgFailed(("Could not attach to tap interface! Bad!\n"));
++ return VMSetError(pVM, VERR_HOSTIF_INIT_FAILED, RT_SRC_POS, N_(
++ "Failed to initialize Host Interface Networking"));
++ }
++ }
++
++ Assert ((int)pThis->maTapFD[uInstance] >= 0);
++ if ((int)pThis->maTapFD[uInstance] >= 0)
++ {
++ rc = CFGMR3InsertString(pLunL0, "Driver", "HostInterface"); RC_CHECK();
++ rc = CFGMR3InsertNode(pLunL0, "Config", &pCfg); RC_CHECK();
++ rc = CFGMR3InsertInteger(pCfg, "FileHandle", pThis->maTapFD[uInstance]); RC_CHECK();
++ }
++ break;
++ }
++# endif
+ /** @todo Check for malformed names. */
+ const char *pszTrunk = pszHifName;
+
+@@ -2495,6 +2496,33 @@ DECLCALLBACK(int) Console::configConstru
+ }
+ else
+ Log(("Failed to open wireless socket\n"));
++# elif defined(RT_OS_FREEBSD)
++ int iSock = socket(AF_INET, SOCK_DGRAM, 0);
++ if (iSock >= 0)
++ {
++ struct ieee80211req ireq;
++ uint8_t data[32];
++
++ (void) memset(&ireq, 0, sizeof(ireq));
++ (void) strncpy(ireq.i_name, pszHifName, sizeof(ireq.i_name));
++ ireq.i_type = IEEE80211_IOC_SSID;
++ ireq.i_val = -1;
++ ireq.i_data = data;
++ ireq.i_len = sizeof(data);
++
++ bool fSharedMacOnWire = ioctl(iSock, SIOCG80211, &ireq) >= 0;
++ close(iSock);
++ if (fSharedMacOnWire)
++ {
++ rc = CFGMR3InsertInteger(pCfg, "SharedMacOnWire", true);
++ RC_CHECK();
++ Log(("Set SharedMacOnWire\n"));
++ }
++ else
++ Log(("Failed to get wireless name\n"));
++ }
++ else
++ Log(("Failed to open wireless socket\n"));
+ # elif defined(RT_OS_WINDOWS)
+ # define DEVNAME_PREFIX L"\\\\.\\"
+ /* we are getting the medium type via IOCTL_NDIS_QUERY_GLOBAL_STATS Io Control
diff --git a/emulators/virtualbox-ose/files/patch-src-VBox-Main-include-ConsoleImpl.h b/emulators/virtualbox-ose/files/patch-src-VBox-Main-include-ConsoleImpl.h
new file mode 100644
index 000000000000..2471480886d8
--- /dev/null
+++ b/emulators/virtualbox-ose/files/patch-src-VBox-Main-include-ConsoleImpl.h
@@ -0,0 +1,20 @@
+--- src/VBox/Main/include/ConsoleImpl.h.orig
++++ src/VBox/Main/include/ConsoleImpl.h
+@@ -410,7 +410,7 @@ private:
+
+ HRESULT callTapSetupApplication(bool isStatic, RTFILE tapFD, Bstr &tapDevice,
+ Bstr &tapSetupApplication);
+-#if (defined(RT_OS_LINUX) || defined(RT_OS_FREEBSD)) && !defined(VBOX_WITH_NETFLT)
++#if ((defined(RT_OS_LINUX) && !defined(VBOX_WITH_NETFLT)) || defined(RT_OS_FREEBSD))
+ HRESULT attachToTapInterface(INetworkAdapter *networkAdapter);
+ HRESULT detachFromTapInterface(INetworkAdapter *networkAdapter);
+ #endif
+@@ -582,7 +582,7 @@ private:
+ PPDMLED mapNetworkLeds[SchemaDefs::NetworkAdapterCount];
+ PPDMLED mapSharedFolderLed;
+ PPDMLED mapUSBLed[2];
+-#if !defined(VBOX_WITH_NETFLT) && (defined(RT_OS_LINUX) || defined(RT_OS_FREEBSD))
++#if ((defined(RT_OS_LINUX) && !defined(VBOX_WITH_NETFLT)) || defined(RT_OS_FREEBSD))
+ Utf8Str maTAPDeviceName[8];
+ RTFILE maTapFD[8];
+ #endif
diff --git a/emulators/virtualbox-ose/files/patch-src-VBox-Runtime-VBox-log-vbox.cpp b/emulators/virtualbox-ose/files/patch-src-VBox-Runtime-VBox-log-vbox.cpp
new file mode 100644
index 000000000000..005a25e4a79a
--- /dev/null
+++ b/emulators/virtualbox-ose/files/patch-src-VBox-Runtime-VBox-log-vbox.cpp
@@ -0,0 +1,82 @@
+--- src/VBox/Runtime/VBox/log-vbox.cpp (revision 25471)
++++ src/VBox/Runtime/VBox/log-vbox.cpp (revision 25472)
+@@ -135,6 +135,12 @@
+ # include <Windows.h>
+ # elif defined(RT_OS_LINUX)
+ # include <unistd.h>
++# elif defined(RT_OS_FREEBSD)
++# include <sys/param.h>
++# include <sys/sysctl.h>
++# include <sys/user.h>
++# include <stdlib.h>
++# include <unistd.h>
+ # elif defined(RT_OS_SOLARIS)
+ # define _STRUCTURED_PROC 1
+ # undef _FILE_OFFSET_BITS /* procfs doesn't like this */
+@@ -157,6 +163,7 @@
+ # include <iprt/path.h>
+ # include <iprt/process.h>
+ # include <iprt/string.h>
++# include <iprt/mem.h>
+ # include <stdio.h>
+ #endif
+
+@@ -339,12 +346,8 @@
+ fclose(pFile);
+ }
+
+-# elif defined(RT_OS_LINUX) || defined(RT_OS_FREEBSD)
+-# ifdef RT_OS_LINUX
++# elif defined(RT_OS_LINUX)
+ FILE *pFile = fopen("/proc/self/cmdline", "r");
+-# else /* RT_OS_FREEBSD: */
+- FILE *pFile = fopen("/proc/curproc/cmdline", "r");
+-# endif
+ if (pFile)
+ {
+ /* braindead */
+@@ -370,7 +373,44 @@
+ RTLogLoggerEx(pLogger, 0, ~0U, "\n");
+ fclose(pFile);
+ }
++# elif defined(RT_OS_FREEBSD)
++ char *pszArgFileBuf = NULL;
++ int aiName[4];
++ size_t cchArgs;
+
++ aiName[0] = CTL_KERN;
++ aiName[1] = KERN_PROC;
++ aiName[2] = KERN_PROC_ARGS;
++ aiName[3] = -1;
++
++ /* Retrieve the required length first */
++ cchArgs = 0;
++ int rcBSD = sysctl(aiName, RT_ELEMENTS(aiName), NULL, &cchArgs, NULL, 0);
++
++ if (cchArgs > 0)
++ {
++ pszArgFileBuf = (char *)RTMemAllocZ(cchArgs + 1 /* Safety */);
++ if (pszArgFileBuf)
++ {
++ /* Retrieve the argument list */
++ rcBSD = sysctl(aiName, RT_ELEMENTS(aiName), pszArgFileBuf, &cchArgs, NULL, 0);
++ if (!rcBSD)
++ {
++ /*
++ * cmdline is a flattened argument list so we need
++ * to convert all \0 to blanks
++ */
++ for(size_t i = 0; i < cchArgs - 1; i++)
++ {
++ if(pszArgFileBuf[i] == '\0')
++ pszArgFileBuf[i] = ' ';
++ }
++
++ RTLogLoggerEx(pLogger, 0, ~0U, "Commandline: %s\n", pszArgFileBuf);
++ }
++ RTMemFree(pszArgFileBuf);
++ }
++ }
+ # elif defined(RT_OS_L4) || defined(RT_OS_OS2) || defined(RT_OS_DARWIN)
+ /* commandline? */
+ # else
diff --git a/emulators/virtualbox-ose/files/patch-src-VBox-Runtime-r0drv-freebsd-spinlock-r0drv-freebsd.c b/emulators/virtualbox-ose/files/patch-src-VBox-Runtime-r0drv-freebsd-spinlock-r0drv-freebsd.c
deleted file mode 100644
index c7c56d5814ee..000000000000
--- a/emulators/virtualbox-ose/files/patch-src-VBox-Runtime-r0drv-freebsd-spinlock-r0drv-freebsd.c
+++ /dev/null
@@ -1,14 +0,0 @@
-Index: src/VBox/Runtime/r0drv/freebsd/spinlock-r0drv-freebsd.c
-@@ -171,7 +171,12 @@ RTDECL(void) RTSpinlockAcquire(RTSPINLOC
- AssertPtr(pThis);
- Assert(pThis->u32Magic == RTSPINLOCK_MAGIC);
- #ifdef RT_STRICT
-+#if 0
-+ /* This can't work because at least RTPowerNotificationRegister calls
-+ * RTSpinlockAcquire with *pTmp allocated on the stack.
-+ */
- Assert(pTmp->uFlags == 0);
-+#endif
- pTmp->uFlags = 42;
- #endif
-
diff --git a/emulators/virtualbox-ose/files/patch-src-VBox-Runtime-r0drv-freebsd-the-freebsd-kernel.h b/emulators/virtualbox-ose/files/patch-src-VBox-Runtime-r0drv-freebsd-the-freebsd-kernel.h
deleted file mode 100644
index 4332049487c3..000000000000
--- a/emulators/virtualbox-ose/files/patch-src-VBox-Runtime-r0drv-freebsd-the-freebsd-kernel.h
+++ /dev/null
@@ -1,11 +0,0 @@
---- src/VBox/Runtime/r0drv/freebsd/the-freebsd-kernel.h.orig 2009-09-11 14:48:47.000000000 +0200
-+++ src/VBox/Runtime/r0drv/freebsd/the-freebsd-kernel.h 2009-09-11 14:48:54.000000000 +0200
-@@ -76,7 +76,7 @@
- # define SLEEPQ_TIMEDWAIT_SIG(EventInt) sleepq_timedwait_sig(EventInt, 0)
- # define SLEEPQ_WAIT(EventInt) sleepq_wait(EventInt, 0)
- # define SLEEPQ_WAIT_SIG(EventInt) sleepq_wait_sig(EventInt, 0)
--#elif
-+#else
- # define SLEEPQ_TIMEDWAIT(EventInt) sleepq_timedwait(EventInt)
- # define SLEEPQ_TIMEDWAIT_SIG(EventInt) sleepq_timedwait_sig(EventInt)
- # define SLEEPQ_WAIT(EventInt) sleepq_wait(EventInt)
diff --git a/emulators/virtualbox-ose/files/patch-src-VBox-Runtime-r3-freebsd-rtProcInitExePath-freebsd.cpp b/emulators/virtualbox-ose/files/patch-src-VBox-Runtime-r3-freebsd-rtProcInitExePath-freebsd.cpp
new file mode 100644
index 000000000000..2332212ead14
--- /dev/null
+++ b/emulators/virtualbox-ose/files/patch-src-VBox-Runtime-r3-freebsd-rtProcInitExePath-freebsd.cpp
@@ -0,0 +1,81 @@
+--- src/VBox/Runtime/r3/freebsd/rtProcInitExePath-freebsd.cpp (revision 25471)
++++ src/VBox/Runtime/r3/freebsd/rtProcInitExePath-freebsd.cpp (revision 25472)
+@@ -32,6 +32,8 @@
+ * Header Files *
+ *******************************************************************************/
+ #define LOG_GROUP RTLOGGROUP_PROCESS
++#include <sys/param.h>
++#include <sys/sysctl.h>
+ #include <unistd.h>
+ #include <errno.h>
+ #include <dlfcn.h>
+@@ -47,17 +49,20 @@
+
+ DECLHIDDEN(int) rtProcInitExePath(char *pszPath, size_t cchPath)
+ {
+- /*
+- * Read the /proc/curproc/file link, convert to native and return it.
+- */
+- int cchLink = readlink("/proc/curproc/file", pszPath, cchPath - 1);
+- if (cchLink > 0 && (size_t)cchLink <= cchPath - 1)
+- {
+- pszPath[cchLink] = '\0';
++ int aiName[4];
++ size_t cchExePath;
+
++ aiName[0] = CTL_KERN;
++ aiName[1] = KERN_PROC;
++ aiName[2] = KERN_PROC_PATHNAME;
++ aiName[3] = getpid();
++
++ cchExePath = cchPath - 1;
++ if(sysctl(aiName, RT_ELEMENTS(aiName), pszPath, &cchExePath, NULL, 0) == 0)
++ {
+ char *pszTmp = NULL;
+ int rc = rtPathFromNative(&pszTmp, pszPath);
+- AssertMsgRCReturn(rc, ("rc=%Rrc pszLink=\"%s\"\nhex: %.*Rhsx\n", rc, pszPath, cchLink, pszPath), rc);
++ AssertMsgRCReturn(rc, ("rc=%Rrc pszLink=\"%s\"\nhex: %.*Rhsx\n", rc, pszPath, cchExePath, pszPath), rc);
+
+ size_t cch = strlen(pszTmp);
+ AssertReturn(cch <= cchPath, VERR_BUFFER_OVERFLOW);
+@@ -68,39 +73,8 @@
+ return VINF_SUCCESS;
+ }
+
+- int err = errno;
+-
+- /*
+- * Fall back on the dynamic linker since /proc is optional.
+- */
+- void *hExe = dlopen(NULL, 0);
+- if (hExe)
+- {
+- struct link_map const *pLinkMap = 0;
+- if (dlinfo(hExe, RTLD_DI_LINKMAP, &pLinkMap) == 0)
+- {
+- const char *pszImageName = pLinkMap->l_name;
+- if (*pszImageName == '/') /* this may not always be absolute, despite the docs. :-( */
+- {
+- char *pszTmp = NULL;
+- int rc = rtPathFromNative(&pszTmp, pszImageName);
+- AssertMsgRCReturn(rc, ("rc=%Rrc pszImageName=\"%s\"\n", rc, pszImageName), rc);
+-
+- size_t cch = strlen(pszTmp);
+- AssertReturn(cch <= cchPath, VERR_BUFFER_OVERFLOW);
+-
+- memcpy(pszPath, pszTmp, cch + 1);
+- RTStrFree(pszTmp);
+-
+- return VINF_SUCCESS;
+- }
+- /** @todo Try search the PATH for the file name or append the current
+- * directory, which ever makes sense... */
+- }
+- }
+-
+- int rc = RTErrConvertFromErrno(err);
+- AssertMsgFailed(("rc=%Rrc err=%d cchLink=%d hExe=%p\n", rc, err, cchLink, hExe));
++ int rc = RTErrConvertFromErrno(errno);
++ AssertMsgFailed(("rc=%Rrc errno=%d cchLink=%d\n", rc, errno, cchExePath));
+ return rc;
+ }
diff --git a/emulators/virtualbox-ose/files/patch-src-VBox-apps-adpctl_VBoxNetAdpCtl.cpp b/emulators/virtualbox-ose/files/patch-src-VBox-apps-adpctl_VBoxNetAdpCtl.cpp
deleted file mode 100644
index 955bf7a3a151..000000000000
--- a/emulators/virtualbox-ose/files/patch-src-VBox-apps-adpctl_VBoxNetAdpCtl.cpp
+++ /dev/null
@@ -1,207 +0,0 @@
---- src/apps/adpctl/VBoxNetAdpCtl.cpp.r22902 2009-04-10 14:03:59.000000000 +0200
-+++ src/apps/adpctl/VBoxNetAdpCtl.cpp 2009-09-16 14:07:11.000000000 +0200
-@@ -1,4 +1,4 @@
--/* $Id: VBoxNetAdpCtl.cpp 18864 2009-04-10 12:03:59Z vboxsync $ */
-+/* $Id: VBoxNetAdpCtl.cpp 23064 2009-09-16 12:07:11Z vboxsync $ */
- /** @file
- * Apps - VBoxAdpCtl, Configuration tool for vboxnetX adapters.
- */
-@@ -24,7 +24,6 @@
- /*******************************************************************************
- * Header Files *
- *******************************************************************************/
--#include <assert.h>
- #include <stdio.h>
- #include <stdlib.h>
- #include <string.h>
-@@ -36,11 +35,12 @@
- # include <sys/ioccom.h>
- #endif
-
--/* @todo Error codes must be moved to some header file */
--#define ADPCTLERR_NO_CTL_DEV 3
--#define ADPCTLERR_IOCTL_FAILED 4
-+/** @todo Error codes must be moved to some header file */
-+#define ADPCTLERR_BAD_NAME 2
-+#define ADPCTLERR_NO_CTL_DEV 3
-+#define ADPCTLERR_IOCTL_FAILED 4
-
--/* @todo These are duplicates from src/VBox/HostDrivers/VBoxNetAdp/VBoxNetAdpInternal.h */
-+/** @todo These are duplicates from src/VBox/HostDrivers/VBoxNetAdp/VBoxNetAdpInternal.h */
- #define VBOXNETADP_CTL_DEV_NAME "/dev/vboxnetctl"
- #define VBOXNETADP_NAME "vboxnet"
- #define VBOXNETADP_MAX_NAME_LEN 32
-@@ -85,6 +85,7 @@
- pcszArg5, /* [network mask] */
- NULL /* terminator */
- };
-+ char * const envp[] = { (char*)"LC_ALL=C", NULL };
- int rc = EXIT_SUCCESS;
- pid_t childPid = fork();
- switch (childPid)
-@@ -94,7 +95,7 @@
- rc = EXIT_FAILURE;
- break;
- case 0: /* Child process. */
-- if (execv(VBOXADPCTL_IFCONFIG_PATH, (char * const*)argv) == -1)
-+ if (execve(VBOXADPCTL_IFCONFIG_PATH, (char * const*)argv, envp) == -1)
- rc = EXIT_FAILURE;
- break;
- default: /* Parent process. */
-@@ -108,15 +109,39 @@
- #define MAX_ADDRESSES 128
- #define MAX_ADDRLEN 64
-
--static bool removeAddresses(const char *pszAdapterName)
-+static bool removeAddresses(char *pszAdapterName)
- {
-- char szCmd[1024], szBuf[1024];
-+ char szBuf[1024];
- char aszAddresses[MAX_ADDRESSES][MAX_ADDRLEN];
-+ int rc;
-+ int fds[2];
-+ char * const argv[] = { VBOXADPCTL_IFCONFIG_PATH, pszAdapterName, NULL };
-+ char * const envp[] = { (char*)"LC_ALL=C", NULL };
-
- memset(aszAddresses, 0, sizeof(aszAddresses));
-- snprintf(szCmd, sizeof(szCmd), VBOXADPCTL_IFCONFIG_PATH " %s", pszAdapterName);
-- FILE *fp = popen(szCmd, "r");
-
-+ rc = pipe(fds);
-+ if (rc < 0)
-+ return false;
-+
-+ pid_t pid = fork();
-+ if (pid < 0)
-+ return false;
-+
-+ if (pid == 0)
-+ {
-+ /* child */
-+ close(fds[0]);
-+ close(STDOUT_FILENO);
-+ rc = dup2(fds[1], STDOUT_FILENO);
-+ if (rc >= 0)
-+ execve(VBOXADPCTL_IFCONFIG_PATH, argv, envp);
-+ return false;
-+ }
-+
-+ /* parent */
-+ close(fds[1]);
-+ FILE *fp = fdopen(fds[0], "r");
- if (!fp)
- return false;
-
-@@ -124,9 +149,6 @@
- for (cAddrs = 0; cAddrs < MAX_ADDRESSES && fgets(szBuf, sizeof(szBuf), fp);)
- {
- int cbSkipWS = strspn(szBuf, " \t");
--#if 0 /* Don't use this! assert() breaks the mac build. Use IPRT or be a rectangular building thing. */
-- assert(cbSkipWS < 20);
--#endif
- char *pszWord = strtok(szBuf + cbSkipWS, " ");
- /* We are concerned with IPv6 address lines only. */
- if (!pszWord || strcmp(pszWord, "inet6"))
-@@ -143,11 +165,12 @@
- continue;
- strncpy(aszAddresses[cAddrs++], pszWord, MAX_ADDRLEN-1);
- }
-- pclose(fp);
-+ fclose(fp);
-
- for (int i = 0; i < cAddrs; i++)
- {
-- if (executeIfconfig(pszAdapterName, "inet6", VBOXADPCTL_DEL_CMD, aszAddresses[i]) != EXIT_SUCCESS)
-+ if (executeIfconfig(pszAdapterName, "inet6",
-+ VBOXADPCTL_DEL_CMD, aszAddresses[i]) != EXIT_SUCCESS)
- return false;
- }
-
-@@ -166,19 +189,41 @@
- int rc = ioctl(fd, uCmd, pData);
- if (rc == -1)
- {
-- perror("VBoxNetAdpCtl: ioctl failed for " VBOXNETADP_CTL_DEV_NAME);
-+ perror("VBoxNetAdpCtl: ioctl failed for " VBOXNETADP_CTL_DEV_NAME);
- rc = ADPCTLERR_IOCTL_FAILED;
- }
--
-+
- close(fd);
--
-+
- return rc;
- }
-
-+int checkAdapterName(const char *pcszNameIn, char *pszNameOut)
-+{
-+ int iAdapterIndex = -1;
-+
-+ if ( strlen(pcszNameIn) >= VBOXNETADP_MAX_NAME_LEN
-+ || sscanf(pcszNameIn, "vboxnet%d", &iAdapterIndex) != 1
-+ || iAdapterIndex < 0 || iAdapterIndex > 99 )
-+ {
-+ fprintf(stderr, "Setting configuration for %s is not supported.\n", pcszNameIn);
-+ return ADPCTLERR_BAD_NAME;
-+ }
-+ sprintf(pszNameOut, "vboxnet%d", iAdapterIndex);
-+ if (strcmp(pszNameOut, pcszNameIn))
-+ {
-+ fprintf(stderr, "Invalid adapter name %s.\n", pcszNameIn);
-+ return ADPCTLERR_BAD_NAME;
-+ }
-+
-+ return 0;
-+}
-+
- int main(int argc, char *argv[])
-
- {
-- const char *pszAdapterName;
-+ char szAdapterName[VBOXNETADP_MAX_NAME_LEN];
-+ char *pszAdapterName;
- const char *pszAddress;
- const char *pszNetworkMask = NULL;
- const char *pszOption = NULL;
-@@ -216,13 +261,18 @@
- pszAddress = argv[2];
- if (strcmp("remove", pszAddress) == 0)
- {
-- strncpy(Req.szName, pszAdapterName, sizeof(Req.szName));
-+ rc = checkAdapterName(pszAdapterName, szAdapterName);
-+ if (rc)
-+ return rc;
-+ memset(&Req, '\0', sizeof(Req));
-+ snprintf(Req.szName, sizeof(Req.szName), "%s", szAdapterName);
- return doIOCtl(VBOXNETADP_CTL_REMOVE, &Req);
- }
- break;
- case 2:
- if (strcmp("add", argv[1]) == 0)
- {
-+ memset(&Req, '\0', sizeof(Req));
- rc = doIOCtl(VBOXNETADP_CTL_ADD, &Req);
- if (rc == 0)
- puts(Req.szName);
-@@ -237,11 +287,11 @@
- return 1;
- }
-
-- if (strncmp("vboxnet", pszAdapterName, 7))
-- {
-- fprintf(stderr, "Setting configuration for %s is not supported.\n", pszAdapterName);
-- return 2;
-- }
-+ rc = checkAdapterName(pszAdapterName, szAdapterName);
-+ if (rc)
-+ return rc;
-+
-+ pszAdapterName = szAdapterName;
-
- if (fRemove)
- {
-@@ -276,3 +326,4 @@
- }
- return rc;
- }
-+
diff --git a/emulators/virtualbox-ose/files/patch-src-settings-vm-VBoxVMSettingsAudio.cpp b/emulators/virtualbox-ose/files/patch-src-settings-vm-VBoxVMSettingsAudio.cpp
new file mode 100644
index 000000000000..707189e1cac7
--- /dev/null
+++ b/emulators/virtualbox-ose/files/patch-src-settings-vm-VBoxVMSettingsAudio.cpp
@@ -0,0 +1,12 @@
+--- src/VBox/Frontends/VirtualBox/src/settings/vm/VBoxVMSettingsAudio.cpp.orig 2009-12-17 15:28:01.000000000 +0100
++++ src/VBox/Frontends/VirtualBox/src/settings/vm/VBoxVMSettingsAudio.cpp 2009-12-21 14:14:35.000000000 +0100
+@@ -89,6 +89,9 @@
+ #endif
+ #if defined Q_OS_LINUX || defined Q_OS_FREEBSD
+ mCbAudioDriver->addItem (vboxGlobal().toString (KAudioDriverType_OSS));
++# ifdef VBOX_WITH_PULSE
++ mCbAudioDriver->addItem (vboxGlobal().toString (KAudioDriverType_Pulse));
++# endif
+ #endif
+ #if defined Q_OS_LINUX
+ # ifdef VBOX_WITH_ALSA
diff --git a/emulators/virtualbox-ose/pkg-message b/emulators/virtualbox-ose/pkg-message
index 91b8b16427cd..a5c046c48a13 100644
--- a/emulators/virtualbox-ose/pkg-message
+++ b/emulators/virtualbox-ose/pkg-message
@@ -2,14 +2,15 @@
VirtualBox was installed.
-You need to load the vboxdrv kernel module and a mounted /proc filesystem.
+You need to load the vboxdrv kernel module via /boot/loader.conf:
-% mount -t procfs proc /proc
-% kldload vboxdrv
+vboxdrv_load="YES"
-For bridged networking you also need to load the vboxnetflt kernel module.
+For bridged networking please add the following line to your /etc/rc.conf:
-% kldload vboxnetflt
+vboxnet_enable="YES"
+
+Reboot the machine to load the needed kernel modules.
You also have to add all users to your vboxusers group in order to use vbox.
diff --git a/emulators/virtualbox-ose/pkg-plist b/emulators/virtualbox-ose/pkg-plist
index f8ade22c00a7..797ae3012595 100644
--- a/emulators/virtualbox-ose/pkg-plist
+++ b/emulators/virtualbox-ose/pkg-plist
@@ -45,6 +45,7 @@ lib/virtualbox/VBoxXPCOMIPCD
lib/virtualbox/VBoxDD2GC.gc
lib/virtualbox/VBoxDDGC.gc
lib/virtualbox/VMMGC.gc
+lib/virtualbox/tstMicroGC.gc
lib/virtualbox/VBoxDD2R0.r0
lib/virtualbox/VBoxDDR0.r0
%%GUESTADDITIONS%%lib/virtualbox/additions/VBoxGuestAdditions.iso
@@ -60,12 +61,15 @@ lib/virtualbox/components/VBoxXPCOMBase.xpt
%%NLS%%%%DATADIR%%/nls/VirtualBox_bg.qm
%%NLS%%%%DATADIR%%/nls/VirtualBox_ca.qm
%%NLS%%%%DATADIR%%/nls/VirtualBox_cs.qm
+%%NLS%%%%DATADIR%%/nls/VirtualBox_da.qm
%%NLS%%%%DATADIR%%/nls/VirtualBox_de.qm
%%NLS%%%%DATADIR%%/nls/VirtualBox_el.qm
+%%NLS%%%%DATADIR%%/nls/VirtualBox_en.qm
%%NLS%%%%DATADIR%%/nls/VirtualBox_es.qm
%%NLS%%%%DATADIR%%/nls/VirtualBox_eu.qm
%%NLS%%%%DATADIR%%/nls/VirtualBox_fi.qm
%%NLS%%%%DATADIR%%/nls/VirtualBox_fr.qm
+%%NLS%%%%DATADIR%%/nls/VirtualBox_gl_ES.qm
%%NLS%%%%DATADIR%%/nls/VirtualBox_hu.qm
%%NLS%%%%DATADIR%%/nls/VirtualBox_id.qm
%%NLS%%%%DATADIR%%/nls/VirtualBox_it.qm
@@ -89,12 +93,15 @@ lib/virtualbox/components/VBoxXPCOMBase.xpt
%%NLS%%%%DATADIR%%/nls/qt_bg.qm
%%NLS%%%%DATADIR%%/nls/qt_ca.qm
%%NLS%%%%DATADIR%%/nls/qt_cs.qm
+%%NLS%%%%DATADIR%%/nls/qt_da.qm
%%NLS%%%%DATADIR%%/nls/qt_de.qm
%%NLS%%%%DATADIR%%/nls/qt_el.qm
+%%NLS%%%%DATADIR%%/nls/qt_en.qm
%%NLS%%%%DATADIR%%/nls/qt_es.qm
%%NLS%%%%DATADIR%%/nls/qt_eu.qm
%%NLS%%%%DATADIR%%/nls/qt_fi.qm
%%NLS%%%%DATADIR%%/nls/qt_fr.qm
+%%NLS%%%%DATADIR%%/nls/qt_gl_ES.qm
%%NLS%%%%DATADIR%%/nls/qt_hu.qm
%%NLS%%%%DATADIR%%/nls/qt_id.qm
%%NLS%%%%DATADIR%%/nls/qt_it.qm
@@ -593,7 +600,3 @@ include/virtualbox/xpcom/xpcom-config.h
@dirrm lib/virtualbox/components
%%GUESTADDITIONS%%@dirrm lib/virtualbox/additions
@dirrm lib/virtualbox
-@cwd /
-%%KMODDIR%%/vboxdrv.ko
-%%KMODDIR%%/vboxnetadp.ko
-%%KMODDIR%%/vboxnetflt.ko
diff --git a/emulators/virtualbox/Makefile b/emulators/virtualbox/Makefile
deleted file mode 100644
index 46617a1b64b8..000000000000
--- a/emulators/virtualbox/Makefile
+++ /dev/null
@@ -1,259 +0,0 @@
-# New ports collection makefile for: virtualbox
-# Date created: 2009-05-02
-# Whom: Bernhard Froehlich <decke@bluelife.at>
-#
-# $FreeBSD$
-#
-
-PORTNAME= virtualbox
-DISTVERSION= 3.0.51r22902
-PORTREVISION= 3
-CATEGORIES= emulators kld
-MASTER_SITES= http://tmp.chruetertee.ch/ \
- http://freebsd.unixfreunde.de/sources/ \
- http://disasterarea.chruetertee.ch/ \
- http://mirror.4bit.ws/ \
- http://dlc.sun.com/virtualbox/${VBOX_GUEST_VER}/:guestadditions
-DISTFILES= ${DISTNAME}${EXTRACT_SUFX} ${GADISTFILES}
-EXTRACT_ONLY= ${DISTNAME}${EXTRACT_SUFX}
-
-#for discussion please use emulation@FreeBSD.org
-MAINTAINER= vbox@FreeBSD.org
-COMMENT= A general-purpose full virtualizer for x86 hardware
-
-BUILD_DEPENDS= yasm:${PORTSDIR}/devel/yasm \
- as86:${PORTSDIR}/devel/dev86 \
- xsltproc:${PORTSDIR}/textproc/libxslt \
- kmk:${PORTSDIR}/devel/kBuild
-LIB_DEPENDS= png.5:${PORTSDIR}/graphics/png \
- xslt.2:${PORTSDIR}/textproc/libxslt \
- curl.5:${PORTSDIR}/ftp/curl
-
-ONLY_FOR_ARCHS= i386 amd64
-USE_GNOME= libidl
-USE_CDRTOOLS= yes
-USE_BZIP2= yes
-USE_PYTHON= yes
-USE_PYDISTUTILS= easy_install
-PYDISTUTILS_PKGNAME= vboxapi
-PYDISTUTILS_PKGVERSION= 1.0
-PYDISTUTILS_NOEGGINFO= yes
-
-HAS_CONFIGURE= yes
-CONFIGURE_ARGS+=--with-gcc="${CC}" --with-g++="${CXX}"
-USE_LDCONFIG= ${PREFIX}/lib/virtualbox
-
-CONFLICTS= bcc-[0-9]*
-
-VBOXGROUP?= vboxusers
-VBOXGID?= 920
-VBOX_FRONTENDS= VBoxHeadless
-VBOX_GUEST_VER= 3.0.6
-
-SUB_FILES= pkg-install
-
-SUB_LIST= PREFIX=${PREFIX} \
- VBOXGROUP=${VBOXGROUP} \
- VBOXGID=${VBOXGID}
-
-OPTIONS= QT4 "Build with QT4 Frontend" on \
- DEBUG "Build with debugging symbols" off \
- GUESTADDITIONS "Build with Guest Additions" off \
- DBUS "Build with D-Bus and HAL support" on \
- PULSEAUDIO "Build with PulseAudio" off \
- X11 "Build with X11 support" on \
- NLS "Native language support" on
-
-.include <bsd.port.options.mk>
-
-PLIST_SUB+= KMODDIR=${KMODDIR:C,^/,,} \
- PYTHON_VER=${PYTHON_VER} \
- PYTHON_VERU=${PYTHON_VER:S/./_/} \
- GUEST_VER=${VBOX_GUEST_VER}
-
-KMODDIR= /boot/modules
-KMK_BUILDTYPE= release
-KMK_CONFIG= VBOX_LIBPATH_X11=${LOCALBASE} VBOX_FREEBSD_SRC=${SRC_BASE}/sys
-KMK_FLAGS=
-
-.if defined(WITHOUT_QT4) && !defined(WITHOUT_NLS)
-BROKEN= NLS support requires QT4 frontend. Run 'make config' again!
-.endif
-
-.if defined(WITHOUT_X11) && !defined(WITHOUT_QT4)
-BROKEN= QT4 frontend requires X11 support. Run 'make config' again!
-.endif
-
-.if !defined(WITHOUT_X11)
-USE_SDL= sdl
-USE_XORG= xcursor xmu
-VBOX_FRONTENDS+=VBoxBFE VBoxSDL VBoxTestOGL
-PLIST_SUB+= X11=""
-.else
-CONFIGURE_ARGS+=--build-headless
-PLIST_SUB+= X11="@comment "
-.endif
-
-.if !defined(WITHOUT_QT4)
-USE_QT_VER= 4
-QT_NONSTANDARD= yes
-QT_COMPONENTS= gui network moc_build uic_build rcc_build linguist
-INSTALLS_ICONS= yes
-VBOX_FRONTENDS+=VirtualBox
-PLIST_SUB+= QT4=""
-.else
-CONFIGURE_ARGS+=--disable-qt4
-PLIST_SUB+= QT4="@comment "
-.endif
-
-.if defined(WITH_GUESTADDITIONS)
-GUESTADDITIONS= VBoxGuestAdditions_${VBOX_GUEST_VER}.iso
-GADISTFILES= ${GUESTADDITIONS}:guestadditions
-RESTRICTED= for personal use only
-RESTRICTED_FILES= ${GUESTADDITIONS}
-FETCH_ARGS= -pRr
-PLIST_SUB+= GUESTADDITIONS=""
-.else
-PLIST_SUB+= GUESTADDITIONS="@comment "
-.endif
-
-.if defined(WITH_DEBUG)
-KMK_FLAGS+= BUILD_TYPE=debug
-KMK_BUILDTYPE= debug
-.endif
-
-.if !defined(WITHOUT_DBUS)
-LIB_DEPENDS+= dbus-1.3:${PORTSDIR}/devel/dbus
-.else
-CONFIGURE_ARGS+=--disable-dbus
-.endif
-
-.if !defined(WITH_PULSEAUDIO)
-CONFIGURE_ARGS+=--disable-pulse
-.endif
-
-.if !defined(WITHOUT_NLS)
-PLIST_SUB+= NLS=""
-.else
-PLIST_SUB+= NLS="@comment "
-.endif
-
-.if !exists(${SRC_BASE}/sys/kern/bus_if.m)
-IGNORE= requires kernel sources for the kernel module
-.endif
-
-.if ${OSVERSION} < 700000
-BROKEN= Does not compile on FreeBSD 6.X
-.endif
-
-.if ${ARCH} == i386
-KMK_ARCH= freebsd.x86
-PLIST_SUB+= I386=""
-.else
-KMK_ARCH= freebsd.${ARCH}
-PLIST_SUB+= I386="@comment "
-.endif
-
-.include <bsd.port.pre.mk>
-
-pre-everything::
-.if ${ARCH} == "amd64"
-.if !exists(/usr/lib32)
- @${ECHO} 'Requires 32-bit libraries installed under /usr/lib32.'
- @${ECHO} 'Do: cd /usr/src; make build32 install32; ldconfig -v -m -R /usr/lib32'
- @${FALSE}
-.endif
-.endif
-
-post-patch:
- @${ECHO} 'VBOX_PATH_APP_PRIVATE_ARCH = ${PREFIX}/lib/virtualbox' > ${WRKSRC}/LocalConfig.kmk
- @${ECHO} 'VBOX_PATH_SHARED_LIBS = ${PREFIX}/lib/virtualbox' >> ${WRKSRC}/LocalConfig.kmk
- @${ECHO} 'VBOX_WITH_RUNPATH = ${PREFIX}/lib/virtualbox' >> ${WRKSRC}/LocalConfig.kmk
- @${ECHO} 'VBOX_PATH_APP_PRIVATE = ${DATADIR}' >> ${WRKSRC}/LocalConfig.kmk
- @${ECHO} 'VBOX_PATH_APP_DOCS = ${DOCSDIR}' >> ${WRKSRC}/LocalConfig.kmk
- @${ECHO} 'VBOX_WITH_INSTALLER = 1' >> ${WRKSRC}/LocalConfig.kmk
- @${ECHO} 'VBOX_WITH_TESTCASES=' >> ${WRKSRC}/LocalConfig.kmk
-.if defined(WITHOUT_X11)
- @${ECHO} 'VBOX_WITH_X11_ADDITIONS=' >> ${WRKSRC}/LocalConfig.kmk
-.endif
- @${REINPLACE_CMD} -e 's|/usr/local|${LOCALBASE}|g' \
- ${WRKSRC}/Config.kmk ${WRKSRC}/configure \
- ${WRKSRC}/kBuild/units/qt3.kmk ${WRKSRC}/kBuild/units/qt4.kmk \
- ${WRKSRC}/kBuild/sdks/LIBSDL.kmk \
- ${WRKSRC}/src/libs/xpcom18a4/python/gen_python_deps.py
- @${REINPLACE_CMD} -e 's|\$$KBUILDDIR_BIN/kmk_sed|${PREFIX}/bin/kmk_sed|g' ${WRKSRC}/configure
-
-pre-build:
- @${REINPLACE_CMD} -e 's|/bin/bash|/bin/sh|' \
- ${WRKSRC}/env.sh
-
-do-build:
- cd ${WRKSRC} && ${SH} env.sh && ${KMK_CONFIG} ${LOCALBASE}/bin/kmk ${KMK_FLAGS}
-
-do-install:
- ${MKDIR} ${KMODDIR}
-.for f in vboxdrv.ko vboxnetadp.ko vboxnetflt.ko
- ${INSTALL_KLD} ${WRKSRC}/out/${KMK_ARCH}/${KMK_BUILDTYPE}/bin/${f} ${KMODDIR}
-.endfor
-
- ${MKDIR} ${DATADIR}
- (cd ${WRKSRC}/out/${KMK_ARCH}/${KMK_BUILDTYPE}/bin/sdk/bindings/xpcom && ${COPYTREE_SHARE} "idl samples" ${DATADIR})
-
- ${MKDIR} ${PREFIX}/include/virtualbox
- (cd ${WRKSRC}/out/${KMK_ARCH}/${KMK_BUILDTYPE}/bin/sdk/bindings/xpcom/include && ${COPYTREE_SHARE} "*" ${PREFIX}/include/virtualbox)
-
- ${MKDIR} ${PREFIX}/lib/virtualbox
- (cd ${WRKSRC}/out/${KMK_ARCH}/${KMK_BUILDTYPE}/bin && ${COPYTREE_SHARE} "*.so *.gc *.r0 components" ${PREFIX}/lib/virtualbox)
-
-.if !defined(WITHOUT_NLS)
- ${MKDIR} ${DATADIR}/nls
- (cd ${WRKSRC}/out/${KMK_ARCH}/${KMK_BUILDTYPE}/obj/VirtualBox/qtnls && ${COPYTREE_SHARE} "*.qm" ${DATADIR}/nls)
-.endif
-
- ${MKDIR} ${PREFIX}/bin
-.for f in VBoxManage VBoxNetAdpCtl VBoxNetDHCP VBoxSVC VBoxXPCOMIPCD ${VBOX_FRONTENDS}
- ${INSTALL_PROGRAM} ${WRKSRC}/out/${KMK_ARCH}/${KMK_BUILDTYPE}/bin/${f} ${PREFIX}/lib/virtualbox/
- ${LN} -sf ${PREFIX}/lib/virtualbox/${f} ${PREFIX}/bin/
-.endfor
-
-.for f in VBoxNetAdpCtl VBoxNetDHCP ${VBOX_FRONTENDS}
- ${CHMOD} 4511 ${PREFIX}/lib/virtualbox/${f}
-.endfor
-
-.for f in VBoxManage VBoxSVC VBoxXPCOMIPCD
- ${CHMOD} 0711 ${PREFIX}/lib/virtualbox/${f}
-.endfor
-
-.if defined(WITH_GUESTADDITIONS)
- ${MKDIR} ${PREFIX}/lib/virtualbox/additions
- ${INSTALL_DATA} ${DISTDIR}/${GUESTADDITIONS} ${PREFIX}/lib/virtualbox/additions/
- ${LN} -sf ${PREFIX}/lib/virtualbox/additions/${GUESTADDITIONS} ${PREFIX}/lib/virtualbox/additions/VBoxGuestAdditions.iso
-.endif
-
- cd ${WRKSRC}/out/${KMK_ARCH}/${KMK_BUILDTYPE}/bin/sdk/installer && \
- VBOX_INSTALL_PATH="${PREFIX}/lib/virtualbox" ${PYTHON_CMD} vboxapisetup.py install
-
- @${MKDIR} ${PYTHON_SITELIBDIR}
- (cd ${WRKSRC}/out/${KMK_ARCH}/${KMK_BUILDTYPE}/bin/sdk/bindings/xpcom/python && ${COPYTREE_SHARE} "*" ${PYTHON_SITELIBDIR})
- ${PYTHON_CMD} -mcompileall ${PYTHON_SITELIBDIR}/xpcom/
-
-post-install:
- @${SETENV} ${SH} ${PKGINSTALL} ${PKGNAME} POST-INSTALL
-
-.for f in VBoxManage VBoxNetDHCP VBoxSVC VBoxXPCOMIPCD ${VBOX_FRONTENDS}
- ${CHOWN} root:${VBOXGROUP} ${PREFIX}/lib/virtualbox/${f}
-.endfor
-
- @${FIND} ${DATADIR} -type d -print0 | ${XARGS} -0 ${CHMOD} 755
- @${FIND} ${PREFIX}/include/virtualbox -type d -print0 | ${XARGS} -0 ${CHMOD} 755
- @${FIND} ${PREFIX}/lib/virtualbox -type d -print0 | ${XARGS} -0 ${CHMOD} 755
-
-.if !defined(WITHOUT_QT4)
- ${MKDIR} ${PREFIX}/share/icons/hicolor/48x48/apps/
- ${INSTALL_DATA} ${WRKSRC}/src/VBox/Frontends/VirtualBox/images/OSE/VirtualBox_48px.png ${PREFIX}/share/icons/hicolor/48x48/apps/VBox.png
- ${MKDIR} ${PREFIX}/share/applications/
- ${INSTALL_DATA} ${WRKSRC}/src/VBox/Installer/solaris/virtualbox.desktop ${PREFIX}/share/applications/virtualbox.desktop
-.endif
- @${CAT} ${PKGMESSAGE}
-
-.include <bsd.port.post.mk>
diff --git a/emulators/virtualbox/distinfo b/emulators/virtualbox/distinfo
deleted file mode 100644
index 492de57d1c4a..000000000000
--- a/emulators/virtualbox/distinfo
+++ /dev/null
@@ -1,6 +0,0 @@
-MD5 (virtualbox-3.0.51r22902.tar.bz2) = c2fbfd0eca2d2c9e6ad5f029cf75def0
-SHA256 (virtualbox-3.0.51r22902.tar.bz2) = ccbc88276f9e1944005d1c2f3661ec6d7113b22801ecbbb72d422aa0ab2b0a2a
-SIZE (virtualbox-3.0.51r22902.tar.bz2) = 51742256
-MD5 (VBoxGuestAdditions_3.0.6.iso) = 8d033b4f66db1a3e5b914da1717e9c21
-SHA256 (VBoxGuestAdditions_3.0.6.iso) = d6a8b61ef1004637c8be3a70612bb0e101f552d7eb0a9a376ff1ad264baf6a3c
-SIZE (VBoxGuestAdditions_3.0.6.iso) = 32786432
diff --git a/emulators/virtualbox/files/patch-Config.kmk b/emulators/virtualbox/files/patch-Config.kmk
deleted file mode 100644
index 2ce55eb8a12d..000000000000
--- a/emulators/virtualbox/files/patch-Config.kmk
+++ /dev/null
@@ -1,10 +0,0 @@
---- Config.kmk.bak 2009-09-02 18:34:01.000000000 +0200
-+++ Config.kmk 2009-09-02 19:19:09.000000000 +0200
-@@ -781,6 +781,7 @@
- VBOX_WITH_VBOXBFE=
- VBOX_WITH_OGL=
- VBOX_WITH_KCHMVIEWER=
-+ VBOX_WITH_HGSMI=
- endif
-
- #
diff --git a/emulators/virtualbox/files/patch-configure b/emulators/virtualbox/files/patch-configure
deleted file mode 100644
index c6532c3db606..000000000000
--- a/emulators/virtualbox/files/patch-configure
+++ /dev/null
@@ -1,20 +0,0 @@
---- configure.orgi 2009-05-31 13:43:50.000000000 +0200
-+++ configure 2009-05-31 13:45:47.000000000 +0200
-@@ -102,7 +102,7 @@
- XSLTPROC="xsltproc"
- GENISOIMAGE="genisoimage"
- MKISOFS="mkisofs"
--LIBCRYPTO="-lcrypto"
-+LIBCRYPTO="-lcrypto -lssl"
- LIBPTHREAD="-lpthread"
- LIBCAP="-lcap"
- GSOAP=""
-@@ -1698,7 +1698,7 @@
- cat $ODIR.tmp_src.cc >> $LOG
- echo "using the following command line:" >> $LOG
- echo "$CXX -O -Wall -o $ODIR.tmp_out $ODIR.tmp_src.cc -I$p/include/$d $p/$b/lib$d.so" >> $LOG
-- $CXX -O -Wall -o $ODIR.tmp_out $ODIR.tmp_src.cc -I$p/include/$d $p/$b/lib$d.so >> $LOG 2>&1
-+ $CXX -O -Wall -o $ODIR.tmp_out $ODIR.tmp_src.cc -I$p/include/$d $p/$b/lib$d.so -pthread >> $LOG 2>&1
- if [ $? -eq 0 ]; then
- found=1
- break
diff --git a/emulators/virtualbox/files/patch-src-VBox-Devices-Makefile.kmk b/emulators/virtualbox/files/patch-src-VBox-Devices-Makefile.kmk
deleted file mode 100644
index d404c8aee176..000000000000
--- a/emulators/virtualbox/files/patch-src-VBox-Devices-Makefile.kmk
+++ /dev/null
@@ -1,15 +0,0 @@
---- src/VBox/Devices/Makefile.kmk.orig 2009-11-01 22:50:39.000000000 +0100
-+++ src/VBox/Devices/Makefile.kmk 2009-11-01 22:50:52.000000000 +0100
-@@ -31,8 +31,10 @@
- include $(PATH_SUB_CURRENT)/PC/VMI/Makefile.kmk
- endif
- include $(PATH_SUB_CURRENT)/Graphics/BIOS/Makefile.kmk
--include $(PATH_SUB_CURRENT)/testcase/Makefile.kmk
--include $(PATH_SUB_CURRENT)/Storage/testcase/Makefile.kmk
-+ifdef VBOX_WITH_TESTCASES
-+ include $(PATH_SUB_CURRENT)/testcase/Makefile.kmk
-+ include $(PATH_SUB_CURRENT)/Storage/testcase/Makefile.kmk
-+endif
- ifndef VBOX_OSE
- include $(PATH_SUB_CURRENT)/Storage/VBoxHDDFormats/Makefile.kmk
- endif
diff --git a/emulators/virtualbox/files/patch-src-VBox-Frontends-VBoxManage-VBoxInternalManage.cpp b/emulators/virtualbox/files/patch-src-VBox-Frontends-VBoxManage-VBoxInternalManage.cpp
deleted file mode 100644
index 0a1f735fb79a..000000000000
--- a/emulators/virtualbox/files/patch-src-VBox-Frontends-VBoxManage-VBoxInternalManage.cpp
+++ /dev/null
@@ -1,50 +0,0 @@
-Index: src/VBox/Frontends/VBoxManage/VBoxInternalManage.cpp
-@@ -54,7 +54,8 @@
- #ifdef RT_OS_WINDOWS
- # include <windows.h>
- # include <winioctl.h>
--#elif defined(RT_OS_LINUX) || defined(RT_OS_DARWIN) || defined(RT_OS_SOLARIS)
-+#elif defined(RT_OS_LINUX) || defined(RT_OS_DARWIN) \
-+ || defined(RT_OS_SOLARIS) || defined(RT_OS_FREEBSD)
- # include <errno.h>
- # include <sys/ioctl.h>
- # include <sys/types.h>
-@@ -76,6 +77,9 @@
- # include <sys/dkio.h>
- # include <sys/vtoc.h>
- #endif /* RT_OS_SOLARIS */
-+#ifdef RT_OS_FREEBSD
-+# include <sys/disk.h>
-+#endif /* RT_OS_FREEBSD */
-
- using namespace com;
-
-@@ -1013,6 +1017,28 @@
- vrc = VERR_INVALID_PARAMETER;
- goto out;
- }
-+#elif defined(RT_OS_FREEBSD)
-+ struct stat DevStat;
-+ if (!fstat(RawFile, &DevStat) && S_ISCHR(DevStat.st_mode))
-+ {
-+ off_t cMediasize = 0;
-+ if (!ioctl(RawFile, DIOCGMEDIASIZE, &cMediasize))
-+ {
-+ cbSize = cMediasize;
-+ }
-+ else
-+ {
-+ vrc = RTErrConvertFromErrno(errno);
-+ RTPrintf("Cannot get the block count for file '%s': %Rrc", rawdisk.raw(), vrc);
-+ goto out;
-+ }
-+ }
-+ else
-+ {
-+ RTPrintf("File '%s' is no character device\n", rawdisk.raw());
-+ vrc = VERR_INVALID_PARAMETER;
-+ goto out;
-+ }
- #else /* all unrecognized OSes */
- /* Hopefully this works on all other hosts. If it doesn't, it'll just fail
- * creating the VMDK, so no real harm done. */
diff --git a/emulators/virtualbox/files/patch-src-VBox-HostDrivers-VBoxNetAdp-freebsd-VBoxNetAdp-freebsd.c b/emulators/virtualbox/files/patch-src-VBox-HostDrivers-VBoxNetAdp-freebsd-VBoxNetAdp-freebsd.c
deleted file mode 100644
index 0e223c4b9039..000000000000
--- a/emulators/virtualbox/files/patch-src-VBox-HostDrivers-VBoxNetAdp-freebsd-VBoxNetAdp-freebsd.c
+++ /dev/null
@@ -1,11 +0,0 @@
---- src/VBox/HostDrivers/VBoxNetAdp/freebsd/VBoxNetAdp-freebsd.c.orig 2009-12-07 12:20:44.000000000 +0100
-+++ src/VBox/HostDrivers/VBoxNetAdp/freebsd/VBoxNetAdp-freebsd.c 2009-12-07 12:21:00.000000000 +0100
-@@ -92,7 +92,7 @@
- DECLARE_MODULE(vboxnetadp, g_VBoxNetAdpFreeBSDModule, SI_SUB_PSEUDO, SI_ORDER_ANY);
- MODULE_VERSION(vboxnetadp, 1);
- MODULE_DEPEND(vboxnetadp, vboxdrv, 1, 1, 1);
--MODULE_DEPEND(vboxnetadp, ng_vboxnetflt, 1, 1, 1);
-+MODULE_DEPEND(vboxnetadp, vboxnetflt, 1, 1, 1);
-
- /**
- * Module event handler
diff --git a/emulators/virtualbox/files/patch-src-VBox-HostDrivers-VBoxNetFlt-VBoxNetFltInternal.h b/emulators/virtualbox/files/patch-src-VBox-HostDrivers-VBoxNetFlt-VBoxNetFltInternal.h
deleted file mode 100644
index 250a1960a7f4..000000000000
--- a/emulators/virtualbox/files/patch-src-VBox-HostDrivers-VBoxNetFlt-VBoxNetFltInternal.h
+++ /dev/null
@@ -1,28 +0,0 @@
-Index: src/VBox/HostDrivers/VBoxNetFlt/VBoxNetFltInternal.h
-===================================================================
---- src/VBox/HostDrivers/VBoxNetFlt/VBoxNetFltInternal.h (revision 23391)
-+++ src/VBox/HostDrivers/VBoxNetFlt/VBoxNetFltInternal.h (working copy)
-@@ -206,6 +206,14 @@
- hook_p output;
- /** Original interface flags */
- unsigned int flags;
-+ /** Input queue */
-+ struct ifqueue inq;
-+ /** Output queue */
-+ struct ifqueue outq;
-+ /** Input task */
-+ struct task tskin;
-+ /** Output task */
-+ struct task tskout;
- /** The MAC address of the interface. */
- RTMAC Mac;
- /** @} */
-@@ -241,6 +249,8 @@
- # endif
- #elif defined(RT_OS_LINUX)
- uint8_t abPadding[320];
-+#elif defined(RT_OS_FREEBSD)
-+ uint8_t abPadding[320];
- #else
- uint8_t abPadding[128];
- #endif
diff --git a/emulators/virtualbox/files/patch-src-VBox-HostDrivers-VBoxNetFlt-freebsd-VBoxNetFlt-freebsd.c b/emulators/virtualbox/files/patch-src-VBox-HostDrivers-VBoxNetFlt-freebsd-VBoxNetFlt-freebsd.c
deleted file mode 100644
index f23fedbf0ec0..000000000000
--- a/emulators/virtualbox/files/patch-src-VBox-HostDrivers-VBoxNetFlt-freebsd-VBoxNetFlt-freebsd.c
+++ /dev/null
@@ -1,384 +0,0 @@
-Index: src/VBox/HostDrivers/VBoxNetFlt/freebsd/VBoxNetFlt-freebsd.c
-===================================================================
---- src/VBox/HostDrivers/VBoxNetFlt/freebsd/VBoxNetFlt-freebsd.c (revision 23391)
-+++ src/VBox/HostDrivers/VBoxNetFlt/freebsd/VBoxNetFlt-freebsd.c (working copy)
-@@ -43,6 +43,8 @@
- #include <sys/socket.h>
- #include <sys/sockio.h>
- #include <sys/syscallsubr.h>
-+#include <sys/queue.h>
-+#include <sys/taskqueue.h>
-
- #include <net/if.h>
- #include <net/if_var.h>
-@@ -78,8 +80,6 @@
- static ng_rcvdata_t ng_vboxnetflt_rcvdata;
- static ng_disconnect_t ng_vboxnetflt_disconnect;
- static int ng_vboxnetflt_mod_event(module_t mod, int event, void *data);
--static int ng_vboxnetflt_rcv_in(hook_p node, item_p item);
--static int ng_vboxnetflt_rcv_out(hook_p node, item_p item);
-
- /** Netgraph node type */
- #define NG_VBOXNETFLT_NODE_TYPE "vboxnetflt"
-@@ -112,8 +112,8 @@
- {
- .version = NG_ABI_VERSION,
- .name = NG_VBOXNETFLT_NODE_TYPE,
-- .mod_event = vboxnetflt_modevent,
-- .constructor = ng_vboxnetflt_constructor,
-+ .mod_event = vboxnetflt_modevent,
-+ .constructor = ng_vboxnetflt_constructor,
- .rcvmsg = ng_vboxnetflt_rcvmsg,
- .shutdown = ng_vboxnetflt_shutdown,
- .newhook = ng_vboxnetflt_newhook,
-@@ -122,7 +122,7 @@
- .cmdlist = ng_vboxnetflt_cmdlist,
- };
- NETGRAPH_INIT(vboxnetflt, &ng_vboxnetflt_typestruct);
--MODULE_VERSION(ng_vboxnetflt, 1);
-+MODULE_VERSION(vboxnetflt, 1);
- MODULE_DEPEND(ng_vboxnetflt, vboxdrv, 1, 1, 1);
-
- /**
-@@ -267,16 +267,12 @@
- if (strcmp(name, NG_VBOXNETFLT_HOOK_IN) == 0)
- {
- #if __FreeBSD_version >= 800000
-- NG_HOOK_SET_RCVDATA(hook, ng_vboxnetflt_rcv_in);
- NG_HOOK_SET_TO_INBOUND(hook);
- #endif
- pThis->u.s.input = hook;
- }
- else if (strcmp(name, NG_VBOXNETFLT_HOOK_OUT) == 0)
- {
--#if __FreeBSD_version >= 800000
-- NG_HOOK_SET_RCVDATA(hook, ng_vboxnetflt_rcv_out);
--#endif
- pThis->u.s.output = hook;
- }
- else
-@@ -310,161 +306,171 @@
-
- /**
- * Handle data on netgraph hooks.
-+ * Frames processing is deferred to a taskqueue because this might
-+ * be called with non-sleepable locks held and code paths inside
-+ * the virtual switch might sleep.
- */
- static int ng_vboxnetflt_rcvdata(hook_p hook, item_p item)
- {
- const node_p node = NG_HOOK_NODE(hook);
- PVBOXNETFLTINS pThis = NG_NODE_PRIVATE(node);
-+ struct ifnet *ifp = pThis->u.s.ifp;
- struct mbuf *m;
-+ struct m_tag *mtag;
-+ bool fActive;
-
-+ fActive = ASMAtomicUoReadBool(&pThis->fActive);
-+
-+ NGI_GET_M(item, m);
-+ NG_FREE_ITEM(item);
-+
-+ /* Locate tag to see if processing should be skipped for this frame */
-+ mtag = m_tag_locate(m, MTAG_VBOX, PACKET_TAG_VBOX, NULL);
-+ if (mtag != NULL)
-+ {
-+ m_tag_unlink(m, mtag);
-+ m_tag_free(mtag);
-+ }
-+
-+ /*
-+ * Handle incoming hook. This is connected to the
-+ * input path of the interface, thus handling incoming frames.
-+ */
- if (pThis->u.s.input == hook)
-- return ng_vboxnetflt_rcv_in(hook, item);
-+ {
-+ if (mtag != NULL || !fActive)
-+ {
-+ ether_demux(ifp, m);
-+ return (0);
-+ }
-+ mtx_lock_spin(&pThis->u.s.inq.ifq_mtx);
-+ _IF_ENQUEUE(&pThis->u.s.inq, m);
-+ mtx_unlock_spin(&pThis->u.s.inq.ifq_mtx);
-+ taskqueue_enqueue_fast(taskqueue_fast, &pThis->u.s.tskin);
-+ }
-+ /**
-+ * Handle mbufs on the outgoing hook, frames going to the interface
-+ */
- else if (pThis->u.s.output == hook)
-- return ng_vboxnetflt_rcv_out(hook, item);
-+ {
-+ if (mtag != NULL || !fActive)
-+ return ether_output_frame(ifp, m);
-+ mtx_lock_spin(&pThis->u.s.outq.ifq_mtx);
-+ _IF_ENQUEUE(&pThis->u.s.outq, m);
-+ mtx_unlock_spin(&pThis->u.s.outq.ifq_mtx);
-+ taskqueue_enqueue_fast(taskqueue_fast, &pThis->u.s.tskout);
-+ }
- else
- {
-- NGI_GET_M(item, m);
-- NG_FREE_ITEM(item);
-+ m_freem(m);
- }
- return (0);
- }
-
-+static int ng_vboxnetflt_shutdown(node_p node)
-+{
-+ PVBOXNETFLTINS pThis = NG_NODE_PRIVATE(node);
-+ bool fActive;
-+
-+ /* Prevent node shutdown if we're active */
-+ fActive = ASMAtomicUoReadBool(&pThis->fActive);
-+ if (fActive)
-+ return (EBUSY);
-+ NG_NODE_UNREF(node);
-+ return (0);
-+}
-+
-+static int ng_vboxnetflt_disconnect(hook_p hook)
-+{
-+ return (0);
-+}
-+
- /**
-- * Handle incoming hook. This is connected to the
-- * input path of the interface, thus handling incoming frames.
-+ * Input processing task, handles incoming frames
- */
--static int ng_vboxnetflt_rcv_in(hook_p hook, item_p item)
-+static void vboxNetFltFreeBSDinput(void *arg, int pending)
- {
-+ PVBOXNETFLTINS pThis = (PVBOXNETFLTINS)arg;
- struct mbuf *m, *m0;
-- struct m_tag *mtag;
-- const node_p node = NG_HOOK_NODE(hook);
-- PVBOXNETFLTINS pThis = NG_NODE_PRIVATE(node);
- struct ifnet *ifp = pThis->u.s.ifp;
-- bool fActive, fDropIt = false;
- unsigned int cSegs = 0;
-+ bool fDropIt = false, fActive;
- PINTNETSG pSG;
-
-- NGI_GET_M(item, m);
-- NG_FREE_ITEM(item);
--
-- fActive = ASMAtomicUoReadBool(&pThis->fActive);
-- if (!fActive)
-- goto out;
--
-- mtag = m_tag_locate(m, MTAG_VBOX, PACKET_TAG_VBOX, NULL);
-- if (mtag != NULL)
-- {
-- m_tag_unlink(m, mtag);
-- m_tag_free(mtag);
-- goto out;
-- }
- vboxNetFltRetain(pThis, true /* fBusy */);
--
-- for (m0 = m; m0 != NULL; m0 = m0->m_next)
-+ for (;;)
- {
-- if (m0->m_len > 0)
-- cSegs++;
-- }
-+ mtx_lock_spin(&pThis->u.s.inq.ifq_mtx);
-+ _IF_DEQUEUE(&pThis->u.s.inq, m);
-+ mtx_unlock_spin(&pThis->u.s.inq.ifq_mtx);
-+ if (m == NULL)
-+ break;
-
-+ for (m0 = m; m0 != NULL; m0 = m0->m_next)
-+ if (m0->m_len > 0)
-+ cSegs++;
-+
- #ifdef PADD_RUNT_FRAMES_FROM_HOST
-- if (m_length(m, NULL) < 60)
-- cSegs++;
-+ if (m_length(m, NULL) < 60)
-+ cSegs++;
- #endif
-
-- /* Create a copy of the mbuf and hand it to the virtual switch */
-- pSG = RTMemTmpAlloc(RT_OFFSETOF(INTNETSG, aSegs[cSegs]));
-- vboxNetFltFreeBSDMBufToSG(pThis, m, pSG, cSegs, 0);
-- fDropIt = pThis->pSwitchPort->pfnRecv(pThis->pSwitchPort, pSG, INTNETTRUNKDIR_WIRE);
-- RTMemTmpFree(pSG);
-+ /* Create a copy and deliver to the virtual switch */
-+ pSG = RTMemTmpAlloc(RT_OFFSETOF(INTNETSG, aSegs[cSegs]));
-+ vboxNetFltFreeBSDMBufToSG(pThis, m, pSG, cSegs, 0);
-+ fDropIt = pThis->pSwitchPort->pfnRecv(pThis->pSwitchPort, pSG, INTNETTRUNKDIR_HOST);
-+ RTMemTmpFree(pSG);
-+ if (fDropIt)
-+ m_freem(m);
-+ else
-+ ether_demux(ifp, m);
-+ }
- vboxNetFltRelease(pThis, true /* fBusy */);
--
--out:
-- /* Only deliver it to the host stack if the destination weren't a guest */
-- if (fDropIt)
-- {
-- m_freem(m);
-- return (0);
-- }
-- ether_demux(ifp, m);
-- return (0);
- }
-
- /**
-- * Handle mbufs on the outgoing hook, frames going to the interface
-+ * Output processing task, handles outgoing frames
- */
--static int ng_vboxnetflt_rcv_out(hook_p hook, item_p item)
-+static void vboxNetFltFreeBSDoutput(void *arg, int pending)
- {
-+ PVBOXNETFLTINS pThis = (PVBOXNETFLTINS)arg;
- struct mbuf *m, *m0;
-- struct m_tag *mtag;
-- const node_p node = NG_HOOK_NODE(hook);
-- PVBOXNETFLTINS pThis = NG_NODE_PRIVATE(node);
- struct ifnet *ifp = pThis->u.s.ifp;
- unsigned int cSegs = 0;
- bool fDropIt = false, fActive;
- PINTNETSG pSG;
-
-- NGI_GET_M(item, m);
-- NG_FREE_ITEM(item);
--
-- fActive = ASMAtomicUoReadBool(&pThis->fActive);
-- if (!fActive)
-- return ether_output_frame(ifp, m);
--
- vboxNetFltRetain(pThis, true /* fBusy */);
-- /* Pass directly to interface if the packet originated from us */
-- mtag = m_tag_locate(m, MTAG_VBOX, PACKET_TAG_VBOX, NULL);
-- if (mtag != NULL)
-+ for (;;)
- {
-- m_tag_unlink(m, mtag);
-- m_tag_free(mtag);
-- goto out;
-- }
-+ mtx_lock_spin(&pThis->u.s.outq.ifq_mtx);
-+ _IF_DEQUEUE(&pThis->u.s.outq, m);
-+ mtx_unlock_spin(&pThis->u.s.outq.ifq_mtx);
-+ if (m == NULL)
-+ break;
-
-- for (m0 = m; m0 != NULL; m0 = m0->m_next)
-- {
-- if (m0->m_len > 0)
-- cSegs++;
-- }
-+ for (m0 = m; m0 != NULL; m0 = m0->m_next)
-+ if (m0->m_len > 0)
-+ cSegs++;
-
- #ifdef PADD_RUNT_FRAMES_FROM_HOST
-- if (m_length(m, NULL) < 60)
-- cSegs++;
-+ if (m_length(m, NULL) < 60)
-+ cSegs++;
- #endif
-- /* Create a copy and deliver to the virtual switch */
-- pSG = RTMemTmpAlloc(RT_OFFSETOF(INTNETSG, aSegs[cSegs]));
-- vboxNetFltFreeBSDMBufToSG(pThis, m, pSG, cSegs, 0);
-- fDropIt = pThis->pSwitchPort->pfnRecv(pThis->pSwitchPort, pSG, INTNETTRUNKDIR_HOST);
-- RTMemTmpFree(pSG);
-+ /* Create a copy and deliver to the virtual switch */
-+ pSG = RTMemTmpAlloc(RT_OFFSETOF(INTNETSG, aSegs[cSegs]));
-+ vboxNetFltFreeBSDMBufToSG(pThis, m, pSG, cSegs, 0);
-+ fDropIt = pThis->pSwitchPort->pfnRecv(pThis->pSwitchPort, pSG, INTNETTRUNKDIR_HOST);
-+ RTMemTmpFree(pSG);
-
--out:
-+ if (fDropIt)
-+ m_freem(m);
-+ else
-+ ether_output_frame(ifp, m);
-+ }
- vboxNetFltRelease(pThis, true /* fBusy */);
-- if (fDropIt)
-- {
-- m_freem(m);
-- return (0);
-- }
--
-- return ether_output_frame(ifp, m);
- }
-
--static int ng_vboxnetflt_shutdown(node_p node)
--{
-- PVBOXNETFLTINS pThis = NG_NODE_PRIVATE(node);
-- bool fActive;
--
-- /* Prevent node shutdown if we're active */
-- fActive = ASMAtomicUoReadBool(&pThis->fActive);
-- if (fActive)
-- return (EBUSY);
-- NG_NODE_UNREF(node);
-- return (0);
--}
--
--static int ng_vboxnetflt_disconnect(hook_p hook)
--{
-- return (0);
--}
--
- /**
- * Called to deliver a frame to either the host, the wire or both.
- */
-@@ -536,13 +542,23 @@
-
- /* Create a new netgraph node for this instance */
- if (ng_make_node_common(&ng_vboxnetflt_typestruct, &node) != 0)
-- return VERR_INTERNAL_ERROR;
-+ return VERR_INTERNAL_ERROR;
-
- RTSpinlockAcquire(pThis->hSpinlock, &Tmp);
- ASMAtomicUoWritePtr((void * volatile *)&pThis->u.s.ifp, ifp);
- pThis->u.s.node = node;
- bcopy(IF_LLADDR(ifp), &pThis->u.s.Mac, ETHER_ADDR_LEN);
- ASMAtomicUoWriteBool(&pThis->fDisconnectedFromHost, false);
-+ /* Initialize deferred input queue */
-+ bzero(&pThis->u.s.inq, sizeof(struct ifqueue));
-+ mtx_init(&pThis->u.s.inq.ifq_mtx, "vboxnetflt inq", NULL, MTX_SPIN);
-+ TASK_INIT(&pThis->u.s.tskin, 0, vboxNetFltFreeBSDinput, pThis);
-+
-+ /* Initialize deferred output queue */
-+ bzero(&pThis->u.s.outq, sizeof(struct ifqueue));
-+ mtx_init(&pThis->u.s.outq.ifq_mtx, "vboxnetflt outq", NULL, MTX_SPIN);
-+ TASK_INIT(&pThis->u.s.tskout, 0, vboxNetFltFreeBSDoutput, pThis);
-+
- RTSpinlockRelease(pThis->hSpinlock, &Tmp);
-
- NG_NODE_SET_PRIVATE(node, pThis);
-@@ -571,7 +587,10 @@
- }
-
- if (ifp0 != NULL)
-+ {
-+ vboxNetFltOsDeleteInstance(pThis);
- vboxNetFltOsInitInstance(pThis, NULL);
-+ }
-
- return !ASMAtomicUoReadBool(&pThis->fDisconnectedFromHost);
- }
-@@ -579,6 +598,12 @@
- void vboxNetFltOsDeleteInstance(PVBOXNETFLTINS pThis)
- {
-
-+ taskqueue_drain(taskqueue_fast, &pThis->u.s.tskin);
-+ taskqueue_drain(taskqueue_fast, &pThis->u.s.tskout);
-+
-+ mtx_destroy(&pThis->u.s.inq.ifq_mtx);
-+ mtx_destroy(&pThis->u.s.outq.ifq_mtx);
-+
- if (pThis->u.s.node != NULL)
- ng_rmnode_self(pThis->u.s.node);
- pThis->u.s.node = NULL;
diff --git a/emulators/virtualbox/files/patch-src-VBox-Runtime-r0drv-freebsd-spinlock-r0drv-freebsd.c b/emulators/virtualbox/files/patch-src-VBox-Runtime-r0drv-freebsd-spinlock-r0drv-freebsd.c
deleted file mode 100644
index c7c56d5814ee..000000000000
--- a/emulators/virtualbox/files/patch-src-VBox-Runtime-r0drv-freebsd-spinlock-r0drv-freebsd.c
+++ /dev/null
@@ -1,14 +0,0 @@
-Index: src/VBox/Runtime/r0drv/freebsd/spinlock-r0drv-freebsd.c
-@@ -171,7 +171,12 @@ RTDECL(void) RTSpinlockAcquire(RTSPINLOC
- AssertPtr(pThis);
- Assert(pThis->u32Magic == RTSPINLOCK_MAGIC);
- #ifdef RT_STRICT
-+#if 0
-+ /* This can't work because at least RTPowerNotificationRegister calls
-+ * RTSpinlockAcquire with *pTmp allocated on the stack.
-+ */
- Assert(pTmp->uFlags == 0);
-+#endif
- pTmp->uFlags = 42;
- #endif
-
diff --git a/emulators/virtualbox/files/patch-src-VBox-Runtime-r0drv-freebsd-the-freebsd-kernel.h b/emulators/virtualbox/files/patch-src-VBox-Runtime-r0drv-freebsd-the-freebsd-kernel.h
deleted file mode 100644
index 4332049487c3..000000000000
--- a/emulators/virtualbox/files/patch-src-VBox-Runtime-r0drv-freebsd-the-freebsd-kernel.h
+++ /dev/null
@@ -1,11 +0,0 @@
---- src/VBox/Runtime/r0drv/freebsd/the-freebsd-kernel.h.orig 2009-09-11 14:48:47.000000000 +0200
-+++ src/VBox/Runtime/r0drv/freebsd/the-freebsd-kernel.h 2009-09-11 14:48:54.000000000 +0200
-@@ -76,7 +76,7 @@
- # define SLEEPQ_TIMEDWAIT_SIG(EventInt) sleepq_timedwait_sig(EventInt, 0)
- # define SLEEPQ_WAIT(EventInt) sleepq_wait(EventInt, 0)
- # define SLEEPQ_WAIT_SIG(EventInt) sleepq_wait_sig(EventInt, 0)
--#elif
-+#else
- # define SLEEPQ_TIMEDWAIT(EventInt) sleepq_timedwait(EventInt)
- # define SLEEPQ_TIMEDWAIT_SIG(EventInt) sleepq_timedwait_sig(EventInt)
- # define SLEEPQ_WAIT(EventInt) sleepq_wait(EventInt)
diff --git a/emulators/virtualbox/files/patch-src-VBox-apps-adpctl_VBoxNetAdpCtl.cpp b/emulators/virtualbox/files/patch-src-VBox-apps-adpctl_VBoxNetAdpCtl.cpp
deleted file mode 100644
index 955bf7a3a151..000000000000
--- a/emulators/virtualbox/files/patch-src-VBox-apps-adpctl_VBoxNetAdpCtl.cpp
+++ /dev/null
@@ -1,207 +0,0 @@
---- src/apps/adpctl/VBoxNetAdpCtl.cpp.r22902 2009-04-10 14:03:59.000000000 +0200
-+++ src/apps/adpctl/VBoxNetAdpCtl.cpp 2009-09-16 14:07:11.000000000 +0200
-@@ -1,4 +1,4 @@
--/* $Id: VBoxNetAdpCtl.cpp 18864 2009-04-10 12:03:59Z vboxsync $ */
-+/* $Id: VBoxNetAdpCtl.cpp 23064 2009-09-16 12:07:11Z vboxsync $ */
- /** @file
- * Apps - VBoxAdpCtl, Configuration tool for vboxnetX adapters.
- */
-@@ -24,7 +24,6 @@
- /*******************************************************************************
- * Header Files *
- *******************************************************************************/
--#include <assert.h>
- #include <stdio.h>
- #include <stdlib.h>
- #include <string.h>
-@@ -36,11 +35,12 @@
- # include <sys/ioccom.h>
- #endif
-
--/* @todo Error codes must be moved to some header file */
--#define ADPCTLERR_NO_CTL_DEV 3
--#define ADPCTLERR_IOCTL_FAILED 4
-+/** @todo Error codes must be moved to some header file */
-+#define ADPCTLERR_BAD_NAME 2
-+#define ADPCTLERR_NO_CTL_DEV 3
-+#define ADPCTLERR_IOCTL_FAILED 4
-
--/* @todo These are duplicates from src/VBox/HostDrivers/VBoxNetAdp/VBoxNetAdpInternal.h */
-+/** @todo These are duplicates from src/VBox/HostDrivers/VBoxNetAdp/VBoxNetAdpInternal.h */
- #define VBOXNETADP_CTL_DEV_NAME "/dev/vboxnetctl"
- #define VBOXNETADP_NAME "vboxnet"
- #define VBOXNETADP_MAX_NAME_LEN 32
-@@ -85,6 +85,7 @@
- pcszArg5, /* [network mask] */
- NULL /* terminator */
- };
-+ char * const envp[] = { (char*)"LC_ALL=C", NULL };
- int rc = EXIT_SUCCESS;
- pid_t childPid = fork();
- switch (childPid)
-@@ -94,7 +95,7 @@
- rc = EXIT_FAILURE;
- break;
- case 0: /* Child process. */
-- if (execv(VBOXADPCTL_IFCONFIG_PATH, (char * const*)argv) == -1)
-+ if (execve(VBOXADPCTL_IFCONFIG_PATH, (char * const*)argv, envp) == -1)
- rc = EXIT_FAILURE;
- break;
- default: /* Parent process. */
-@@ -108,15 +109,39 @@
- #define MAX_ADDRESSES 128
- #define MAX_ADDRLEN 64
-
--static bool removeAddresses(const char *pszAdapterName)
-+static bool removeAddresses(char *pszAdapterName)
- {
-- char szCmd[1024], szBuf[1024];
-+ char szBuf[1024];
- char aszAddresses[MAX_ADDRESSES][MAX_ADDRLEN];
-+ int rc;
-+ int fds[2];
-+ char * const argv[] = { VBOXADPCTL_IFCONFIG_PATH, pszAdapterName, NULL };
-+ char * const envp[] = { (char*)"LC_ALL=C", NULL };
-
- memset(aszAddresses, 0, sizeof(aszAddresses));
-- snprintf(szCmd, sizeof(szCmd), VBOXADPCTL_IFCONFIG_PATH " %s", pszAdapterName);
-- FILE *fp = popen(szCmd, "r");
-
-+ rc = pipe(fds);
-+ if (rc < 0)
-+ return false;
-+
-+ pid_t pid = fork();
-+ if (pid < 0)
-+ return false;
-+
-+ if (pid == 0)
-+ {
-+ /* child */
-+ close(fds[0]);
-+ close(STDOUT_FILENO);
-+ rc = dup2(fds[1], STDOUT_FILENO);
-+ if (rc >= 0)
-+ execve(VBOXADPCTL_IFCONFIG_PATH, argv, envp);
-+ return false;
-+ }
-+
-+ /* parent */
-+ close(fds[1]);
-+ FILE *fp = fdopen(fds[0], "r");
- if (!fp)
- return false;
-
-@@ -124,9 +149,6 @@
- for (cAddrs = 0; cAddrs < MAX_ADDRESSES && fgets(szBuf, sizeof(szBuf), fp);)
- {
- int cbSkipWS = strspn(szBuf, " \t");
--#if 0 /* Don't use this! assert() breaks the mac build. Use IPRT or be a rectangular building thing. */
-- assert(cbSkipWS < 20);
--#endif
- char *pszWord = strtok(szBuf + cbSkipWS, " ");
- /* We are concerned with IPv6 address lines only. */
- if (!pszWord || strcmp(pszWord, "inet6"))
-@@ -143,11 +165,12 @@
- continue;
- strncpy(aszAddresses[cAddrs++], pszWord, MAX_ADDRLEN-1);
- }
-- pclose(fp);
-+ fclose(fp);
-
- for (int i = 0; i < cAddrs; i++)
- {
-- if (executeIfconfig(pszAdapterName, "inet6", VBOXADPCTL_DEL_CMD, aszAddresses[i]) != EXIT_SUCCESS)
-+ if (executeIfconfig(pszAdapterName, "inet6",
-+ VBOXADPCTL_DEL_CMD, aszAddresses[i]) != EXIT_SUCCESS)
- return false;
- }
-
-@@ -166,19 +189,41 @@
- int rc = ioctl(fd, uCmd, pData);
- if (rc == -1)
- {
-- perror("VBoxNetAdpCtl: ioctl failed for " VBOXNETADP_CTL_DEV_NAME);
-+ perror("VBoxNetAdpCtl: ioctl failed for " VBOXNETADP_CTL_DEV_NAME);
- rc = ADPCTLERR_IOCTL_FAILED;
- }
--
-+
- close(fd);
--
-+
- return rc;
- }
-
-+int checkAdapterName(const char *pcszNameIn, char *pszNameOut)
-+{
-+ int iAdapterIndex = -1;
-+
-+ if ( strlen(pcszNameIn) >= VBOXNETADP_MAX_NAME_LEN
-+ || sscanf(pcszNameIn, "vboxnet%d", &iAdapterIndex) != 1
-+ || iAdapterIndex < 0 || iAdapterIndex > 99 )
-+ {
-+ fprintf(stderr, "Setting configuration for %s is not supported.\n", pcszNameIn);
-+ return ADPCTLERR_BAD_NAME;
-+ }
-+ sprintf(pszNameOut, "vboxnet%d", iAdapterIndex);
-+ if (strcmp(pszNameOut, pcszNameIn))
-+ {
-+ fprintf(stderr, "Invalid adapter name %s.\n", pcszNameIn);
-+ return ADPCTLERR_BAD_NAME;
-+ }
-+
-+ return 0;
-+}
-+
- int main(int argc, char *argv[])
-
- {
-- const char *pszAdapterName;
-+ char szAdapterName[VBOXNETADP_MAX_NAME_LEN];
-+ char *pszAdapterName;
- const char *pszAddress;
- const char *pszNetworkMask = NULL;
- const char *pszOption = NULL;
-@@ -216,13 +261,18 @@
- pszAddress = argv[2];
- if (strcmp("remove", pszAddress) == 0)
- {
-- strncpy(Req.szName, pszAdapterName, sizeof(Req.szName));
-+ rc = checkAdapterName(pszAdapterName, szAdapterName);
-+ if (rc)
-+ return rc;
-+ memset(&Req, '\0', sizeof(Req));
-+ snprintf(Req.szName, sizeof(Req.szName), "%s", szAdapterName);
- return doIOCtl(VBOXNETADP_CTL_REMOVE, &Req);
- }
- break;
- case 2:
- if (strcmp("add", argv[1]) == 0)
- {
-+ memset(&Req, '\0', sizeof(Req));
- rc = doIOCtl(VBOXNETADP_CTL_ADD, &Req);
- if (rc == 0)
- puts(Req.szName);
-@@ -237,11 +287,11 @@
- return 1;
- }
-
-- if (strncmp("vboxnet", pszAdapterName, 7))
-- {
-- fprintf(stderr, "Setting configuration for %s is not supported.\n", pszAdapterName);
-- return 2;
-- }
-+ rc = checkAdapterName(pszAdapterName, szAdapterName);
-+ if (rc)
-+ return rc;
-+
-+ pszAdapterName = szAdapterName;
-
- if (fRemove)
- {
-@@ -276,3 +326,4 @@
- }
- return rc;
- }
-+
diff --git a/emulators/virtualbox/files/pkg-install.in b/emulators/virtualbox/files/pkg-install.in
deleted file mode 100644
index 5d5268d8e8ce..000000000000
--- a/emulators/virtualbox/files/pkg-install.in
+++ /dev/null
@@ -1,22 +0,0 @@
-#!/bin/sh
-
-case $2 in
-POST-INSTALL)
- GROUP=%%VBOXGROUP%%
- GID=%%VBOXGID%%
- PW=/usr/sbin/pw
-
- if ${PW} group show "${GROUP}" 2>/dev/null; then
- echo "You already have a group \"${GROUP}\", so I will use it."
- else
- if ${PW} groupadd ${GROUP} -g ${GID}; then
- echo "Added group \"${GROUP}\"."
- else
- echo "Adding group \"${GROUP}\" failed..."
- exit 1
- fi
- fi
-
- exit 0
- ;;
-esac
diff --git a/emulators/virtualbox/pkg-descr b/emulators/virtualbox/pkg-descr
deleted file mode 100644
index 0b1e16c034af..000000000000
--- a/emulators/virtualbox/pkg-descr
+++ /dev/null
@@ -1,7 +0,0 @@
-VirtualBox is a family of powerful x86 virtualization products for
-enterprise as well as home use. Not only is VirtualBox an extremely
-feature rich, high performance product for enterprise customers, it
-is also the only professional solution that is freely available as
-Open Source Software under the terms of the GNU General Public License.
-
-WWW: http://www.virtualbox.org/
diff --git a/emulators/virtualbox/pkg-message b/emulators/virtualbox/pkg-message
deleted file mode 100644
index 91b8b16427cd..000000000000
--- a/emulators/virtualbox/pkg-message
+++ /dev/null
@@ -1,26 +0,0 @@
-=============================================================================
-
-VirtualBox was installed.
-
-You need to load the vboxdrv kernel module and a mounted /proc filesystem.
-
-% mount -t procfs proc /proc
-% kldload vboxdrv
-
-For bridged networking you also need to load the vboxnetflt kernel module.
-
-% kldload vboxnetflt
-
-You also have to add all users to your vboxusers group in order to use vbox.
-
-% pw groupmod vboxusers -m jerry
-
-Running VirtualBox as non-root user may fail with a fatal error
-NS_ERROR_FACTORY_NOT_REGISTERED. In this case delete /tmp/.vbox-*-ipc file.
-
-Check wiki page for known issues and troubleshooting:
-http://wiki.freebsd.org/VirtualBox
-
-Please report any problems to emulation@. Thanks!
-
-=============================================================================
diff --git a/emulators/virtualbox/pkg-plist b/emulators/virtualbox/pkg-plist
deleted file mode 100644
index f8ade22c00a7..000000000000
--- a/emulators/virtualbox/pkg-plist
+++ /dev/null
@@ -1,599 +0,0 @@
-%%X11%%bin/VBoxBFE
-bin/VBoxHeadless
-bin/VBoxManage
-bin/VBoxNetAdpCtl
-bin/VBoxNetDHCP
-%%X11%%bin/VBoxSDL
-bin/VBoxSVC
-%%X11%%bin/VBoxTestOGL
-bin/VBoxXPCOMIPCD
-%%QT4%%bin/VirtualBox
-%%X11%%lib/virtualbox/VBoxBFE
-%%X11%%lib/virtualbox/VBoxBFE.so
-lib/virtualbox/VBoxDD.so
-lib/virtualbox/VBoxDD2.so
-lib/virtualbox/VBoxDDU.so
-lib/virtualbox/VBoxGuestPropSvc.so
-lib/virtualbox/VBoxHeadless
-lib/virtualbox/VBoxHeadless.so
-%%QT4%%lib/virtualbox/VBoxKeyboard.so
-lib/virtualbox/VBoxManage
-lib/virtualbox/VBoxNetAdpCtl
-lib/virtualbox/VBoxNetDHCP
-lib/virtualbox/VBoxNetDHCP.so
-%%X11%%lib/virtualbox/VBoxOGLhostcrutil.so
-%%X11%%lib/virtualbox/VBoxOGLhosterrorspu.so
-%%X11%%lib/virtualbox/VBoxOGLrenderspu.so
-lib/virtualbox/VBoxPython.so
-lib/virtualbox/VBoxREM.so
-%%X11%%lib/virtualbox/VBoxTestOGL
-%%I386%%lib/virtualbox/VBoxREM32.so
-%%I386%%lib/virtualbox/VBoxREM64.so
-lib/virtualbox/VBoxRT.so
-%%X11%%lib/virtualbox/VBoxSDL
-%%X11%%lib/virtualbox/VBoxSDL.so
-lib/virtualbox/VBoxSVC
-lib/virtualbox/VBoxSharedClipboard.so
-%%X11%%lib/virtualbox/VBoxSharedCrOpenGL.so
-lib/virtualbox/VBoxSharedFolders.so
-lib/virtualbox/VBoxVMM.so
-lib/virtualbox/VBoxXPCOM.so
-lib/virtualbox/VBoxXPCOMC.so
-lib/virtualbox/VBoxXPCOMIPCD
-%%QT4%%lib/virtualbox/VirtualBox
-%%QT4%%lib/virtualbox/VirtualBox.so
-lib/virtualbox/VBoxDD2GC.gc
-lib/virtualbox/VBoxDDGC.gc
-lib/virtualbox/VMMGC.gc
-lib/virtualbox/VBoxDD2R0.r0
-lib/virtualbox/VBoxDDR0.r0
-%%GUESTADDITIONS%%lib/virtualbox/additions/VBoxGuestAdditions.iso
-%%GUESTADDITIONS%%lib/virtualbox/additions/VBoxGuestAdditions_%%GUEST_VER%%.iso
-lib/virtualbox/VBoxPython%%PYTHON_VERU%%.so
-lib/virtualbox/VMMR0.r0
-lib/virtualbox/components/VirtualBox_XPCOM.xpt
-lib/virtualbox/components/VBoxXPCOMIPCC.so
-lib/virtualbox/components/VBoxSVCM.so
-lib/virtualbox/components/VBoxC.so
-lib/virtualbox/components/VBoxXPCOMBase.xpt
-%%NLS%%%%DATADIR%%/nls/VirtualBox_ar.qm
-%%NLS%%%%DATADIR%%/nls/VirtualBox_bg.qm
-%%NLS%%%%DATADIR%%/nls/VirtualBox_ca.qm
-%%NLS%%%%DATADIR%%/nls/VirtualBox_cs.qm
-%%NLS%%%%DATADIR%%/nls/VirtualBox_de.qm
-%%NLS%%%%DATADIR%%/nls/VirtualBox_el.qm
-%%NLS%%%%DATADIR%%/nls/VirtualBox_es.qm
-%%NLS%%%%DATADIR%%/nls/VirtualBox_eu.qm
-%%NLS%%%%DATADIR%%/nls/VirtualBox_fi.qm
-%%NLS%%%%DATADIR%%/nls/VirtualBox_fr.qm
-%%NLS%%%%DATADIR%%/nls/VirtualBox_hu.qm
-%%NLS%%%%DATADIR%%/nls/VirtualBox_id.qm
-%%NLS%%%%DATADIR%%/nls/VirtualBox_it.qm
-%%NLS%%%%DATADIR%%/nls/VirtualBox_ja.qm
-%%NLS%%%%DATADIR%%/nls/VirtualBox_km_KH.qm
-%%NLS%%%%DATADIR%%/nls/VirtualBox_ko.qm
-%%NLS%%%%DATADIR%%/nls/VirtualBox_nl.qm
-%%NLS%%%%DATADIR%%/nls/VirtualBox_pl.qm
-%%NLS%%%%DATADIR%%/nls/VirtualBox_pt.qm
-%%NLS%%%%DATADIR%%/nls/VirtualBox_pt_BR.qm
-%%NLS%%%%DATADIR%%/nls/VirtualBox_ro.qm
-%%NLS%%%%DATADIR%%/nls/VirtualBox_ru.qm
-%%NLS%%%%DATADIR%%/nls/VirtualBox_sk.qm
-%%NLS%%%%DATADIR%%/nls/VirtualBox_sr.qm
-%%NLS%%%%DATADIR%%/nls/VirtualBox_sv.qm
-%%NLS%%%%DATADIR%%/nls/VirtualBox_tr.qm
-%%NLS%%%%DATADIR%%/nls/VirtualBox_uk.qm
-%%NLS%%%%DATADIR%%/nls/VirtualBox_zh_CN.qm
-%%NLS%%%%DATADIR%%/nls/VirtualBox_zh_TW.qm
-%%NLS%%%%DATADIR%%/nls/qt_ar.qm
-%%NLS%%%%DATADIR%%/nls/qt_bg.qm
-%%NLS%%%%DATADIR%%/nls/qt_ca.qm
-%%NLS%%%%DATADIR%%/nls/qt_cs.qm
-%%NLS%%%%DATADIR%%/nls/qt_de.qm
-%%NLS%%%%DATADIR%%/nls/qt_el.qm
-%%NLS%%%%DATADIR%%/nls/qt_es.qm
-%%NLS%%%%DATADIR%%/nls/qt_eu.qm
-%%NLS%%%%DATADIR%%/nls/qt_fi.qm
-%%NLS%%%%DATADIR%%/nls/qt_fr.qm
-%%NLS%%%%DATADIR%%/nls/qt_hu.qm
-%%NLS%%%%DATADIR%%/nls/qt_id.qm
-%%NLS%%%%DATADIR%%/nls/qt_it.qm
-%%NLS%%%%DATADIR%%/nls/qt_ja.qm
-%%NLS%%%%DATADIR%%/nls/qt_km_KH.qm
-%%NLS%%%%DATADIR%%/nls/qt_ko.qm
-%%NLS%%%%DATADIR%%/nls/qt_nl.qm
-%%NLS%%%%DATADIR%%/nls/qt_pl.qm
-%%NLS%%%%DATADIR%%/nls/qt_pt.qm
-%%NLS%%%%DATADIR%%/nls/qt_pt_BR.qm
-%%NLS%%%%DATADIR%%/nls/qt_ro.qm
-%%NLS%%%%DATADIR%%/nls/qt_ru.qm
-%%NLS%%%%DATADIR%%/nls/qt_sk.qm
-%%NLS%%%%DATADIR%%/nls/qt_sr.qm
-%%NLS%%%%DATADIR%%/nls/qt_sv.qm
-%%NLS%%%%DATADIR%%/nls/qt_tr.qm
-%%NLS%%%%DATADIR%%/nls/qt_uk.qm
-%%NLS%%%%DATADIR%%/nls/qt_zh_CN.qm
-%%NLS%%%%DATADIR%%/nls/qt_zh_TW.qm
-%%QT4%%share/applications/virtualbox.desktop
-%%QT4%%share/icons/hicolor/48x48/apps/VBox.png
-%%DATADIR%%/idl/nsIDebug.idl
-%%DATADIR%%/idl/nsIInterfaceRequestor.idl
-%%DATADIR%%/idl/nsIMemory.idl
-%%DATADIR%%/idl/nsIProgrammingLanguage.idl
-%%DATADIR%%/idl/nsISupports.idl
-%%DATADIR%%/idl/nsITraceRefcnt.idl
-%%DATADIR%%/idl/nsIWeakReference.idl
-%%DATADIR%%/idl/nsIConsoleMessage.idl
-%%DATADIR%%/idl/nsIConsoleService.idl
-%%DATADIR%%/idl/nsIConsoleListener.idl
-%%DATADIR%%/idl/nsIErrorService.idl
-%%DATADIR%%/idl/nsIException.idl
-%%DATADIR%%/idl/nsIExceptionService.idl
-%%DATADIR%%/idl/nsrootidl.idl
-%%DATADIR%%/idl/nsIClassInfo.idl
-%%DATADIR%%/idl/nsIFactory.idl
-%%DATADIR%%/idl/nsIModule.idl
-%%DATADIR%%/idl/nsIComponentRegistrar.idl
-%%DATADIR%%/idl/nsIServiceManager.idl
-%%DATADIR%%/idl/nsIComponentManager.idl
-%%DATADIR%%/idl/nsICategoryManager.idl
-%%DATADIR%%/idl/nsINativeComponentLoader.idl
-%%DATADIR%%/idl/nsIComponentLoader.idl
-%%DATADIR%%/idl/nsIComponentManagerObsolete.idl
-%%DATADIR%%/idl/nsISupportsArray.idl
-%%DATADIR%%/idl/nsIComponentLoaderManager.idl
-%%DATADIR%%/idl/nsICollection.idl
-%%DATADIR%%/idl/nsISerializable.idl
-%%DATADIR%%/idl/nsIEnumerator.idl
-%%DATADIR%%/idl/nsISimpleEnumerator.idl
-%%DATADIR%%/idl/nsIObserverService.idl
-%%DATADIR%%/idl/nsIObserver.idl
-%%DATADIR%%/idl/nsIAtom.idl
-%%DATADIR%%/idl/nsIAtomService.idl
-%%DATADIR%%/idl/nsIProperties.idl
-%%DATADIR%%/idl/nsIPersistentProperties2.idl
-%%DATADIR%%/idl/nsIRecyclingAllocator.idl
-%%DATADIR%%/idl/nsIStringEnumerator.idl
-%%DATADIR%%/idl/nsISupportsPrimitives.idl
-%%DATADIR%%/idl/nsISupportsIterators.idl
-%%DATADIR%%/idl/nsITimelineService.idl
-%%DATADIR%%/idl/nsIVariant.idl
-%%DATADIR%%/idl/nsIArray.idl
-%%DATADIR%%/idl/nsIPropertyBag.idl
-%%DATADIR%%/idl/nsIHashable.idl
-%%DATADIR%%/idl/nsIDirectoryService.idl
-%%DATADIR%%/idl/nsIDirectoryEnumerator.idl
-%%DATADIR%%/idl/nsIFile.idl
-%%DATADIR%%/idl/nsILocalFile.idl
-%%DATADIR%%/idl/nsIInputStream.idl
-%%DATADIR%%/idl/nsILocalFileMac.idl
-%%DATADIR%%/idl/nsIObjectInputStream.idl
-%%DATADIR%%/idl/nsIBinaryInputStream.idl
-%%DATADIR%%/idl/nsIObjectOutputStream.idl
-%%DATADIR%%/idl/nsIBinaryOutputStream.idl
-%%DATADIR%%/idl/nsIStreamBufferAccess.idl
-%%DATADIR%%/idl/nsIOutputStream.idl
-%%DATADIR%%/idl/nsIByteArrayInputStream.idl
-%%DATADIR%%/idl/nsIFastLoadFileControl.idl
-%%DATADIR%%/idl/nsISeekableStream.idl
-%%DATADIR%%/idl/nsIInputStreamTee.idl
-%%DATADIR%%/idl/nsIFastLoadService.idl
-%%DATADIR%%/idl/nsIMultiplexInputStream.idl
-%%DATADIR%%/idl/nsIPipe.idl
-%%DATADIR%%/idl/nsIAsyncInputStream.idl
-%%DATADIR%%/idl/nsIAsyncOutputStream.idl
-%%DATADIR%%/idl/nsIScriptableInputStream.idl
-%%DATADIR%%/idl/nsIStorageStream.idl
-%%DATADIR%%/idl/nsILineInputStream.idl
-%%DATADIR%%/idl/nsIStringStream.idl
-%%DATADIR%%/idl/nsIProxyObjectManager.idl
-%%DATADIR%%/idl/nsIEventQueue.idl
-%%DATADIR%%/idl/nsIEventQueueService.idl
-%%DATADIR%%/idl/nsIRunnable.idl
-%%DATADIR%%/idl/nsIThread.idl
-%%DATADIR%%/idl/nsIEventTarget.idl
-%%DATADIR%%/idl/nsIEnvironment.idl
-%%DATADIR%%/idl/nsITimer.idl
-%%DATADIR%%/idl/nsITimerInternal.idl
-%%DATADIR%%/idl/nsITimerManager.idl
-%%DATADIR%%/idl/nsIInterfaceInfo.idl
-%%DATADIR%%/idl/nsIProcess.idl
-%%DATADIR%%/idl/nsIXPTLoader.idl
-%%DATADIR%%/idl/nsIInterfaceInfoManager.idl
-%%DATADIR%%/idl/ipcIMessageObserver.idl
-%%DATADIR%%/idl/ipcIService.idl
-%%DATADIR%%/idl/ipcIClientObserver.idl
-%%DATADIR%%/idl/ipcILockService.idl
-%%DATADIR%%/idl/ipcIDConnectService.idl
-%%DATADIR%%/idl/ipcITransactionService.idl
-%%DATADIR%%/idl/ipcITransactionObserver.idl
-%%DATADIR%%/idl/VirtualBox_XPCOM.idl
-%%DATADIR%%/samples/tstVBoxAPILinux.cpp
-%%DATADIR%%/samples/Makefile
-include/virtualbox/VBoxCAPI_v2_2.h
-include/virtualbox/VBoxCAPI_v3_0.h
-include/virtualbox/VBoxCAPI_v3_1.h
-include/virtualbox/VirtualBox_XPCOM.h
-include/virtualbox/ipcIClientObserver.h
-include/virtualbox/ipcIDConnectService.h
-include/virtualbox/ipcILockService.h
-include/virtualbox/ipcIMessageObserver.h
-include/virtualbox/ipcIService.h
-include/virtualbox/ipcITransactionObserver.h
-include/virtualbox/ipcITransactionService.h
-include/virtualbox/ipcd/ipcCID.h
-include/virtualbox/ipcd/ipcLockCID.h
-include/virtualbox/ipcd/ipcMessageReader.h
-include/virtualbox/ipcd/ipcMessageWriter.h
-include/virtualbox/ipcd/ipcModule.h
-include/virtualbox/ipcd/ipcModuleUtil.h
-include/virtualbox/ipcd/ipcdclient.h
-include/virtualbox/nsIArray.h
-include/virtualbox/nsIAsyncInputStream.h
-include/virtualbox/nsIAsyncOutputStream.h
-include/virtualbox/nsIAtom.h
-include/virtualbox/nsIAtomService.h
-include/virtualbox/nsIBinaryInputStream.h
-include/virtualbox/nsIBinaryOutputStream.h
-include/virtualbox/nsIByteArrayInputStream.h
-include/virtualbox/nsICategoryManager.h
-include/virtualbox/nsIClassInfo.h
-include/virtualbox/nsICollection.h
-include/virtualbox/nsIComponentLoader.h
-include/virtualbox/nsIComponentLoaderManager.h
-include/virtualbox/nsIComponentManager.h
-include/virtualbox/nsIComponentManagerObsolete.h
-include/virtualbox/nsIComponentRegistrar.h
-include/virtualbox/nsIConsoleListener.h
-include/virtualbox/nsIConsoleMessage.h
-include/virtualbox/nsIConsoleService.h
-include/virtualbox/nsIDebug.h
-include/virtualbox/nsIDirectoryEnumerator.h
-include/virtualbox/nsIDirectoryService.h
-include/virtualbox/nsIEnumerator.h
-include/virtualbox/nsIEnvironment.h
-include/virtualbox/nsIErrorService.h
-include/virtualbox/nsIEventQueue.h
-include/virtualbox/nsIEventQueueService.h
-include/virtualbox/nsIEventTarget.h
-include/virtualbox/nsIException.h
-include/virtualbox/nsIExceptionService.h
-include/virtualbox/nsIFactory.h
-include/virtualbox/nsIFastLoadFileControl.h
-include/virtualbox/nsIFastLoadService.h
-include/virtualbox/nsIFile.h
-include/virtualbox/nsIHashable.h
-include/virtualbox/nsIInputStream.h
-include/virtualbox/nsIInputStreamTee.h
-include/virtualbox/nsIInterfaceInfo.h
-include/virtualbox/nsIInterfaceInfoManager.h
-include/virtualbox/nsIInterfaceRequestor.h
-include/virtualbox/nsILineInputStream.h
-include/virtualbox/nsILocalFile.h
-include/virtualbox/nsILocalFileMac.h
-include/virtualbox/nsIMemory.h
-include/virtualbox/nsIModule.h
-include/virtualbox/nsIMultiplexInputStream.h
-include/virtualbox/nsINativeComponentLoader.h
-include/virtualbox/nsIObjectInputStream.h
-include/virtualbox/nsIObjectOutputStream.h
-include/virtualbox/nsIObserver.h
-include/virtualbox/nsIObserverService.h
-include/virtualbox/nsIOutputStream.h
-include/virtualbox/nsIPersistentProperties2.h
-include/virtualbox/nsIPipe.h
-include/virtualbox/nsIProcess.h
-include/virtualbox/nsIProgrammingLanguage.h
-include/virtualbox/nsIProperties.h
-include/virtualbox/nsIPropertyBag.h
-include/virtualbox/nsIProxyObjectManager.h
-include/virtualbox/nsIRecyclingAllocator.h
-include/virtualbox/nsIRunnable.h
-include/virtualbox/nsIScriptableInputStream.h
-include/virtualbox/nsISeekableStream.h
-include/virtualbox/nsISerializable.h
-include/virtualbox/nsIServiceManager.h
-include/virtualbox/nsISimpleEnumerator.h
-include/virtualbox/nsIStorageStream.h
-include/virtualbox/nsIStreamBufferAccess.h
-include/virtualbox/nsIStringEnumerator.h
-include/virtualbox/nsIStringStream.h
-include/virtualbox/nsISupports.h
-include/virtualbox/nsISupportsArray.h
-include/virtualbox/nsISupportsIterators.h
-include/virtualbox/nsISupportsPrimitives.h
-include/virtualbox/nsIThread.h
-include/virtualbox/nsITimelineService.h
-include/virtualbox/nsITimer.h
-include/virtualbox/nsITimerInternal.h
-include/virtualbox/nsITimerManager.h
-include/virtualbox/nsITraceRefcnt.h
-include/virtualbox/nsIVariant.h
-include/virtualbox/nsIWeakReference.h
-include/virtualbox/nsIXPTLoader.h
-include/virtualbox/nsprpub/nspr.h
-include/virtualbox/nsprpub/plarena.h
-include/virtualbox/nsprpub/plarenas.h
-include/virtualbox/nsprpub/plbase64.h
-include/virtualbox/nsprpub/plerror.h
-include/virtualbox/nsprpub/plgetopt.h
-include/virtualbox/nsprpub/plhash.h
-include/virtualbox/nsprpub/plresolv.h
-include/virtualbox/nsprpub/plstr.h
-include/virtualbox/nsprpub/pratom.h
-include/virtualbox/nsprpub/prbit.h
-include/virtualbox/nsprpub/prclist.h
-include/virtualbox/nsprpub/prcmon.h
-include/virtualbox/nsprpub/prcountr.h
-include/virtualbox/nsprpub/prcvar.h
-include/virtualbox/nsprpub/prdtoa.h
-include/virtualbox/nsprpub/prenv.h
-include/virtualbox/nsprpub/prerr.h
-include/virtualbox/nsprpub/prerror.h
-include/virtualbox/nsprpub/prinet.h
-include/virtualbox/nsprpub/prinit.h
-include/virtualbox/nsprpub/prinrval.h
-include/virtualbox/nsprpub/prio.h
-include/virtualbox/nsprpub/pripcsem.h
-include/virtualbox/nsprpub/prlink.h
-include/virtualbox/nsprpub/md/_iprt_atomic.h
-include/virtualbox/nsprpub/md/_darwin.h
-include/virtualbox/nsprpub/md/_freebsd.h
-include/virtualbox/nsprpub/md/_l4v2.h
-include/virtualbox/nsprpub/md/_linux.h
-include/virtualbox/nsprpub/md/_macos.h
-include/virtualbox/nsprpub/md/_netbsd.h
-include/virtualbox/nsprpub/md/_openbsd.h
-include/virtualbox/nsprpub/md/_os2_errors.h
-include/virtualbox/nsprpub/md/_os2.h
-include/virtualbox/nsprpub/md/_pcos.h
-include/virtualbox/nsprpub/md/_solaris.h
-include/virtualbox/nsprpub/md/_unix_errors.h
-include/virtualbox/nsprpub/md/_unixos.h
-include/virtualbox/nsprpub/md/_pth.h
-include/virtualbox/nsprpub/md/prosdep.h
-include/virtualbox/nsprpub/md/_freebsd.cfg
-include/virtualbox/nsprpub/md/_linux.cfg
-include/virtualbox/nsprpub/md/_darwin.cfg
-include/virtualbox/nsprpub/md/_netbsd.cfg
-include/virtualbox/nsprpub/md/_openbsd.cfg
-include/virtualbox/nsprpub/md/_os2.cfg
-include/virtualbox/nsprpub/md/_solaris32.cfg
-include/virtualbox/nsprpub/md/_l4v2.cfg
-include/virtualbox/nsprpub/md/_solaris64.cfg
-include/virtualbox/nsprpub/prlock.h
-include/virtualbox/nsprpub/prlog.h
-include/virtualbox/nsprpub/prlong.h
-include/virtualbox/nsprpub/prmem.h
-include/virtualbox/nsprpub/prmon.h
-include/virtualbox/nsprpub/prmwait.h
-include/virtualbox/nsprpub/prnetdb.h
-include/virtualbox/nsprpub/prolock.h
-include/virtualbox/nsprpub/prpdce.h
-include/virtualbox/nsprpub/prprf.h
-include/virtualbox/nsprpub/prproces.h
-include/virtualbox/nsprpub/prrng.h
-include/virtualbox/nsprpub/prrwlock.h
-include/virtualbox/nsprpub/prshm.h
-include/virtualbox/nsprpub/prshma.h
-include/virtualbox/nsprpub/prsystem.h
-include/virtualbox/nsprpub/prthread.h
-include/virtualbox/nsprpub/prtime.h
-include/virtualbox/nsprpub/prtpool.h
-include/virtualbox/nsprpub/prtrace.h
-include/virtualbox/nsprpub/prtypes.h
-include/virtualbox/nsprpub/prvrsion.h
-include/virtualbox/nsprpub/prwin16.h
-include/virtualbox/nsprpub/prcpucfg.h
-include/virtualbox/nsprpub/obsolete/pralarm.h
-include/virtualbox/nsprpub/obsolete/probslet.h
-include/virtualbox/nsprpub/obsolete/protypes.h
-include/virtualbox/nsprpub/obsolete/prsem.h
-include/virtualbox/nsprpub/private/pprio.h
-include/virtualbox/nsprpub/private/pprthred.h
-include/virtualbox/nsprpub/private/prpriv.h
-include/virtualbox/nsrootidl.h
-include/virtualbox/string/nsAString.h
-include/virtualbox/string/nsAlgorithm.h
-include/virtualbox/string/nsCharTraits.h
-include/virtualbox/string/nsDependentString.h
-include/virtualbox/string/nsDependentSubstring.h
-include/virtualbox/string/nsEmbedString.h
-include/virtualbox/string/nsLiteralString.h
-include/virtualbox/string/nsObsoleteAString.h
-include/virtualbox/string/nsPrintfCString.h
-include/virtualbox/string/nsPromiseFlatString.h
-include/virtualbox/string/nsReadableUtils.h
-include/virtualbox/string/nsString.h
-include/virtualbox/string/nsStringAPI.h
-include/virtualbox/string/nsStringFwd.h
-include/virtualbox/string/nsStringIterator.h
-include/virtualbox/string/nsSubstring.h
-include/virtualbox/string/nsSubstringTuple.h
-include/virtualbox/string/nsTAString.h
-include/virtualbox/string/nsTString.h
-include/virtualbox/string/nsTDependentString.h
-include/virtualbox/string/nsTDependentSubstring.h
-include/virtualbox/string/nsTObsoleteAString.h
-include/virtualbox/string/nsTPromiseFlatString.h
-include/virtualbox/string/nsTSubstring.h
-include/virtualbox/string/nsTSubstringTuple.h
-include/virtualbox/string/nsUTF8Utils.h
-include/virtualbox/string/nsXPIDLString.h
-include/virtualbox/string/string-template-def-char.h
-include/virtualbox/string/string-template-def-unichar.h
-include/virtualbox/string/string-template-undef.h
-include/virtualbox/xpcom/nsAgg.h
-include/virtualbox/xpcom/nsAppDirectoryServiceDefs.h
-include/virtualbox/xpcom/nsArray.h
-include/virtualbox/xpcom/nsArrayEnumerator.h
-include/virtualbox/xpcom/nsAtomService.h
-include/virtualbox/xpcom/nsAutoBuffer.h
-include/virtualbox/xpcom/nsAutoLock.h
-include/virtualbox/xpcom/nsAutoPtr.h
-include/virtualbox/xpcom/nsBaseHashtable.h
-include/virtualbox/xpcom/nsCOMArray.h
-include/virtualbox/xpcom/nsCRT.h
-include/virtualbox/xpcom/nsCategoryManagerUtils.h
-include/virtualbox/xpcom/nsCheapSets.h
-include/virtualbox/xpcom/nsClassHashtable.h
-include/virtualbox/xpcom/nsCom.h
-include/virtualbox/xpcom/nsComponentManagerObsolete.h
-include/virtualbox/xpcom/nsComponentManagerUtils.h
-include/virtualbox/xpcom/nsCppSharedAllocator.h
-include/virtualbox/xpcom/nsID.h
-include/virtualbox/xpcom/nsDataHashtable.h
-include/virtualbox/xpcom/nsDebugImpl.h
-include/virtualbox/xpcom/nsDeque.h
-include/virtualbox/xpcom/nsDirectoryService.h
-include/virtualbox/xpcom/nsDirectoryServiceDefs.h
-include/virtualbox/xpcom/nsDirectoryServiceUtils.h
-include/virtualbox/xpcom/nsDoubleHashtable.h
-include/virtualbox/xpcom/nsEnumeratorUtils.h
-include/virtualbox/xpcom/nsError.h
-include/virtualbox/xpcom/nsEscape.h
-include/virtualbox/xpcom/nsEventQueueUtils.h
-include/virtualbox/xpcom/nsFastLoadPtr.h
-include/virtualbox/xpcom/nsFastLoadService.h
-include/virtualbox/xpcom/nsFixedSizeAllocator.h
-include/virtualbox/xpcom/nsHashKeys.h
-include/virtualbox/xpcom/nsHashSets.h
-include/virtualbox/xpcom/nsHashtable.h
-include/virtualbox/xpcom/nsIAllocator.h
-include/virtualbox/xpcom/nsIByteBuffer.h
-include/virtualbox/xpcom/nsIID.h
-include/virtualbox/xpcom/nsIServiceManagerObsolete.h
-include/virtualbox/xpcom/nsIServiceManagerUtils.h
-include/virtualbox/xpcom/nsISupportsBase.h
-include/virtualbox/xpcom/nsISupportsObsolete.h
-include/virtualbox/xpcom/nsIUnicharBuffer.h
-include/virtualbox/xpcom/nsIUnicharInputStream.h
-include/virtualbox/xpcom/nsInt64.h
-include/virtualbox/xpcom/nsInterfaceHashtable.h
-include/virtualbox/xpcom/nsLinebreakConverter.h
-include/virtualbox/xpcom/nsLocalFile.h
-include/virtualbox/xpcom/nsLocalFileUnix.h
-include/virtualbox/xpcom/nsLocalFileOS2.h
-include/virtualbox/xpcom/nsLocalFileOSX.h
-include/virtualbox/xpcom/nsModule.h
-include/virtualbox/xpcom/nsMultiplexInputStream.h
-include/virtualbox/xpcom/nsNativeCharsetUtils.h
-include/virtualbox/xpcom/nsProcess.h
-include/virtualbox/xpcom/nsNativeComponentLoader.h
-include/virtualbox/xpcom/nsObserverService.h
-include/virtualbox/xpcom/nsObsoleteModuleLoading.h
-include/virtualbox/xpcom/nsProxiedService.h
-include/virtualbox/xpcom/nsProxyEvent.h
-include/virtualbox/xpcom/nsProxyRelease.h
-include/virtualbox/xpcom/nsQuickSort.h
-include/virtualbox/xpcom/nsRecyclingAllocator.h
-include/virtualbox/xpcom/nsRefPtrHashtable.h
-include/virtualbox/xpcom/nsScriptableInputStream.h
-include/virtualbox/xpcom/nsStaticAtom.h
-include/virtualbox/xpcom/nsStaticComponent.h
-include/virtualbox/xpcom/nsStaticNameTable.h
-include/virtualbox/xpcom/nsStorageStream.h
-include/virtualbox/xpcom/nsStreamUtils.h
-include/virtualbox/xpcom/nsStringEnumerator.h
-include/virtualbox/xpcom/nsStringIO.h
-include/virtualbox/xpcom/nsTHashtable.h
-include/virtualbox/xpcom/nsStringStream.h
-include/virtualbox/xpcom/nsSupportsArray.h
-include/virtualbox/xpcom/nsSupportsPrimitives.h
-include/virtualbox/xpcom/nsTextFormatter.h
-include/virtualbox/xpcom/nsTime.h
-include/virtualbox/xpcom/nsTraceRefcntImpl.h
-include/virtualbox/xpcom/nsUnitConversion.h
-include/virtualbox/xpcom/nsValueArray.h
-include/virtualbox/xpcom/nsVariant.h
-include/virtualbox/xpcom/nsVoidArray.h
-include/virtualbox/xpcom/nsWeakPtr.h
-include/virtualbox/xpcom/nsXPCOM.h
-include/virtualbox/xpcom/nsXPCOMCID.h
-include/virtualbox/xpcom/nscore.h
-include/virtualbox/xpcom/pldhash.h
-include/virtualbox/xpcom/plevent.h
-include/virtualbox/xpcom/xcDll.h
-include/virtualbox/xpcom/xpt_arena.h
-include/virtualbox/xpcom/xpt_struct.h
-include/virtualbox/xpcom/xpt_xdr.h
-include/virtualbox/xpcom/xptcall.h
-include/virtualbox/xpcom/xptcstubsdecl.inc
-include/virtualbox/xpcom/xptcstubsdef.inc
-include/virtualbox/xpcom/xptinfo.h
-include/virtualbox/xpcom/nsIInterfaceRequestorUtils.h
-include/virtualbox/xpcom/nsISupportsImpl.h
-include/virtualbox/xpcom/nsISupportsUtils.h
-include/virtualbox/xpcom/nsIWeakReferenceUtils.h
-include/virtualbox/xpcom/nsCOMPtr.h
-include/virtualbox/xpcom/nsDebug.h
-include/virtualbox/xpcom/nsGenericFactory.h
-include/virtualbox/xpcom/nsIGenericFactory.h
-include/virtualbox/xpcom/nsMemory.h
-include/virtualbox/xpcom/nsTraceRefcnt.h
-include/virtualbox/xpcom/nsWeakReference.h
-include/virtualbox/xpcom/nsXPCOMGlue.h
-include/virtualbox/xpcom/xpcom-config.h
-%%PYTHON_SITELIBDIR%%/vboxapi/__init__.py
-%%PYTHON_SITELIBDIR%%/vboxapi/__init__.pyc
-%%PYTHON_SITELIBDIR%%/vboxapi/VirtualBox_constants.py
-%%PYTHON_SITELIBDIR%%/vboxapi/VirtualBox_constants.pyc
-%%PYTHON_SITELIBDIR%%/vboxapi-1.0-py%%PYTHON_VER%%.egg-info
-%%PYTHON_SITELIBDIR%%/xpcom/__init__.py
-%%PYTHON_SITELIBDIR%%/xpcom/__init__.pyc
-%%PYTHON_SITELIBDIR%%/xpcom/components.py
-%%PYTHON_SITELIBDIR%%/xpcom/components.pyc
-%%PYTHON_SITELIBDIR%%/xpcom/file.py
-%%PYTHON_SITELIBDIR%%/xpcom/file.pyc
-%%PYTHON_SITELIBDIR%%/xpcom/nsError.py
-%%PYTHON_SITELIBDIR%%/xpcom/nsError.pyc
-%%PYTHON_SITELIBDIR%%/xpcom/primitives.py
-%%PYTHON_SITELIBDIR%%/xpcom/primitives.pyc
-%%PYTHON_SITELIBDIR%%/xpcom/vboxxpcom.py
-%%PYTHON_SITELIBDIR%%/xpcom/vboxxpcom.pyc
-%%PYTHON_SITELIBDIR%%/xpcom/xpcom_consts.py
-%%PYTHON_SITELIBDIR%%/xpcom/xpcom_consts.pyc
-%%PYTHON_SITELIBDIR%%/xpcom/xpt.py
-%%PYTHON_SITELIBDIR%%/xpcom/xpt.pyc
-%%PYTHON_SITELIBDIR%%/xpcom/client/__init__.py
-%%PYTHON_SITELIBDIR%%/xpcom/client/__init__.pyc
-%%PYTHON_SITELIBDIR%%/xpcom/server/__init__.py
-%%PYTHON_SITELIBDIR%%/xpcom/server/__init__.pyc
-%%PYTHON_SITELIBDIR%%/xpcom/server/enumerator.py
-%%PYTHON_SITELIBDIR%%/xpcom/server/enumerator.pyc
-%%PYTHON_SITELIBDIR%%/xpcom/server/factory.py
-%%PYTHON_SITELIBDIR%%/xpcom/server/factory.pyc
-%%PYTHON_SITELIBDIR%%/xpcom/server/loader.py
-%%PYTHON_SITELIBDIR%%/xpcom/server/loader.pyc
-%%PYTHON_SITELIBDIR%%/xpcom/server/module.py
-%%PYTHON_SITELIBDIR%%/xpcom/server/module.pyc
-%%PYTHON_SITELIBDIR%%/xpcom/server/policy.py
-%%PYTHON_SITELIBDIR%%/xpcom/server/policy.pyc
-@dirrm %%PYTHON_SITELIBDIR%%/xpcom/server
-@dirrm %%PYTHON_SITELIBDIR%%/xpcom/client
-@dirrm %%PYTHON_SITELIBDIR%%/xpcom
-@dirrm %%PYTHON_SITELIBDIR%%/vboxapi
-@dirrm include/virtualbox/xpcom
-@dirrm include/virtualbox/string
-@dirrm include/virtualbox/nsprpub/private
-@dirrm include/virtualbox/nsprpub/obsolete
-@dirrm include/virtualbox/nsprpub/md
-@dirrm include/virtualbox/nsprpub
-@dirrm include/virtualbox/ipcd
-@dirrm include/virtualbox
-%%NLS%%@dirrm %%DATADIR%%/nls
-@dirrm %%DATADIR%%/samples
-@dirrm %%DATADIR%%/idl
-@dirrm %%DATADIR%%
-%%QT4%%@dirrmtry share/icons/hicolor/48x48/apps
-%%QT4%%@dirrmtry share/icons/hicolor/48x48
-%%QT4%%@dirrmtry share/icons/hicolor
-%%QT4%%@dirrmtry share/icons
-%%QT4%%@dirrmtry share/applications
-@dirrm lib/virtualbox/components
-%%GUESTADDITIONS%%@dirrm lib/virtualbox/additions
-@dirrm lib/virtualbox
-@cwd /
-%%KMODDIR%%/vboxdrv.ko
-%%KMODDIR%%/vboxnetadp.ko
-%%KMODDIR%%/vboxnetflt.ko