commit e83731c138e911a104e6f682917e9c3da8fd7496
Author: Sérgio M. Basto <sergio(a)serjux.com>
Date: Thu Mar 19 17:35:50 2020 +0000
Add Clipboard.patch for guest in epel7
Clipboard.patch | 52 ++++++++++++++++++++++++++++++++++++++++++++++++++++
VirtualBox.spec | 2 ++
2 files changed, 54 insertions(+)
---
diff --git a/Clipboard.patch b/Clipboard.patch
new file mode 100644
index 0000000..6df543f
--- /dev/null
+++ b/Clipboard.patch
@@ -0,0 +1,52 @@
+Shared Clipboard: ticketref:19336 Linux guest: shared clipboard doesn't work (on
fresh VirtualBox-6.1.4-136177)
+
+git-svn-id:
http://www.virtualbox.org/svn/vbox@83184
cfe28804-0f27-0410-a406-dd0f0b0b656f
+diff --git trunk/src/VBox/Additions/x11/VBoxClient/clipboard.cpp
b/trunk/src/VBox/Additions/x11/VBoxClient/clipboard.cpp
+index ad9e3bf69c..9063b212cd 100644
+--- trunk/src/VBox/Additions/x11/VBoxClient/clipboard.cpp
++++ trunk/src/VBox/Additions/x11/VBoxClient/clipboard.cpp
+@@ -107,7 +107,7 @@ DECLCALLBACK(int) ShClX11RequestDataForX11Callback(PSHCLCONTEXT pCtx,
SHCLFORMAT
+ else
+ #endif
+ {
+- uint32_t cbData = _4K; /** @ŧodo Make this dynamic. */
++ uint32_t cbData = _4K; /** @todo Make this dynamic. */
+ void *pvData = RTMemAlloc(cbData);
+ if (pvData)
+ {
+@@ -215,7 +215,6 @@ DECLCALLBACK(void) ShClX11RequestFromX11CompleteCallback(PSHCLCONTEXT
pCtx, int
+ *
+ * @returns VBox status code.
+ */
+-#if 0
+ static int vboxClipboardConnect(void)
+ {
+ LogFlowFuncEnter();
+@@ -245,7 +244,6 @@ static int vboxClipboardConnect(void)
+ LogFlowFuncLeaveRC(rc);
+ return rc;
+ }
+-#endif
+
+ /**
+ * The main loop of our clipboard reader.
+@@ -469,7 +467,7 @@ static int run(struct VBCLSERVICE **ppInterface, bool fDaemonised)
+ RT_NOREF(ppInterface, fDaemonised);
+
+ /* Initialise the guest library. */
+- int rc = 0; //vboxClipboardConnect();
++ int rc = vboxClipboardConnect();
+ if (RT_SUCCESS(rc))
+ {
+ #ifdef VBOX_WITH_SHARED_CLIPBOARD_FUSE
+@@ -477,9 +475,7 @@ static int run(struct VBCLSERVICE **ppInterface, bool fDaemonised)
+ if (RT_SUCCESS(rc))
+ {
+ #endif
+- RTThreadSleep(60 * 1000);
+-
+- //rc = vboxClipboardMain();
++ rc = vboxClipboardMain();
+
+ #ifdef VBOX_WITH_SHARED_CLIPBOARD_FUSE
+ int rc2 = vboxClipboardFUSEStop();
diff --git a/VirtualBox.spec b/VirtualBox.spec
index 4ee4c2f..0eb03c7 100644
--- a/VirtualBox.spec
+++ b/VirtualBox.spec
@@ -92,6 +92,7 @@ Patch70: vbox-python-detection.diff
Patch80: VirtualBox-6.1.4-hacks.patch
Patch81: fixes_for_5.6.patch
+Patch82: Clipboard.patch
BuildRequires: kBuild >= 0.1.9998.r3093
BuildRequires: SDL-devel
@@ -341,6 +342,7 @@ rm -r src/libs/zlib-1.2.*/
%patch70 -p1 -b .python-detection
%patch80 -p1 -b .hack
%patch81 -p1 -b .kernel5.6
+%patch82 -p1 -b .clipboard
%build
./configure --disable-kmods \