[Pkg-virtualbox-commits] [virtualbox] 01/01: Fix build with the correct patch

Gianfranco Costamagna locutusofborg at moszumanska.debian.org
Wed Oct 19 17:39:23 UTC 2016


This is an automated email from the git hooks/post-receive script.

locutusofborg pushed a commit to branch master
in repository virtualbox.

commit fccc466bb158c7b12be9e967f4c816b0875f6381
Author: Gianfranco Costamagna <costamagnagianfranco at yahoo.it>
Date:   Wed Oct 19 19:38:33 2016 +0200

    Fix build with the correct patch
---
 debian/changelog               |  7 +++++
 debian/patches/fix-build.patch | 63 ++++++++++++++++++++++++++++++++++--------
 2 files changed, 59 insertions(+), 11 deletions(-)

diff --git a/debian/changelog b/debian/changelog
index 1172db0..68a7767 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,3 +1,10 @@
+virtualbox (5.1.8-dfsg-3) unstable; urgency=medium
+
+  * Fix build with the correct upstream patch.
+    (Closes: #841340)
+
+ -- Gianfranco Costamagna <locutusofborg at debian.org>  Wed, 19 Oct 2016 19:33:05 +0200
+
 virtualbox (5.1.8-dfsg-2) unstable; urgency=medium
 
   * Fix a build failure with newer gcc.
diff --git a/debian/patches/fix-build.patch b/debian/patches/fix-build.patch
index ba9b8e5..54ce32f 100644
--- a/debian/patches/fix-build.patch
+++ b/debian/patches/fix-build.patch
@@ -1,14 +1,55 @@
-Description: Upstream patch to workaround gcc-6 6.2.0-7 build failure
+Description: Upstream changeset 64324 and 64325 to fix build failure with gcc-7 (and 6.2.0-7 backported patch)
 
---- virtualbox-5.1.8-dfsg.orig/src/VBox/Main/src-server/linux/HostDnsServiceLinux.cpp
-+++ virtualbox-5.1.8-dfsg/src/VBox/Main/src-server/linux/HostDnsServiceLinux.cpp
-@@ -78,8 +78,8 @@ class AutoNotify:public FileDescriptor
- 
- struct InotifyEventWithName
+Index: virtualbox/src/VBox/Devices/USB/linux/USBProxyDevice-linux.cpp
+===================================================================
+--- virtualbox.orig/src/VBox/Devices/USB/linux/USBProxyDevice-linux.cpp
++++ virtualbox/src/VBox/Devices/USB/linux/USBProxyDevice-linux.cpp
+@@ -110,8 +110,16 @@
+  */
+ typedef struct USBPROXYURBLNX
  {
--    struct inotify_event e;
-     char name[NAME_MAX];
-+    struct inotify_event e;
- };
+-    /** The kernel URB data */
++    /** The kernel URB data. */
++#if RT_GNUC_PREREQ(6, 0)
++    /* gcc 6.2 complains about the [] member of KUrb */
++# pragma GCC diagnostic push
++# pragma GCC diagnostic ignored "-Wpedantic"
++#endif
+     struct usbdevfs_urb             KUrb;
++#if RT_GNUC_PREREQ(6, 0)
++# pragma GCC diagnostic pop
++#endif
+     /** Space filler for the isochronous packets. */
+     struct usbdevfs_iso_packet_desc aIsocPktsDonUseTheseUseTheOnesInKUrb[8];
+     /** Node to link the URB in of the existing lists. */
+@@ -121,11 +129,11 @@
+     /** The next linux URB if split up. */
+     struct USBPROXYURBLNX           *pSplitNext;
+     /** Don't report these back. */
+-    bool                             fCanceledBySubmit;
++    bool                            fCanceledBySubmit;
+     /** This split element is reaped. */
+-    bool                             fSplitElementReaped;
++    bool                            fSplitElementReaped;
+     /** Size to transfer in remaining fragments of a split URB */
+-    uint32_t                         cbSplitRemaining;
++    uint32_t                        cbSplitRemaining;
+ } USBPROXYURBLNX, *PUSBPROXYURBLNX;
+ 
+ /**
+Index: virtualbox/src/VBox/Main/src-server/linux/HostDnsServiceLinux.cpp
+===================================================================
+--- virtualbox.orig/src/VBox/Main/src-server/linux/HostDnsServiceLinux.cpp
++++ virtualbox/src/VBox/Main/src-server/linux/HostDnsServiceLinux.cpp
+@@ -34,6 +34,11 @@
+ 
+ #include <linux/limits.h>
  
- HostDnsServiceLinux::~HostDnsServiceLinux()
++/* Workaround for <sys/cdef.h> defining __flexarr to [] which beats us in
++ * struct inotify_event (char name __flexarr). */
++#include <sys/cdefs.h>
++#undef __flexarr
++#define __flexarr [0]
+ #include <sys/inotify.h>
+ #include <sys/types.h>
+ #include <sys/socket.h>

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-virtualbox/virtualbox.git



More information about the Pkg-virtualbox-commits mailing list