[SCM] ffado/master: Add patches to fix the build with GCC 7

mattia at users.alioth.debian.org mattia at users.alioth.debian.org
Fri Nov 10 23:40:39 UTC 2017


The following commit has been merged in the master branch:
commit e4ec83b535c11458d54f53acf75efdc76641c8ef
Author: Mattia Rizzolo <mattia at debian.org>
Date:   Fri Nov 10 21:55:54 2017 +0100

    Add patches to fix the build with GCC 7
    
    Closes: #853491
    Signed-off-by: Mattia Rizzolo <mattia at debian.org>

diff --git a/debian/patches/dbus_with_gcc7.patch b/debian/patches/dbus_with_gcc7.patch
new file mode 100644
index 0000000..3ef0b4f
--- /dev/null
+++ b/debian/patches/dbus_with_gcc7.patch
@@ -0,0 +1,61 @@
+Description: Fix build with dbusc++ 0.9 and GCC 7
+Origin: upstream, http://subversion.ffado.org/changeset/2674
+Last-Update: 2017-11-10
+
+--- a/support/dbus/controlclient.h
++++ b/support/dbus/controlclient.h
+@@ -26,6 +26,11 @@
+ 
+ #include "debugmodule/debugmodule.h"
+ 
++/* Work around a bug in dbus-c++ 0.9.0 which prevents compilation under gcc7 */
++#ifndef DBUS_HAS_RECURSIVE_MUTEX
++#define DBUS_HAS_RECURSIVE_MUTEX
++#endif
++
+ #include <dbus-c++/dbus.h>
+ 
+ #include "controlclient-glue.h"
+--- a/support/dbus/controlserver.h
++++ b/support/dbus/controlserver.h
+@@ -26,6 +26,11 @@
+ 
+ #include "debugmodule/debugmodule.h"
+ 
++/* Work around a bug in dbus-c++ 0.9.0 which prevents compilation under gcc7 */
++#ifndef DBUS_HAS_RECURSIVE_MUTEX
++#define DBUS_HAS_RECURSIVE_MUTEX
++#endif
++
+ #include <dbus-c++/dbus.h>
+ 
+ #include "controlserver-glue.h"
+--- a/support/dbus/ffado-dbus-server.cpp
++++ b/support/dbus/ffado-dbus-server.cpp
+@@ -37,6 +37,11 @@
+ #include "devicemanager.h"
+ #include "ffadodevice.h"
+ 
++/* Work around a bug in dbus-c++ 0.9.0 which prevents compilation under gcc7 */
++#ifndef DBUS_HAS_RECURSIVE_MUTEX
++#define DBUS_HAS_RECURSIVE_MUTEX
++#endif
++
+ #include <dbus-c++/dbus.h>
+ #include "controlserver.h"
+ #include "libcontrol/BasicElements.h"
+--- a/support/dbus/test-dbus.cpp
++++ b/support/dbus/test-dbus.cpp
+@@ -28,6 +28,12 @@
+ #include <signal.h>
+ 
+ #include "controlclient.h"
++
++/* Work around a bug in dbus-c++ 0.9.0 which prevents compilation under gcc7 */
++#ifndef DBUS_HAS_RECURSIVE_MUTEX
++#define DBUS_HAS_RECURSIVE_MUTEX
++#endif
++
+ #include <dbus-c++/dbus.h>
+ 
+ static const char* SERVER_NAME = "org.ffado.Control";
diff --git a/debian/patches/gcc7.patch b/debian/patches/gcc7.patch
new file mode 100644
index 0000000..5f8813a
--- /dev/null
+++ b/debian/patches/gcc7.patch
@@ -0,0 +1,26 @@
+Description: Fix pointer comparisons with null terminators
+Author: Philip Chung <philipchung1995 at yahoo.com>
+Acked-By: Mattia Rizzolo <mattia at debian.org
+Bug-Debian: https://bugs.debian.org/853491
+Last-Update: 2017-11-10
+
+--- a/src/libieee1394/configrom.cpp
++++ b/src/libieee1394/configrom.cpp
+@@ -176,7 +176,7 @@
+                 ( void* )CSR1212_TEXTUAL_DESCRIPTOR_LEAF_DATA( m_vendorNameKv ),
+                 len );
+ 
+-    while ((buf + len - 1) == '\0') {
++    while (buf[len - 1] == '\0') {
+             len--;
+         }
+         // \todo XXX seems a bit strage to do this but the nodemgr.c code does
+@@ -195,7 +195,7 @@
+         memcpy( buf,
+                 ( void* )CSR1212_TEXTUAL_DESCRIPTOR_LEAF_DATA( m_modelNameKv ),
+                 len );
+-    while ((buf + len - 1) == '\0') {
++    while (buf[len - 1] == '\0') {
+             len--;
+         }
+         // \todo XXX for edirol fa-66 it seems somehow broken. see above
diff --git a/debian/patches/series b/debian/patches/series
index 675e3ce..eb8b09f 100644
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -2,3 +2,5 @@ gcc6.patch
 cpuinfo-parsing.patch
 x32.patch
 powerpcspe.patch
+gcc7.patch
+dbus_with_gcc7.patch

-- 
Free Firewire Audio Drivers (ffado.org) packaging



More information about the pkg-multimedia-commits mailing list