diff options
Diffstat (limited to 'emulators/virtualbox-ose-70')
9 files changed, 152 insertions, 30 deletions
diff --git a/emulators/virtualbox-ose-70/Makefile b/emulators/virtualbox-ose-70/Makefile index e785466e8721..482fc5725a82 100644 --- a/emulators/virtualbox-ose-70/Makefile +++ b/emulators/virtualbox-ose-70/Makefile @@ -1,6 +1,6 @@ PORTNAME= virtualbox-ose DISTVERSION= 7.0.26 -PORTREVISION?= 0 +PORTREVISION?= 2 CATEGORIES= emulators MASTER_SITES= https://download.virtualbox.org/virtualbox/${DISTVERSION}/:src \ LOCAL/vvd:docs @@ -28,7 +28,7 @@ LIB_DEPENDS= libpng.so:graphics/png \ libcurl.so:ftp/curl RUN_DEPENDS= ${LOCALBASE}/etc/rc.d/vboxnet:emulators/virtualbox-ose-kmod-70 -USES= compiler:c++14-lang cpe gnome iconv qt:5 pkgconfig ssl tar:bzip2 +USES= compiler:c++14-lang cpe gnome iconv pkgconfig qt:5 ssl tar:bzip2 CPE_VENDOR= oracle CPE_PRODUCT= vm_virtualbox USE_BINUTILS= yes @@ -77,8 +77,9 @@ PLIST_SUB= GUEST_VER=${DISTVERSION} \ SLAVE_PORT?= no -OPTIONS_DEFINE= AIO ALSA DBUS DEBUG DOCS GUESTADDITIONS NLS PULSEAUDIO \ - PYTHON QT5 R0LOGGING UDPTUNNEL VBOXIMG VDE VNC WEBSERVICE VPX X11 +OPTIONS_DEFINE= AIO ALSA DBUS DEBUG DOCS GUESTADDITIONS NLS OGG PULSEAUDIO \ + PYTHON QT5 R0LOGGING UDPTUNNEL VBOXIMG VDE VNC VORBIS VPX \ + WEBSERVICE X11 OPTIONS_DEFAULT= AIO DBUS QT5 UDPTUNNEL VNC WEBSERVICE X11 .if ${SLAVE_PORT} == no OPTIONS_DEFAULT+= PYTHON @@ -92,12 +93,14 @@ AIO_DESC= Enable Asyncronous IO support (check pkg-message) DEBUG_DESC= Debug symbols, additional logs and assertions GUESTADDITIONS_DESC= Build with Guest Additions NLS_DESC= Native language support (requires QT5) +OGG_DESC= Use libogg from audio/libogg instead of bundled one QT5_DESC= Build with QT5 frontend (requires X11) R0LOGGING_DESC= Enable R0 logging (requires DEBUG) UDPTUNNEL_DESC= Build with UDP tunnel support VBOXIMG_DESC= Build vboximg-mount (requires fuse-libs) VDE_DESC= Build with VDE support VNC_DESC= Build with VNC support +VORBIS_DESC= Use libvorbis from audio/libvorbis instead of bundled one VPX_DESC= Use libvpx for video recording WEBSERVICE_DESC= Build Webservice @@ -107,6 +110,8 @@ DBUS_LIB_DEPENDS= libdbus-1.so:devel/dbus DBUS_CONFIGURE_OFF= --disable-dbus DEBUG_CONFIGURE_ON= --build-debug NLS_IMPLIES= QT5 +OGG_LIB_DEPENDS= libogg.so:audio/libogg +OGG_CONFIGURE_ON= --enable-libogg PULSEAUDIO_LIB_DEPENDS= libpulse.so:audio/pulseaudio PULSEAUDIO_CONFIGURE_OFF= --disable-pulse PYTHON_USES= python @@ -127,6 +132,9 @@ VDE_RUN_DEPENDS= vde_switch:net/vde2 VDE_CONFIGURE_ON= --enable-vde VNC_LIB_DEPENDS= libvncserver.so:net/libvncserver VNC_CONFIGURE_ON= --enable-vnc +VORBIS_LIB_DEPENDS= libvorbis.so:audio/libvorbis \ + libvorbisenc.so:audio/libvorbis +VORBIS_CONFIGURE_ON= --enable-libvorbis VPX_LIB_DEPENDS= libvpx.so:multimedia/libvpx VPX_CONFIGURE_OFF= --disable-libvpx WEBSERVICE_BUILD_DEPENDS= soapcpp2:devel/gsoap diff --git a/emulators/virtualbox-ose-70/files/patch-configure b/emulators/virtualbox-ose-70/files/patch-configure index fe0f4247089b..992770166b0f 100644 --- a/emulators/virtualbox-ose-70/files/patch-configure +++ b/emulators/virtualbox-ose-70/files/patch-configure @@ -1,6 +1,6 @@ ---- configure.orig 2024-10-10 20:19:24.000000000 +0200 -+++ configure 2024-12-27 13:12:46.010746000 +0100 -@@ -154,10 +154,14 @@ +--- configure.orig 2025-04-11 11:59:42 UTC ++++ configure +@@ -154,10 +154,14 @@ if [ "$OS" = "freebsd" ]; then if [ "$OS" = "freebsd" ]; then INCCURL="-I/usr/local/include" LIBCURL="-L/usr/local/lib -lcurl" @@ -15,7 +15,7 @@ else INCCURL="" LIBCURL="-lcurl" -@@ -1207,6 +1211,9 @@ +@@ -1207,6 +1211,9 @@ extern "C" int main(int argc, char** argv) printf("found version %d.%d.%d", SDL_MAJOR_VERSION, SDL_MINOR_VERSION, SDL_PATCHLEVEL); #if SDL_VERSION_ATLEAST(1,2,7) @@ -25,7 +25,7 @@ printf(", OK.\n"); return 0; #else -@@ -1291,7 +1298,7 @@ +@@ -1291,7 +1298,7 @@ EOF #endif } EOF @@ -34,7 +34,7 @@ test_execute fi } -@@ -1605,6 +1612,7 @@ +@@ -1605,6 +1612,7 @@ EOF FLGQT5=`pkg-config Qt5Core --cflags` # gcc 4.8 is able to compile with C++11 (see also VBOX_GCC_std in Config.kmk) [ $(($cc_maj * 100 + $cc_min)) -ge 408 ] && FLGQT5="$FLGQT5 -std=c++11" @@ -42,7 +42,28 @@ INCQT5=`strip_I "$FLGQT5"` LIBDIR5=`pkg-config Qt5Core --variable=libdir` LIBQT5=`pkg-config Qt5Core Qt5Gui --libs` -@@ -2180,8 +2188,8 @@ +@@ -1861,9 +1869,9 @@ check_libvorbis() + if which_wrapper pkg-config > /dev/null; then + libvorbis_ver=`pkg-config vorbis --modversion 2>> $LOG` + if [ $? -eq 0 ]; then +- FLGVRB=`pkg-config vorbis --cflags` ++ FLGVRB=`pkg-config vorbis vorbisenc --cflags` + INCVRB=`strip_I "$FLGVRB"` +- LIBVRB=`pkg-config vorbis --libs` ++ LIBVRB=`pkg-config vorbis vorbisenc --libs` + fi + cat > $ODIR.tmp_src.cc << EOF + #include <cstdio> +@@ -1913,7 +1921,7 @@ EOF + return 0; + } + EOF +- [ -n "$INCOGG" ] && I_INCVRB=`prefix_I "$INCOGG"` ++ [ -n "$INCOGG" ] && I_INCOGG=`prefix_I "$INCOGG"` + if test_compile "$LIBOGG $I_INCOGG" ogg ogg nofatal; then + if test_execute; then + cnf_append "SDK_VBoxLibOgg_INCS" "$INCOGG" +@@ -2180,8 +2188,8 @@ EOF echo "compiling the following source file:" >> $LOG cat $ODIR.tmp_src.cc >> $LOG echo "using the following command line:" >> $LOG @@ -53,7 +74,7 @@ if [ $? -eq 0 ]; then found=1 break -@@ -2297,7 +2305,7 @@ +@@ -2297,7 +2305,7 @@ check_gsoap() else cnf_append "VBOX_GSOAP_CXX_SOURCES" "" fi @@ -62,7 +83,7 @@ gsoap_version=`pkg-config gsoapssl++ --modversion` log_success "found version $gsoap_version" return -@@ -2661,7 +2669,7 @@ +@@ -2661,7 +2669,7 @@ for option in "$@"; do --with-openssl-dir=*) OPENSSLDIR=`echo $option | cut -d'=' -f2` INCCRYPTO="-I${OPENSSLDIR}/include" @@ -71,7 +92,7 @@ # On Darwin (at least for macports) static OpenSSL also needs zlib. [ "$OS" = "darwin" ] && LIBCRYPTO="$LIBCRYPTO ${OPENSSLDIR}/lib/libz.a" # On Linux static OpenSSL typically needs a few additional libraries. -@@ -3028,12 +3036,22 @@ +@@ -3028,12 +3036,22 @@ if [ $ONLY_ADDITIONS -eq 0 ]; then [ $WITH_JAVA -eq 1 ] && check_java # PulseAudio @@ -100,7 +121,7 @@ fi fi -@@ -3049,14 +3067,6 @@ +@@ -3049,14 +3067,6 @@ if [ "$OS" = "linux" ]; then cnf_append "VBOX_WITHOUT_LINUX_TEST_BUILDS" "1" fi if [ $ONLY_ADDITIONS -eq 0 ]; then diff --git a/emulators/virtualbox-ose-70/files/patch-src_VBox_Additions_freebsd_mount__vboxvfs_Makefile.kmk b/emulators/virtualbox-ose-70/files/patch-src_VBox_Additions_freebsd_mount__vboxvfs_Makefile.kmk index 4d327e1089b1..270472c045e3 100644 --- a/emulators/virtualbox-ose-70/files/patch-src_VBox_Additions_freebsd_mount__vboxvfs_Makefile.kmk +++ b/emulators/virtualbox-ose-70/files/patch-src_VBox_Additions_freebsd_mount__vboxvfs_Makefile.kmk @@ -1,6 +1,6 @@ ---- src/VBox/Additions/freebsd/mount_vboxvfs/Makefile.kmk.orig 2018-11-29 19:03:21 UTC +--- src/VBox/Additions/freebsd/mount_vboxvfs/Makefile.kmk.orig 2025-05-11 03:54:13 UTC +++ src/VBox/Additions/freebsd/mount_vboxvfs/Makefile.kmk -@@ -0,0 +1,23 @@ +@@ -0,0 +1,28 @@ +# $Id: Makefile.kmk $ +## @file +# Sub-Makefile for the FreeBSD Shared folder mount utility. @@ -19,8 +19,13 @@ + +PROGRAMS += mount_vboxvfs +mount_vboxvfs_TEMPLATE = NewVBoxGuestR3Exe -+mount_vboxvfs_SOURCES = $(MOUNT)/getmntopts.c \ -+ mount_vboxvfs.c ++mount_vboxvfs_SOURCES = mount_vboxvfs.c ++ ++ifdef HAVE_MNTOPTS_IN_LIBUTIL ++mount_vboxvfs_LIBS = util ++else ++mount_vboxvfs_SOURCES += $(MOUNT)/getmntopts.c ++endif + +include $(FILE_KBUILD_SUB_FOOTER) + diff --git a/emulators/virtualbox-ose-70/files/patch-src_VBox_Devices_Graphics_DevVGA-SVGA.cpp b/emulators/virtualbox-ose-70/files/patch-src_VBox_Devices_Graphics_DevVGA-SVGA.cpp new file mode 100644 index 000000000000..aa74b95e2303 --- /dev/null +++ b/emulators/virtualbox-ose-70/files/patch-src_VBox_Devices_Graphics_DevVGA-SVGA.cpp @@ -0,0 +1,20 @@ +--- src/VBox/Devices/Graphics/DevVGA-SVGA.cpp.orig 2025-04-11 12:09:20 UTC ++++ src/VBox/Devices/Graphics/DevVGA-SVGA.cpp +@@ -178,7 +178,7 @@ + # ifdef RT_OS_DARWIN + # include "DevVGA-SVGA3d-cocoa.h" + # endif +-# ifdef RT_OS_LINUX ++# if defined(RT_OS_FREEBSD) || defined(RT_OS_LINUX) + # ifdef IN_RING3 + # include "DevVGA-SVGA3d-glLdr.h" + # endif +@@ -7153,7 +7153,7 @@ static void vmsvgaR3PowerOnDevice(PPDMDEVINS pDevIns, + } + # endif + +-# if defined(VBOX_WITH_VMSVGA3D) && defined(RT_OS_LINUX) ++# if defined(VBOX_WITH_VMSVGA3D) && (defined(RT_OS_FREEBSD) || defined(RT_OS_LINUX)) + if (pThis->svga.f3DEnabled) + { + /* The FIFO thread may use X API for accelerated screen output. */ diff --git a/emulators/virtualbox-ose-70/files/patch-src_VBox_Devices_Graphics_DevVGA-SVGA3d-dx-dx11.cpp b/emulators/virtualbox-ose-70/files/patch-src_VBox_Devices_Graphics_DevVGA-SVGA3d-dx-dx11.cpp new file mode 100644 index 000000000000..8592bccdc8fc --- /dev/null +++ b/emulators/virtualbox-ose-70/files/patch-src_VBox_Devices_Graphics_DevVGA-SVGA3d-dx-dx11.cpp @@ -0,0 +1,11 @@ +--- src/VBox/Devices/Graphics/DevVGA-SVGA3d-dx-dx11.cpp.orig 2025-04-11 12:09:20 UTC ++++ src/VBox/Devices/Graphics/DevVGA-SVGA3d-dx-dx11.cpp +@@ -3111,7 +3111,7 @@ static DECLCALLBACK(int) vmsvga3dBackInit(PPDMDEVINS p + RT_NOREF(pDevIns, pThis); + + int rc; +-#ifdef RT_OS_LINUX /** @todo Remove, this is currently needed for loading the X11 library in order to call XInitThreads(). */ ++#if defined(RT_OS_FREEBSD) || defined(RT_OS_LINUX) /** @todo Remove, this is currently needed for loading the X11 library in order to call XInitThreads(). */ + rc = glLdrInit(pDevIns); + if (RT_FAILURE(rc)) + { diff --git a/emulators/virtualbox-ose-70/files/patch-src_VBox_Devices_Graphics_DevVGA-SVGA3d-glLdr.cpp b/emulators/virtualbox-ose-70/files/patch-src_VBox_Devices_Graphics_DevVGA-SVGA3d-glLdr.cpp index c9574654562d..caa97030f41c 100644 --- a/emulators/virtualbox-ose-70/files/patch-src_VBox_Devices_Graphics_DevVGA-SVGA3d-glLdr.cpp +++ b/emulators/virtualbox-ose-70/files/patch-src_VBox_Devices_Graphics_DevVGA-SVGA3d-glLdr.cpp @@ -1,6 +1,6 @@ ---- src/VBox/Devices/Graphics/DevVGA-SVGA3d-glLdr.cpp.orig 2021-01-07 15:39:16 UTC +--- src/VBox/Devices/Graphics/DevVGA-SVGA3d-glLdr.cpp.orig 2025-04-11 12:09:20 UTC +++ src/VBox/Devices/Graphics/DevVGA-SVGA3d-glLdr.cpp -@@ -186,7 +186,7 @@ int glLdrInit(PPDMDEVINS pDevIns) +@@ -196,7 +196,7 @@ int glLdrInit(PPDMDEVINS pDevIns) pfn_wglDeleteContext = 0; pfn_wglMakeCurrent = 0; pfn_wglShareLists = 0; @@ -9,7 +9,7 @@ pfn_XConfigureWindow = 0; pfn_XCloseDisplay = 0; pfn_XCreateColormap = 0; -@@ -296,7 +296,7 @@ int glLdrInit(PPDMDEVINS pDevIns) +@@ -306,7 +306,7 @@ int glLdrInit(PPDMDEVINS pDevIns) GLGETPROC_(wglDeleteContext, ""); GLGETPROC_(wglMakeCurrent, ""); GLGETPROC_(wglShareLists, ""); @@ -18,7 +18,7 @@ X11GETPROC_(XConfigureWindow); X11GETPROC_(XCloseDisplay); X11GETPROC_(XCreateColormap); -@@ -397,7 +397,7 @@ int glLdrInit(PPDMDEVINS pDevIns) +@@ -407,7 +407,7 @@ int glLdrInit(PPDMDEVINS pDevIns) GLGETPROC_(glVertexPointer, ""); GLGETPROC_(glViewport, ""); diff --git a/emulators/virtualbox-ose-70/files/patch-src_VBox_Devices_Graphics_DevVGA-SVGA3d-glLdr.h b/emulators/virtualbox-ose-70/files/patch-src_VBox_Devices_Graphics_DevVGA-SVGA3d-glLdr.h index 3069950947cd..ea1c170e8f17 100644 --- a/emulators/virtualbox-ose-70/files/patch-src_VBox_Devices_Graphics_DevVGA-SVGA3d-glLdr.h +++ b/emulators/virtualbox-ose-70/files/patch-src_VBox_Devices_Graphics_DevVGA-SVGA3d-glLdr.h @@ -1,6 +1,6 @@ ---- src/VBox/Devices/Graphics/DevVGA-SVGA3d-glLdr.h.orig 2021-01-07 15:39:17 UTC +--- src/VBox/Devices/Graphics/DevVGA-SVGA3d-glLdr.h.orig 2025-04-11 12:09:20 UTC +++ src/VBox/Devices/Graphics/DevVGA-SVGA3d-glLdr.h -@@ -338,7 +338,7 @@ GLPFN BOOL (WINAPI *pfn_wglMakeCurrent)(HDC, HGLRC); +@@ -346,7 +346,7 @@ GLPFN BOOL (WINAPI *pfn_wglShareLists)(HGLRC, HGLRC); GLPFN BOOL (WINAPI *pfn_wglShareLists)(HGLRC, HGLRC); #define wglShareLists pfn_wglShareLists diff --git a/emulators/virtualbox-ose-70/files/patch-src_VBox_Devices_Graphics_DevVGA-SVGA3d-ogl.cpp b/emulators/virtualbox-ose-70/files/patch-src_VBox_Devices_Graphics_DevVGA-SVGA3d-ogl.cpp index 96058e78ff1f..caf9d72e8e19 100644 --- a/emulators/virtualbox-ose-70/files/patch-src_VBox_Devices_Graphics_DevVGA-SVGA3d-ogl.cpp +++ b/emulators/virtualbox-ose-70/files/patch-src_VBox_Devices_Graphics_DevVGA-SVGA3d-ogl.cpp @@ -1,6 +1,6 @@ ---- src/VBox/Devices/Graphics/DevVGA-SVGA3d-ogl.cpp.orig 2021-01-07 15:39:17 UTC +--- src/VBox/Devices/Graphics/DevVGA-SVGA3d-ogl.cpp.orig 2025-04-11 12:09:20 UTC +++ src/VBox/Devices/Graphics/DevVGA-SVGA3d-ogl.cpp -@@ -1189,7 +1189,7 @@ int vmsvga3dTerminate(PVGASTATECC pThisCC) +@@ -1198,7 +1198,7 @@ static DECLCALLBACK(int) vmsvga3dBackTerminate(PVGASTA RTSemEventDestroy(pState->WndRequestSem); #elif defined(RT_OS_DARWIN) @@ -9,7 +9,7 @@ /* signal to the thread that it is supposed to exit */ pState->bTerminate = true; /* wait for it to terminate */ -@@ -3194,7 +3194,7 @@ int vmsvga3dGenerateMipmaps(PVGASTATECC pThisCC, uint3 +@@ -3216,7 +3216,7 @@ static DECLCALLBACK(int) vmsvga3dBackGenerateMipmaps(P } @@ -18,7 +18,7 @@ /** * X11 event handling thread. * -@@ -3224,7 +3224,7 @@ DECLCALLBACK(int) vmsvga3dXEventThread(RTTHREAD hThrea +@@ -3246,7 +3246,7 @@ DECLCALLBACK(int) vmsvga3dXEventThread(RTTHREAD hThrea } return VINF_SUCCESS; } @@ -27,7 +27,25 @@ /** -@@ -4052,7 +4052,7 @@ static int vmsvga3dContextDestroyOgl(PVGASTATECC pThis +@@ -3484,7 +3484,7 @@ int vmsvga3dContextDefineOgl(PVGASTATECC pThisCC, uint + return VINF_SUCCESS; + } + +-#if defined(RT_OS_LINUX) ++#if defined(RT_OS_FREEBSD) || defined(RT_OS_LINUX) + /* + * HW accelerated graphics output. + */ +@@ -3976,7 +3976,7 @@ static DECLCALLBACK(int) vmsvga3dBackSurfaceBlitToScre + return VINF_SUCCESS; + } + +-#else /* !RT_OS_LINUX */ ++#else /* !RT_OS_FREEBSD && !RT_OS_LINUX */ + + static DECLCALLBACK(int) vmsvga3dBackDefineScreen(PVGASTATE pThis, PVGASTATECC pThisCC, VMSVGASCREENOBJECT *pScreen) + { +@@ -4096,7 +4096,7 @@ static int vmsvga3dContextDestroyOgl(PVGASTATECC pThis AssertRC(rc); #elif defined(RT_OS_DARWIN) vmsvga3dCocoaDestroyViewAndContext(pContext->cocoaView, pContext->cocoaContext); diff --git a/emulators/virtualbox-ose-70/files/patch-src_VBox_Runtime_r3_freebsd_systemmem-freebsd.cpp b/emulators/virtualbox-ose-70/files/patch-src_VBox_Runtime_r3_freebsd_systemmem-freebsd.cpp new file mode 100644 index 000000000000..87ae993446a3 --- /dev/null +++ b/emulators/virtualbox-ose-70/files/patch-src_VBox_Runtime_r3_freebsd_systemmem-freebsd.cpp @@ -0,0 +1,39 @@ +--- src/VBox/Runtime/r3/freebsd/systemmem-freebsd.cpp.orig 2025-04-14 17:59:18 UTC ++++ src/VBox/Runtime/r3/freebsd/systemmem-freebsd.cpp +@@ -75,7 +75,6 @@ RTDECL(int) RTSystemQueryAvailableRam(uint64_t *pcb) + u_int cPagesMemFree = 0; + u_int cPagesMemInactive = 0; + u_int cPagesMemCached = 0; +- u_int cPagesMemUsed = 0; + int cbPage = 0; + size_t cbParameter; + int cProcessed = 0; +@@ -83,25 +82,23 @@ RTDECL(int) RTSystemQueryAvailableRam(uint64_t *pcb) + cbParameter = sizeof(cPagesMemFree); + if (sysctlbyname("vm.stats.vm.v_free_count", &cPagesMemFree, &cbParameter, NULL, 0)) + rc = RTErrConvertFromErrno(errno); +- cbParameter = sizeof(cPagesMemUsed); +- if ( RT_SUCCESS(rc) +- && sysctlbyname("vm.stats.vm.v_active_count", &cPagesMemUsed, &cbParameter, NULL, 0)) +- rc = RTErrConvertFromErrno(errno); + cbParameter = sizeof(cPagesMemInactive); + if ( RT_SUCCESS(rc) + && sysctlbyname("vm.stats.vm.v_inactive_count", &cPagesMemInactive, &cbParameter, NULL, 0)) + rc = RTErrConvertFromErrno(errno); ++#if __FreeBSD_version < 1200016 + cbParameter = sizeof(cPagesMemCached); + if ( RT_SUCCESS(rc) + && sysctlbyname("vm.stats.vm.v_cache_count", &cPagesMemCached, &cbParameter, NULL, 0)) + rc = RTErrConvertFromErrno(errno); ++#endif + cbParameter = sizeof(cbPage); + if ( RT_SUCCESS(rc) + && sysctlbyname("hw.pagesize", &cbPage, &cbParameter, NULL, 0)) + rc = RTErrConvertFromErrno(errno); + + if (RT_SUCCESS(rc)) +- *pcb = (cPagesMemFree + cPagesMemInactive + cPagesMemCached ) * cbPage; ++ *pcb = ((uint64_t)cPagesMemFree + cPagesMemInactive + cPagesMemCached) * cbPage; + + return rc; + } |