[SCM] mixxx/master: Upstream patch to fix chromaprint 1.4 compat

sramacher at users.alioth.debian.org sramacher at users.alioth.debian.org
Wed Jan 11 19:58:40 UTC 2017


The following commit has been merged in the master branch:
commit ee6a5de887abe365c702061140bae5747a585cf4
Author: Sebastian Ramacher <sramacher at debian.org>
Date:   Wed Jan 11 20:56:28 2017 +0100

    Upstream patch to fix chromaprint 1.4 compat
    
    Closes: #851009

diff --git a/debian/patches/0008-chromaprint-1.4.patch b/debian/patches/0008-chromaprint-1.4.patch
new file mode 100644
index 0000000..35e63d2
--- /dev/null
+++ b/debian/patches/0008-chromaprint-1.4.patch
@@ -0,0 +1,44 @@
+Description: chromaprint 1.4 compatibility
+Origin: upstream,
+ https://github.com/mixxxdj/mixxx/commit/71f3e5d0adb5116a23f9163b045f3419b9056a08,
+ https://github.com/mixxxdj/mixxx/commit/830e864384ee1c96272997ee3f1dae4f71b28f3e,
+ https://github.com/mixxxdj/mixxx/commit/c5b4368fd228feee28af4fb32ab6fbfd3f29f212
+Last-Update: 2017-01-11
+
+--- mixxx-2.0.0~dfsg.orig/src/musicbrainz/chromaprinter.cpp
++++ mixxx-2.0.0~dfsg/src/musicbrainz/chromaprinter.cpp
+@@ -5,6 +5,19 @@
+ #include "musicbrainz/chromaprinter.h"
+ #include "soundsourceproxy.h"
+ 
++namespace
++{
++    // Type declarations of *fprint and *encoded pointers need to account for Chromaprint API version
++    // (void* -> uint32_t*) and (void* -> char*) changed in versions v1.4.0 or later -- alyptik 12/2016
++    #if (CHROMAPRINT_VERSION_MINOR > 3) || (CHROMAPRINT_VERSION_MAJOR > 1)
++        typedef uint32_t* uint32_p;
++        typedef char* char_p;
++    #else
++        typedef void* uint32_p;
++        typedef void* char_p;
++    #endif
++}
++
+ ChromaPrinter::ChromaPrinter(QObject* parent)
+              : QObject(parent) {
+ }
+@@ -57,12 +70,12 @@ QString ChromaPrinter::calcFingerPrint(c
+     }
+     chromaprint_finish(ctx);
+ 
+-    void* fprint = NULL;
++    uint32_p fprint = NULL;
+     int size = 0;
+     int ret = chromaprint_get_raw_fingerprint(ctx, &fprint, &size);
+     QByteArray fingerprint;
+     if (ret == 1) {
+-        void* encoded = NULL;
++        char_p encoded = NULL;
+         int encoded_size = 0;
+         chromaprint_encode_fingerprint(fprint, size,
+                                        CHROMAPRINT_ALGORITHM_DEFAULT,
diff --git a/debian/patches/series b/debian/patches/series
index bef0e81..50dd5fb 100644
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -5,3 +5,4 @@
 0005-hidapi.patch
 0006-opengles.patch
 0007-fix_gcc6_issue.patch
+0008-chromaprint-1.4.patch
diff --git a/debian/patches/ubuntu.series b/debian/patches/ubuntu.series
index a78635a..2b024e5 100644
--- a/debian/patches/ubuntu.series
+++ b/debian/patches/ubuntu.series
@@ -4,3 +4,4 @@
 0005-hidapi.patch
 0006-opengles.patch
 0007-fix_gcc6_issue.patch
+0008-chromaprint-1.4.patch

-- 
mixxx packaging



More information about the pkg-multimedia-commits mailing list