diff options
author | Matteo Bernardini <ponce@slackbuilds.org> | 2017-01-12 18:42:35 +0100 |
---|---|---|
committer | Willy Sudiarto Raharjo <willysr@slackbuilds.org> | 2017-01-15 06:35:25 +0700 |
commit | 575b7a112011fbe46cfa3a1777be34ccc767d2b0 (patch) | |
tree | d7557cf5e421fcb4f3b748ebe3d875532bc04306 /audio/mixxx | |
parent | 4c2d77731195538e870950223b474a4cebd34b3c (diff) |
audio/mixxx: Add upstream patch for the newer chromaprint.
Signed-off-by: Matteo Bernardini <ponce@slackbuilds.org>
Diffstat (limited to 'audio/mixxx')
-rw-r--r-- | audio/mixxx/chromaprint-1.4.patch | 44 | ||||
-rw-r--r-- | audio/mixxx/mixxx.SlackBuild | 5 |
2 files changed, 48 insertions, 1 deletions
diff --git a/audio/mixxx/chromaprint-1.4.patch b/audio/mixxx/chromaprint-1.4.patch new file mode 100644 index 0000000000000..35e63d2c5fe71 --- /dev/null +++ b/audio/mixxx/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/audio/mixxx/mixxx.SlackBuild b/audio/mixxx/mixxx.SlackBuild index 6583332a8ebb4..4ee8066b9c796 100644 --- a/audio/mixxx/mixxx.SlackBuild +++ b/audio/mixxx/mixxx.SlackBuild @@ -24,7 +24,7 @@ PRGNAM=mixxx VERSION=${VERSION:-2.0.0} -BUILD=${BUILD:-1} +BUILD=${BUILD:-2} TAG=${TAG:-_SBo} if [ -z "$ARCH" ]; then @@ -71,6 +71,9 @@ find -L . \ \( -perm 666 -o -perm 664 -o -perm 600 -o -perm 444 -o -perm 440 -o -perm 400 \) \ -exec chmod 644 {} \; +# Upstream patch for the newer chromaprint +patch -p1 < $CWD/chromaprint-1.4.patch + # Fix library installation path sed -i "s|'lib'|'lib$LIBDIRSUFFIX'|" build/depends.py src/SConscript || exit 1 sed -i "s|usr/lib|usr/lib$LIBDIRSUFFIX|" src/SConscript || exit 1 |