vp-build/srcpkgs/mixxx/patches/0008-chromaprint-1.4.patch

30 lines
1.0 KiB
Diff

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
--- src/musicbrainz/chromaprinter.cpp
+++ 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) {
}