Update to 1.0.1 and fix python-3.x compatibility problem. Changes: 1.0.1 When GStreamer fails to report a duration, raise an exception instead of silently setting the duration field to None.diff -r1.1 -r1.2 pkgsrc/audio/py-audioread/Makefile
(wiz)
@@ -1,20 +1,20 @@ | @@ -1,20 +1,20 @@ | |||
1 | # $NetBSD: Makefile,v 1.1 2013/04/02 10:44:41 drochner Exp $ | 1 | # $NetBSD: Makefile,v 1.2 2014/01/17 14:35:06 wiz Exp $ | |
2 | # | |||
3 | 2 | |||
4 | DISTNAME= v1.0.0 | 3 | VERSION= 1.0.1 | |
5 | PKGNAME= ${PYPKGPREFIX}-audioread-1.0.0 | 4 | DISTNAME= v${VERSION} | |
5 | PKGNAME= ${PYPKGPREFIX}-audioread-${VERSION} | |||
6 | CATEGORIES= audio | 6 | CATEGORIES= audio | |
7 | MASTER_SITES= https://github.com/sampsyo/audioread/archive/ | 7 | MASTER_SITES= https://github.com/sampsyo/audioread/archive/ | |
8 | DIST_SUBDIR= audioread | 8 | DIST_SUBDIR= audioread | |
9 | 9 | |||
10 | MAINTAINER= pkgsrc-users@NetBSD.org | 10 | MAINTAINER= pkgsrc-users@NetBSD.org | |
11 | HOMEPAGE= https://github.com/sampsyo/audioread | 11 | HOMEPAGE= https://github.com/sampsyo/audioread | |
12 | COMMENT= Audio file decoder | 12 | COMMENT= Audio file decoder | |
13 | LICENSE= mit | 13 | LICENSE= mit | |
14 | 14 | |||
15 | WRKSRC= ${WRKDIR}/audioread-1.0.0 | 15 | WRKSRC= ${WRKDIR}/audioread-${VERSION} | |
16 | USE_LANGUAGES= # none | 16 | USE_LANGUAGES= # none | |
17 | EGG_NAME= audioread-1.0.0 | 17 | EGG_NAME= audioread-${VERSION} | |
18 | 18 | |||
19 | .include "../../lang/python/distutils.mk" | 19 | .include "../../lang/python/distutils.mk" | |
20 | .include "../../mk/bsd.pkg.mk" | 20 | .include "../../mk/bsd.pkg.mk" |
@@ -1,5 +1,6 @@ | @@ -1,5 +1,6 @@ | |||
1 | $NetBSD: distinfo,v 1.1 2013/04/02 10:44:41 drochner Exp $ | 1 | $NetBSD: distinfo,v 1.2 2014/01/17 14:35:06 wiz Exp $ | |
2 | 2 | |||
3 | SHA1 (audioread/v1.0.0.tar.gz) = f67aa7e11a86869dacc8189769c14d3c88e7a494 | 3 | SHA1 (audioread/v1.0.1.tar.gz) = 40a738de9a405439dff1d6b83257fb87e966662f | |
4 | RMD160 (audioread/v1.0.0.tar.gz) = 748d38461b63ac45053e5f4019fcf0b795e25649 | 4 | RMD160 (audioread/v1.0.1.tar.gz) = a6fd5c4c2e5715183a2ce8a3e7af680fe6491585 | |
5 | Size (audioread/v1.0.0.tar.gz) = 12934 bytes | 5 | Size (audioread/v1.0.1.tar.gz) = 13055 bytes | |
6 | SHA1 (patch-audioread_gstdec.py) = ca80c0f0c265d44e038c8321e7824325f4e920f7 |
$NetBSD: patch-audioread_gstdec.py,v 1.1 2014/01/17 14:35:06 wiz Exp $
Use print() function for python-3.x compatibility.
--- audioread/gstdec.py.orig 2013-04-24 17:08:52.000000000 +0000
+++ audioread/gstdec.py
@@ -366,8 +366,8 @@ if __name__ == '__main__':
for path in sys.argv[1:]:
path = os.path.abspath(os.path.expanduser(path))
with GstAudioFile(path) as f:
- print f.channels
- print f.samplerate
- print f.duration
+ print(f.channels)
+ print(f.samplerate)
+ print(f.duration)
for s in f:
- print len(s), ord(s[0])
+ print(len(s), ord(s[0]))