summaryrefslogtreecommitdiffstats
path: root/debian/patches
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-07 16:49:11 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-07 16:49:11 +0000
commitf4f3a659b7663cf52c2f2e1fa8e58ed4000e29c9 (patch)
tree46477e488553a670f4b0346080d3f9a635672104 /debian/patches
parentAdding upstream version 7.0.6-dfsg. (diff)
downloadvirtualbox-f4f3a659b7663cf52c2f2e1fa8e58ed4000e29c9.tar.xz
virtualbox-f4f3a659b7663cf52c2f2e1fa8e58ed4000e29c9.zip
Adding debian version 7.0.6-dfsg-1.debian/7.0.6-dfsg-1debian
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'debian/patches')
-rw-r--r--debian/patches/01-build-arch.patch14
-rw-r--r--debian/patches/02-gsoap-build-fix.patch14
-rw-r--r--debian/patches/04-vboxdrv-references.patch77
-rw-r--r--debian/patches/06-xsession.patch22
-rw-r--r--debian/patches/07-vboxnetflt-reference.patch16
-rw-r--r--debian/patches/12-make-module.patch14
-rw-r--r--debian/patches/13-module-mismatch.patch22
-rw-r--r--debian/patches/16-no-update.patch110
-rw-r--r--debian/patches/23-remove-invalid-chars-check.patch18
-rw-r--r--debian/patches/27-hide-host-cache-warning.patch43
-rw-r--r--debian/patches/28-no-selinux-fedora.patch18
-rw-r--r--debian/patches/29-fix-ftbfs-as-needed.patch16
-rw-r--r--debian/patches/32-disable-guest-version-check.patch16
-rw-r--r--debian/patches/35-libvdeplug-soname.patch24
-rw-r--r--debian/patches/36-fix-vnc-version-string.patch22
-rw-r--r--debian/patches/37-do-not-run-if-not-in-vm.patch29
-rw-r--r--debian/patches/python3.11.patch13
-rw-r--r--debian/patches/series17
18 files changed, 505 insertions, 0 deletions
diff --git a/debian/patches/01-build-arch.patch b/debian/patches/01-build-arch.patch
new file mode 100644
index 00000000..47e174ce
--- /dev/null
+++ b/debian/patches/01-build-arch.patch
@@ -0,0 +1,14 @@
+Description: Correctly check build architecture.
+Author: Michael Meskes <meskes@debian.org>
+
+--- a/configure
++++ b/configure
+@@ -379,7 +379,7 @@ test_execute_path()
+ check_environment()
+ {
+ test_header environment
+- BUILD_CPU=`uname -m`
++ BUILD_CPU=`dpkg-architecture -qDEB_HOST_GNU_CPU`
+ [ "$OS" = "solaris" ] && BUILD_CPU=`isainfo | cut -f 1 -d ' '`
+ case "$BUILD_CPU" in
+ i[3456789]86|x86|i86pc|BePC)
diff --git a/debian/patches/02-gsoap-build-fix.patch b/debian/patches/02-gsoap-build-fix.patch
new file mode 100644
index 00000000..27177869
--- /dev/null
+++ b/debian/patches/02-gsoap-build-fix.patch
@@ -0,0 +1,14 @@
+Interim build fix for gsoap > 2.8.13
+Index: virtualbox-git-orig/src/VBox/Main/webservice/Makefile.kmk
+===================================================================
+--- virtualbox-git-orig.orig/src/VBox/Main/webservice/Makefile.kmk 2013-12-02 12:32:51.211124975 -0500
++++ virtualbox-git-orig/src/VBox/Main/webservice/Makefile.kmk 2013-12-02 12:36:04.531133954 -0500
+@@ -848,7 +848,7 @@
+ $(RECOMPILE_ON_MAKEFILE_CURRENT) | $$(dir $$@)
+ $(call MSG_GENERATE,,lots of files,$(GSOAPH_RELEVANT))
+ $(RM) -f $@
+- $(REDIRECT) -C $(VBOXWEB_OUT_DIR) -- $(VBOX_SOAPCPP2) $(VBOXWEB_SOAPCPP2_SKIP_FILES) -L -2 -w -I$(VBOX_PATH_GSOAP_IMPORT) $(GSOAPH_RELEVANT)
++ $(REDIRECT) -C $(VBOXWEB_OUT_DIR) -- $(VBOX_SOAPCPP2) $(VBOXWEB_SOAPCPP2_SKIP_FILES) -z1 -L -2 -w -I$(VBOX_PATH_GSOAP_IMPORT) $(GSOAPH_RELEVANT)
+ ifeq ($(KBUILD_TARGET),win) # MSC -Wall workaround.
+ $(CP) -f "$(VBOXWEB_SOAP_CLIENT_H)" "$(VBOXWEB_SOAP_CLIENT_H).tmp"
+ $(SED) -f $(VBOX_PATH_WEBSERVICE)/stdsoap2.sed --output "$(VBOXWEB_SOAP_CLIENT_H)" "$(VBOXWEB_SOAP_CLIENT_H).tmp"
diff --git a/debian/patches/04-vboxdrv-references.patch b/debian/patches/04-vboxdrv-references.patch
new file mode 100644
index 00000000..ce24d1fe
--- /dev/null
+++ b/debian/patches/04-vboxdrv-references.patch
@@ -0,0 +1,77 @@
+Description: Change error messages for vboxdrv failure, according to virtualbox-dkms.
+Author: Daniel Hahler <ubuntu@thequod.de>
+
+Index: virtualbox/src/VBox/VMM/VMMR3/VM.cpp
+===================================================================
+--- virtualbox.orig/src/VBox/VMM/VMMR3/VM.cpp
++++ virtualbox/src/VBox/VMM/VMMR3/VM.cpp
+@@ -276,12 +276,8 @@
+
+ #ifdef RT_OS_LINUX
+ case VERR_SUPDRV_COMPONENT_NOT_FOUND:
+- pszError = N_("One of the kernel modules was not successfully loaded. Make sure "
+- "that VirtualBox is correctly installed, and if you are using EFI "
+- "Secure Boot that the modules are signed if necessary in the right "
+- "way for your host system. Then try to recompile and reload the "
+- "kernel modules by executing "
+- "'/sbin/vboxconfig' as root");
++ pszError = N_("Please install the virtualbox-dkms package "
++ "and execute 'modprobe vboxdrv' as root");
+ break;
+ #endif
+
+@@ -347,12 +343,8 @@
+ {
+ case VERR_VM_DRIVER_LOAD_ERROR:
+ #ifdef RT_OS_LINUX
+- pszError = N_("VirtualBox kernel driver not loaded. The vboxdrv kernel module "
+- "was either not loaded, /dev/vboxdrv is not set up properly, "
+- "or you are using EFI Secure Boot and the module is not signed "
+- "in the right way for your system. If necessary, try setting up "
+- "the kernel module again by executing "
+- "'/sbin/vboxconfig' as root");
++ pszError = N_("Please install the virtualbox-dkms package "
++ "and execute 'modprobe vboxdrv' as root");
+ #else
+ pszError = N_("VirtualBox kernel driver not loaded");
+ #endif
+@@ -391,12 +383,8 @@
+ case VERR_INVALID_HANDLE: /** @todo track down and fix this error. */
+ case VERR_VM_DRIVER_NOT_INSTALLED:
+ #ifdef RT_OS_LINUX
+- pszError = N_("VirtualBox kernel driver not Installed. The vboxdrv kernel module "
+- "was either not loaded, /dev/vboxdrv is not set up properly, "
+- "or you are using EFI Secure Boot and the module is not signed "
+- "in the right way for your system. If necessary, try setting up "
+- "the kernel module again by executing "
+- "'/sbin/vboxconfig' as root");
++ pszError = N_("Please install the virtualbox-dkms package "
++ "and execute 'modprobe vboxdrv' as root");
+ #else
+ pszError = N_("VirtualBox kernel driver not installed");
+ #endif
+Index: virtualbox/src/VBox/Frontends/VirtualBox/src/main.cpp
+===================================================================
+--- virtualbox.orig/src/VBox/Frontends/VirtualBox/src/main.cpp
++++ virtualbox/src/VBox/Frontends/VirtualBox/src/main.cpp
+@@ -98,8 +98,9 @@
+
+ QString g_QStrHintLinuxNoDriver = QApplication::tr(
+ "The VirtualBox Linux kernel driver is either not loaded or not set "
+- "up correctly. Please try setting it up again by executing<br/><br/>"
+- " <font color=blue>'/sbin/vboxconfig'</font><br/><br/>"
++ "up correctly. Please reinstall virtualbox-dkms "
++ "package and load the kernel module by executing<br/><br/>"
++ " <font color=blue>'modprobe vboxdrv'</font><br/><br/>"
+ "as root.<br/><br/>"
+ "If your system has EFI Secure Boot enabled you may also need to sign "
+ "the kernel modules (vboxdrv, vboxnetflt, vboxnetadp, vboxpci) before "
+@@ -118,7 +119,7 @@
+ "The VirtualBox kernel modules do not match this version of "
+ "VirtualBox. The installation of VirtualBox was apparently not "
+ "successful. Executing<br/><br/>"
+- " <font color=blue>'/sbin/vboxconfig'</font><br/><br/>"
++ " <font color=blue>'modprobe vboxdrv'</font><br/><br/>"
+ "may correct this. Make sure that you are not mixing builds "
+ "of VirtualBox from different sources."
+ );
diff --git a/debian/patches/06-xsession.patch b/debian/patches/06-xsession.patch
new file mode 100644
index 00000000..9a15d84a
--- /dev/null
+++ b/debian/patches/06-xsession.patch
@@ -0,0 +1,22 @@
+Description: Make Xsession.d script ignore errors.
+Author: Michael Meskes <meskes@debian.org>
+
+Index: virtualbox/src/VBox/Additions/x11/Installer/98vboxadd-xclient
+===================================================================
+--- virtualbox.orig/src/VBox/Additions/x11/Installer/98vboxadd-xclient
++++ virtualbox/src/VBox/Additions/x11/Installer/98vboxadd-xclient
+@@ -40,9 +40,9 @@
+ # This script can also be triggered by a connection over SSH, which is not
+ # what we had in mind, so we do not start VBoxClient in that case. We do
+ # not use "exit" here as this script is "source"d, not executed.
+- /usr/bin/VBoxClient --clipboard
+- /usr/bin/VBoxClient --checkhostversion
+- /usr/bin/VBoxClient --seamless
+- /usr/bin/VBoxClient --draganddrop
+- /usr/bin/VBoxClient --vmsvga-session # In case VMSVGA emulation is enabled
++ /usr/bin/VBoxClient --clipboard || true
++ /usr/bin/VBoxClient --checkhostversion || true
++ /usr/bin/VBoxClient --seamless || true
++ /usr/bin/VBoxClient --draganddrop || true
++ /usr/bin/VBoxClient --vmsvga-session || true # In case VMSVGA emulation is enabled
+ fi
diff --git a/debian/patches/07-vboxnetflt-reference.patch b/debian/patches/07-vboxnetflt-reference.patch
new file mode 100644
index 00000000..742b82c2
--- /dev/null
+++ b/debian/patches/07-vboxnetflt-reference.patch
@@ -0,0 +1,16 @@
+Description: Made error message tell about missing vboxnetflt module.
+Author: Michael Meskes <meskes@debian.org>
+
+Index: virtualbox/src/VBox/Devices/Network/DrvIntNet.cpp
+===================================================================
+--- virtualbox.orig/src/VBox/Devices/Network/DrvIntNet.cpp
++++ virtualbox/src/VBox/Devices/Network/DrvIntNet.cpp
+@@ -1987,7 +1987,7 @@
+ return VERR_PDM_NO_ATTACHED_DRIVER;
+ }
+ return PDMDrvHlpVMSetError(pDrvIns, rc, RT_SRC_POS,
+- N_("Failed to open/create the internal network '%s'"), pThis->szNetwork);
++ N_("Failed to open/create the internal network '%s' (you might need to modprobe vboxnetflt to make it accessible)"), pThis->szNetwork);
+ }
+
+ AssertRelease(OpenReq.hIf != INTNET_HANDLE_INVALID);
diff --git a/debian/patches/12-make-module.patch b/debian/patches/12-make-module.patch
new file mode 100644
index 00000000..50fd0056
--- /dev/null
+++ b/debian/patches/12-make-module.patch
@@ -0,0 +1,14 @@
+Description: Fix ARCH setting in modules Makefiles.
+Author: Michael Meskes <meskes@debian.org>, Gianfranco Costamagna <locutusofborg@debian.org>
+
+--- a/src/VBox/Installer/linux/Makefile-header.gmk
++++ b/src/VBox/Installer/linux/Makefile-header.gmk
+@@ -60,7 +60,7 @@
+ #
+
+ # VBOX_KBUILD_TARGET_ARCH = amd64|x86
+-ifeq ($(filter-out x86_64 amd64 AMD64,$(shell uname -m)),)
++ifeq ($(filter-out x86_64 amd64 AMD64,$(shell dpkg-architecture -qDEB_HOST_GNU_CPU)),)
+ VBOX_KBUILD_TARGET_ARCH_DEFAULT := amd64
+ else
+ VBOX_KBUILD_TARGET_ARCH_DEFAULT := x86
diff --git a/debian/patches/13-module-mismatch.patch b/debian/patches/13-module-mismatch.patch
new file mode 100644
index 00000000..3ed9aa81
--- /dev/null
+++ b/debian/patches/13-module-mismatch.patch
@@ -0,0 +1,22 @@
+Description: Adjusts failure message with Debian specific solution.
+Author: Daniel Baumann <daniel@debian.org>
+
+Index: virtualbox/src/VBox/VMM/VMMR3/VM.cpp
+===================================================================
+--- virtualbox.orig/src/VBox/VMM/VMMR3/VM.cpp
++++ virtualbox/src/VBox/VMM/VMMR3/VM.cpp
+@@ -394,9 +394,11 @@
+ break;
+ case VERR_VERSION_MISMATCH:
+ case VERR_VM_DRIVER_VERSION_MISMATCH:
+- pszError = N_("The VirtualBox support driver which is running is from a different "
+- "version of VirtualBox. You can correct this by stopping all "
+- "running instances of VirtualBox and reinstalling the software.");
++ pszError = N_("The version of the VirtualBox kernel modules and the version of "
++ "VirtualBox application are not matching. You can correct this by "
++ "either installing the correct virtualbox-modules package "
++ "(if available) through apt-get or by building it manually with: "
++ "module-assistant auto-install virtualbox");
+ break;
+ default:
+ pszError = N_("Unknown error initializing kernel driver");
diff --git a/debian/patches/16-no-update.patch b/debian/patches/16-no-update.patch
new file mode 100644
index 00000000..c54d5a01
--- /dev/null
+++ b/debian/patches/16-no-update.patch
@@ -0,0 +1,110 @@
+
+Description: Disable "Check for Updates" action.
+Bug-Ubuntu: https://bugs.launchpad.net/bugs/272212
+Author: Daniel Hahler <ubuntu@thequod.de>, Felix Geyer <fgeyer@debian.org>, Gianfranco Costamagna <locutusofborg@debian.org>
+
+Index: virtualbox/doc/manual/en_US/user_Introduction.xml
+===================================================================
+--- virtualbox.orig/doc/manual/en_US/user_Introduction.xml
++++ virtualbox/doc/manual/en_US/user_Introduction.xml
+@@ -6090,14 +6090,14 @@
+ <xref linkend="specialcharacters"/>.
+ </para>
+ </listitem>
+-
++ <!--
+ <listitem>
+ <para>
+ <emphasis role="bold">Update.</emphasis> Enables you to
+ specify various settings for Automatic Updates.
+ </para>
+ </listitem>
+-
++ -->
+ <listitem>
+ <para>
+ <emphasis role="bold">Language.</emphasis> Enables you to
+Index: virtualbox/src/VBox/Frontends/VirtualBox/src/extradata/UIExtraDataManager.cpp
+===================================================================
+--- virtualbox.orig/src/VBox/Frontends/VirtualBox/src/extradata/UIExtraDataManager.cpp
++++ virtualbox/src/VBox/Frontends/VirtualBox/src/extradata/UIExtraDataManager.cpp
+@@ -2417,7 +2417,7 @@
+ bool UIExtraDataManager::applicationUpdateEnabled()
+ {
+ /* 'True' unless 'restriction' feature allowed: */
+- return !isFeatureAllowed(GUI_PreventApplicationUpdate);
++ return false;
+ }
+
+ QString UIExtraDataManager::applicationUpdateData()
+Index: virtualbox/src/VBox/Frontends/VirtualBox/src/settings/UISettingsDialogSpecific.cpp
+===================================================================
+--- virtualbox.orig/src/VBox/Frontends/VirtualBox/src/settings/UISettingsDialogSpecific.cpp
++++ virtualbox/src/VBox/Frontends/VirtualBox/src/settings/UISettingsDialogSpecific.cpp
+@@ -47,10 +47,10 @@
+ #ifdef VBOX_WS_WIN
+ # include "UIGlobalSettingsInterface.h"
+ #endif
+-#ifdef VBOX_GUI_WITH_NETWORK_MANAGER
+-# include "UIGlobalSettingsProxy.h"
+-# include "UIGlobalSettingsUpdate.h"
+-#endif
++//#ifdef VBOX_GUI_WITH_NETWORK_MANAGER
++//# include "UIGlobalSettingsProxy.h"
++//# include "UIGlobalSettingsUpdate.h"
++//#endif
+
+ /* GUI includes: Machine Settings: */
+ #include "UIMachineSettingsAudio.h"
+@@ -99,7 +99,7 @@
+
+ #ifdef VBOX_GUI_WITH_NETWORK_MANAGER
+ /* Update page: */
+- m_pSelector->setItemText(GlobalSettingsPageType_Update, tr("Update"));
++ //m_pSelector->setItemText(GlobalSettingsPageType_Update, tr("Update"));
+ #endif
+
+ /* Language page: */
+@@ -110,7 +110,7 @@
+
+ #ifdef VBOX_GUI_WITH_NETWORK_MANAGER
+ /* Proxy page: */
+- m_pSelector->setItemText(GlobalSettingsPageType_Proxy, tr("Proxy"));
++ //m_pSelector->setItemText(GlobalSettingsPageType_Proxy, tr("Proxy"));
+ #endif
+
+ #ifdef VBOX_WS_WIN
+@@ -226,14 +226,14 @@
+ }
+ #ifdef VBOX_GUI_WITH_NETWORK_MANAGER
+ /* Update page: */
+- case GlobalSettingsPageType_Update:
++ /*case GlobalSettingsPageType_Update:
+ {
+ pSettingsPage = new UIGlobalSettingsUpdate;
+ addItem(":/refresh_32px.png", ":/refresh_24px.png", ":/refresh_16px.png",
+ iPageIndex, "#update", pSettingsPage);
+ addPageHelpKeyword(iPageIndex, "preferences");
+ break;
+- }
++ }*/
+ #endif /* VBOX_GUI_WITH_NETWORK_MANAGER */
+ /* Language page: */
+ case GlobalSettingsPageType_Language:
+@@ -255,14 +255,14 @@
+ }
+ #ifdef VBOX_GUI_WITH_NETWORK_MANAGER
+ /* Proxy page: */
+- case GlobalSettingsPageType_Proxy:
++ /*case GlobalSettingsPageType_Proxy:
+ {
+ pSettingsPage = new UIGlobalSettingsProxy;
+ addItem(":/proxy_32px.png", ":/proxy_24px.png", ":/proxy_16px.png",
+ iPageIndex, "#proxy", pSettingsPage);
+ addPageHelpKeyword(iPageIndex, "preferences");
+ break;
+- }
++ }*/
+ #endif /* VBOX_GUI_WITH_NETWORK_MANAGER */
+ #ifdef VBOX_WS_WIN
+ /* Interface page: */
diff --git a/debian/patches/23-remove-invalid-chars-check.patch b/debian/patches/23-remove-invalid-chars-check.patch
new file mode 100644
index 00000000..0110e1c8
--- /dev/null
+++ b/debian/patches/23-remove-invalid-chars-check.patch
@@ -0,0 +1,18 @@
+Description: Remove check for invalid characters in the build path since we have fixed
+ kBuild to handle those paths starting from version 1:0.1.98svn2318-7.
+Author: Felix Geyer <fgeyer@debian.org>
+
+--- a/configure
++++ b/configure
+@@ -193,11 +193,6 @@ BUILD_TYPE="release"
+ # the restricting tool is ar (mri mode).
+ INVALID_CHARS="[^A-Za-z0-9/\\$:._-]"
+
+-if (cd `dirname $0`; pwd)|grep -q "$INVALID_CHARS"; then
+- echo "Error: VBox base path contains invalid characters!"
+- exit 1
+-fi
+-
+ # Posix /bin/sh isn't supporting echo -n. Use printf instead.
+ ECHO_N="printf"
+
diff --git a/debian/patches/27-hide-host-cache-warning.patch b/debian/patches/27-hide-host-cache-warning.patch
new file mode 100644
index 00000000..092ecd44
--- /dev/null
+++ b/debian/patches/27-hide-host-cache-warning.patch
@@ -0,0 +1,43 @@
+Description: Silently enable the host I/O cache when the image is on an ext4/XFS partition.
+ No need to warn users about it.
+Author: Felix Geyer <fgeyer@debian.org>
+
+Index: virtualbox/src/VBox/Main/src-client/ConsoleImpl2.cpp
+===================================================================
+--- virtualbox.orig/src/VBox/Main/src-client/ConsoleImpl2.cpp
++++ virtualbox/src/VBox/Main/src-client/ConsoleImpl2.cpp
+@@ -4574,34 +4574,12 @@ int Console::i_checkMediumLocation(IMedium *pMedium, bool *pfUseHostIOCache)
+ if ( enmFsTypeFile == RTFSTYPE_EXT4
+ || enmFsTypeFile == RTFSTYPE_XFS)
+ {
+- i_atVMRuntimeErrorCallbackF(0, "Ext4PartitionDetected",
+- N_("The host I/O cache for at least one controller is disabled "
+- "and the medium '%s' for this VM "
+- "is located on an %s partition. There is a known Linux "
+- "kernel bug which can lead to the corruption of the virtual "
+- "disk image under these conditions.\n"
+- "Either enable the host I/O cache permanently in the VM "
+- "settings or put the disk image and the snapshot folder "
+- "onto a different file system.\n"
+- "The host I/O cache will now be enabled for this medium"),
+- strFile.c_str(), enmFsTypeFile == RTFSTYPE_EXT4 ? "ext4" : "xfs");
+ *pfUseHostIOCache = true;
+ }
+ else if ( ( enmFsTypeSnap == RTFSTYPE_EXT4
+ || enmFsTypeSnap == RTFSTYPE_XFS)
+ && !mfSnapshotFolderExt4WarningShown)
+ {
+- i_atVMRuntimeErrorCallbackF(0, "Ext4PartitionDetected",
+- N_("The host I/O cache for at least one controller is disabled "
+- "and the snapshot folder for this VM "
+- "is located on an %s partition. There is a known Linux "
+- "kernel bug which can lead to the corruption of the virtual "
+- "disk image under these conditions.\n"
+- "Either enable the host I/O cache permanently in the VM "
+- "settings or put the disk image and the snapshot folder "
+- "onto a different file system.\n"
+- "The host I/O cache will now be enabled for this medium"),
+- enmFsTypeSnap == RTFSTYPE_EXT4 ? "ext4" : "xfs");
+ *pfUseHostIOCache = true;
+ mfSnapshotFolderExt4WarningShown = true;
+ }
diff --git a/debian/patches/28-no-selinux-fedora.patch b/debian/patches/28-no-selinux-fedora.patch
new file mode 100644
index 00000000..c57e0a63
--- /dev/null
+++ b/debian/patches/28-no-selinux-fedora.patch
@@ -0,0 +1,18 @@
+Description: Don't install the selinux-fedora modules.
+Author: Felix Geyer <fgeyer@debian.org>
+
+Index: virtualbox/src/VBox/Additions/linux/Makefile.kmk
+===================================================================
+--- virtualbox.orig/src/VBox/Additions/linux/Makefile.kmk
++++ virtualbox/src/VBox/Additions/linux/Makefile.kmk
+@@ -301,9 +301,7 @@
+ lnx_add_inst-noexec_SOURCES = \
+ $(VBOX_REL_X11_ADD_INST)vboxclient.desktop \
+ $(VBOX_REL_X11_ADD_INST)vboxvideo.ids \
+- $(if $(VBOX_WITH_LIGHTDM_GREETER_PACKING),lightdm-greeter/vbox-greeter.desktop,) \
+- selinux-fedora/vbox_x11.pp \
+- selinux-fedora/vbox_accel.pp
++ $(if $(VBOX_WITH_LIGHTDM_GREETER_PACKING),lightdm-greeter/vbox-greeter.desktop,)
+
+ INSTALLS += lnx_add_inst-license
+ lnx_add_inst-license_INST = $(VBOX_LNX_ADD_INST_OUT_DIR)
diff --git a/debian/patches/29-fix-ftbfs-as-needed.patch b/debian/patches/29-fix-ftbfs-as-needed.patch
new file mode 100644
index 00000000..690a0ab9
--- /dev/null
+++ b/debian/patches/29-fix-ftbfs-as-needed.patch
@@ -0,0 +1,16 @@
+Description: Fix FTBFS with ld --as-needed.
+Origin: vendor, http://sources.gentoo.org/cgi-bin/viewvc.cgi/gentoo-x86/app-emulation/virtualbox/files/virtualbox-4.1.4-asneeded.patch?revision=1.2&view=markup
+
+Index: virtualbox/Config.kmk
+===================================================================
+--- virtualbox.orig/Config.kmk 2015-04-02 15:46:59.611743003 +0200
++++ virtualbox/Config.kmk 2015-04-02 15:46:59.611743003 +0200
+@@ -6658,7 +6658,7 @@
+ TEMPLATE_VBoxBldProg_LDFLAGS.amd64 = -m64
+ TEMPLATE_VBoxBldProg_LDFLAGS.sparc64 = -m64
+ ifeq ($(KBUILD_HOST),linux)
+-TEMPLATE_VBoxBldProg_LIBS = pthread m rt dl
++TEMPLATE_VBoxBldProg_LIBS = pthread m rt dl crypt
+ else ifeq ($(KBUILD_HOST),os2)
+ TEMPLATE_VBoxBldProg_TOOL = GXX3OMF
+ TEMPLATE_VBoxBldProg_LIBS = socket iconv
diff --git a/debian/patches/32-disable-guest-version-check.patch b/debian/patches/32-disable-guest-version-check.patch
new file mode 100644
index 00000000..e7339240
--- /dev/null
+++ b/debian/patches/32-disable-guest-version-check.patch
@@ -0,0 +1,16 @@
+Description: Disable notifications about outdated guest additions.
+Author: Felix Geyer <fgeyer@debian.org>
+
+Index: virtualbox/src/VBox/Additions/x11/VBoxClient/hostversion.cpp
+===================================================================
+--- virtualbox.orig/src/VBox/Additions/x11/VBoxClient/hostversion.cpp
++++ virtualbox/src/VBox/Additions/x11/VBoxClient/hostversion.cpp
+@@ -94,7 +94,7 @@
+ * Guest Additions. Distributors are encouraged to customise this. */
+ RTStrPrintf(szMsg, sizeof(szMsg), "Your virtual machine is currently running the Guest Additions version %s. Since you are running a version of the Guest Additions provided by the operating system you installed in the virtual machine we recommend that you update it to at least version %s using that system's update features, or alternatively that you remove this version and then install the " VBOX_VENDOR_SHORT " Guest Additions package using the install option from the Devices menu. Please consult the documentation for the operating system you are running to find out how to update or remove the current Guest Additions package.", pszGuestVersion, pszHostVersion);
+ # endif /* VBOX_OSE */
+- rc = VBClShowNotify(szTitle, szMsg);
++ //rc = VBClShowNotify(szTitle, szMsg);
+ }
+
+ /* Store host version to not notify again */
diff --git a/debian/patches/35-libvdeplug-soname.patch b/debian/patches/35-libvdeplug-soname.patch
new file mode 100644
index 00000000..b79680ca
--- /dev/null
+++ b/debian/patches/35-libvdeplug-soname.patch
@@ -0,0 +1,24 @@
+Description: Revert http://www.virtualbox.org/changeset/36310
+ The libvdeplug.so symlink is only shipped in the -dev package.
+Author: Felix Geyer <fgeyer@debian.org>
+
+Index: virtualbox/include/VBox/VDEPlugSymDefs.h
+===================================================================
+--- virtualbox.orig/include/VBox/VDEPlugSymDefs.h
++++ virtualbox/include/VBox/VDEPlugSymDefs.h
+@@ -1,5 +1,5 @@
+ /** @file
+- * Symbols from libvdeplug.so to be loaded at runtime for DrvVDE.cpp
++ * Symbols from libvdeplug.so.2 to be loaded at runtime for DrvVDE.cpp
+ */
+
+ /*
+@@ -34,7 +34,7 @@
+ */
+
+ /** The file name of the DBus library */
+-#define VBOX_LIB_VDE_PLUG_NAME "libvdeplug.so"
++#define VBOX_LIB_VDE_PLUG_NAME "libvdeplug.so.2"
+ #define RT_RUNTIME_LOADER_LIB_NAME VBOX_LIB_VDE_PLUG_NAME
+
+ /** The name of the loader function */
diff --git a/debian/patches/36-fix-vnc-version-string.patch b/debian/patches/36-fix-vnc-version-string.patch
new file mode 100644
index 00000000..8e7f91c6
--- /dev/null
+++ b/debian/patches/36-fix-vnc-version-string.patch
@@ -0,0 +1,22 @@
+Description: fix version string for VNC plugin module.
+--- a/Config.kmk
++++ b/Config.kmk
+@@ -3850,6 +3850,7 @@ VBOX_EDIT_VERSION_AND_BUILD_CMD_FN = $(SED) \
+ -e 's+@VBOX_VERSION_MINOR@+$(VBOX_VERSION_MINOR)+g' \
+ -e 's+@VBOX_VERSION_BUILD@+$(VBOX_VERSION_BUILD)+g' \
+ -e 's+@VBOX_VERSION_STRING@+$(VBOX_VERSION_STRING)+g' \
++ -e 's+@VBOX_VERSION_STRING_RAW@+$(VBOX_VERSION_STRING_RAW)+g' \
+ -e 's+@VBOX_SVN_REV@+$(VBOX_SVN_REV)+g' \
+ -e 's+@VBOX_VENDOR@+$(VBOX_VENDOR)+g' \
+ -e 's+@VBOX_VENDOR_SHORT@+$(VBOX_VENDOR_SHORT)+g' \
+--- a/src/VBox/ExtPacks/VNC/ExtPack.xml
++++ b/src/VBox/ExtPacks/VNC/ExtPack.xml
+@@ -2,7 +2,7 @@
+ <VirtualBoxExtensionPack xmlns="http://www.virtualbox.org/VirtualBoxExtensionPack" version="1.0">
+ <Name>VNC</Name>
+ <Description>VNC plugin module</Description>
+- <Version revision="@VBOX_SVN_REV@">@VBOX_VERSION_STRING@</Version>
++ <Version revision="@VBOX_SVN_REV@">@VBOX_VERSION_STRING_RAW@</Version>
+ <MainModule>VBoxVNCMain</MainModule>
+ <VRDEModule>VBoxVNC</VRDEModule>
+ <ShowLicense/>
diff --git a/debian/patches/37-do-not-run-if-not-in-vm.patch b/debian/patches/37-do-not-run-if-not-in-vm.patch
new file mode 100644
index 00000000..9ae3fcd5
--- /dev/null
+++ b/debian/patches/37-do-not-run-if-not-in-vm.patch
@@ -0,0 +1,29 @@
+Description: Check if we are running in a virtual machine before wasting time
+running virtualbox guest things
+Author: Kevin Puetz (puetzk)
+
+Origin: https://bugs.launchpad.net/ubuntu/+source/virtualbox/+bug/1762491/comments/9
+Last-Update: 2018-07-19
+
+Index: virtualbox/src/VBox/Additions/x11/Installer/98vboxadd-xclient
+===================================================================
+--- virtualbox.orig/src/VBox/Additions/x11/Installer/98vboxadd-xclient
++++ virtualbox/src/VBox/Additions/x11/Installer/98vboxadd-xclient
+@@ -25,6 +25,17 @@
+ # SPDX-License-Identifier: GPL-3.0-only
+ #
+
++in_virtual_machine()
++{
++ if [ -z "$(lspci -d 80ee:cafe)" ]; then
++ echo "VirtualBox Additions disabled, not in a Virtual Machine" >&2
++ return 1
++ fi
++
++ return 0
++}
++in_virtual_machine || return
++
+ # Sanity check: if non-writeable PID-files are present in the user home
+ # directory VBoxClient will fail to start.
+ for i in $HOME/.vboxclient-*.pid; do
diff --git a/debian/patches/python3.11.patch b/debian/patches/python3.11.patch
new file mode 100644
index 00000000..d8e6d6e5
--- /dev/null
+++ b/debian/patches/python3.11.patch
@@ -0,0 +1,13 @@
+diff --git a/configure b/configure
+index 0872ec4c7..037680e08 100755
+--- a/configure
++++ b/configure
+@@ -2127,7 +2127,7 @@ extern "C" int main(void)
+ }
+ EOF
+ found=
+- SUPPYTHONLIBS="python2.7 python2.6 python3.1 python3.2 python3.3 python3.4 python3.4m python3.5 python3.5m python3.6 python3.6m python3.7 python3.7m python3.8 python3.8m python3.9 python3.9m python3.10 python3.10m"
++ SUPPYTHONLIBS="python2.7 python2.6 python3.1 python3.2 python3.3 python3.4 python3.4m python3.5 python3.5m python3.6 python3.6m python3.7 python3.7m python3.8 python3.8m python3.9 python3.9m python3.10 python3.10m python3.11 python3.11m"
+ for p in $PYTHONDIR; do
+ for d in $SUPPYTHONLIBS; do
+ for b in lib/x86_64-linux-gnu lib/i386-linux-gnu lib64 lib/64 lib; do
diff --git a/debian/patches/series b/debian/patches/series
new file mode 100644
index 00000000..e87b7f57
--- /dev/null
+++ b/debian/patches/series
@@ -0,0 +1,17 @@
+01-build-arch.patch
+02-gsoap-build-fix.patch
+04-vboxdrv-references.patch
+06-xsession.patch
+07-vboxnetflt-reference.patch
+12-make-module.patch
+13-module-mismatch.patch
+16-no-update.patch
+23-remove-invalid-chars-check.patch
+27-hide-host-cache-warning.patch
+28-no-selinux-fedora.patch
+#29-fix-ftbfs-as-needed.patch
+32-disable-guest-version-check.patch
+35-libvdeplug-soname.patch
+36-fix-vnc-version-string.patch
+37-do-not-run-if-not-in-vm.patch
+python3.11.patch