diff options
author | adam <adam@pkgsrc.org> | 2019-09-19 16:50:57 +0000 |
---|---|---|
committer | adam <adam@pkgsrc.org> | 2019-09-19 16:50:57 +0000 |
commit | 7ab0f7ed3763ffd9a43d0a4bf7a40c4e910ae448 (patch) | |
tree | c1ab49c11a046f40afb112a1adfbb74ee2ac5fa4 | |
parent | 14e2c425788954a24f7011a8d5be9e15c4cdb530 (diff) | |
download | pkgsrc-7ab0f7ed3763ffd9a43d0a4bf7a40c4e910ae448.tar.gz |
py-zstandard: updated to 0.12.0
0.12.0:
Backwards Compatibility Notes
* Support for Python 3.4 has been dropped since Python 3.4 is no longer
a supported Python version upstream. (But it will likely continue to
work until Python 2.7 support is dropped and we port to Python 3.5+
APIs.)
Bug Fixes
* Fix ``ZstdDecompressor.__init__`` on 64-bit big-endian systems.
* Fix memory leak in ``ZstdDecompressionReader.seek()``.
Changes
* CI transitioned to Azure Pipelines (from AppVeyor and Travis CI).
* Switched to ``pytest`` for running tests (from ``nose``).
* Bundled zstandard library upgraded from 1.3.8 to 1.4.3.
-rw-r--r-- | archivers/py-zstandard/Makefile | 4 | ||||
-rw-r--r-- | archivers/py-zstandard/distinfo | 15 | ||||
-rw-r--r-- | archivers/py-zstandard/patches/patch-c-ext_compressionparams.c | 48 | ||||
-rw-r--r-- | archivers/py-zstandard/patches/patch-zstandard_cffi.py | 25 | ||||
-rw-r--r-- | archivers/py-zstandard/patches/patch-zstd.c | 6 | ||||
-rw-r--r-- | archivers/py-zstandard/patches/patch-zstd_compress_zstd__compress.c | 92 |
6 files changed, 11 insertions, 179 deletions
diff --git a/archivers/py-zstandard/Makefile b/archivers/py-zstandard/Makefile index e0fe3748c84..07124183128 100644 --- a/archivers/py-zstandard/Makefile +++ b/archivers/py-zstandard/Makefile @@ -1,6 +1,6 @@ -# $NetBSD: Makefile,v 1.11 2019/05/15 09:09:49 adam Exp $ +# $NetBSD: Makefile,v 1.12 2019/09/19 16:50:57 adam Exp $ -DISTNAME= zstandard-0.11.1 +DISTNAME= zstandard-0.12.0 PKGNAME= ${PYPKGPREFIX}-${DISTNAME} CATEGORIES= archivers python MASTER_SITES= ${MASTER_SITE_PYPI:=z/zstandard/} diff --git a/archivers/py-zstandard/distinfo b/archivers/py-zstandard/distinfo index 1765dd82985..d1b97c7d2ed 100644 --- a/archivers/py-zstandard/distinfo +++ b/archivers/py-zstandard/distinfo @@ -1,10 +1,7 @@ -$NetBSD: distinfo,v 1.11 2019/05/15 09:09:49 adam Exp $ +$NetBSD: distinfo,v 1.12 2019/09/19 16:50:57 adam Exp $ -SHA1 (zstandard-0.11.1.tar.gz) = 8e292694c584566754370c04444f8636abe71406 -RMD160 (zstandard-0.11.1.tar.gz) = 52dda103a4e290f5719cab8e363876f446dd2b4a -SHA512 (zstandard-0.11.1.tar.gz) = 78cdc5e839ed97cdeb67a4790dddde0b45fe70cef85d96a48688a0daebbf15dfcd74891222a63b1ae6d011b5a74cb5024e877eb1a9c55818fff7122a7139051d -Size (zstandard-0.11.1.tar.gz) = 641453 bytes -SHA1 (patch-c-ext_compressionparams.c) = f9b2674e9e0816ef8ba23cf3cb77294a6b2008f7 -SHA1 (patch-zstandard_cffi.py) = f6d0f070160d9e977701d4d1fb26878d75e19898 -SHA1 (patch-zstd.c) = ee9e8d349759fcc0dd43bcd68fefdf3390feca6c -SHA1 (patch-zstd_compress_zstd__compress.c) = 94c28e6b9bd594693656eac9e7cbdacc04a24c70 +SHA1 (zstandard-0.12.0.tar.gz) = b6b81d4af12dd16f7d830de2b769c569f5a23a9a +RMD160 (zstandard-0.12.0.tar.gz) = c5ed78145c3057cc83893977f59eda68b4b63e29 +SHA512 (zstandard-0.12.0.tar.gz) = ebf896a77ce5cdc82a1edb658a0b96bcf99deee7aa031163879fc21fe3d03623061182fd2c11840a5a46a8ad0a08b98b802b4703b963d448a25c0b52685d3b64 +Size (zstandard-0.12.0.tar.gz) = 648827 bytes +SHA1 (patch-zstd.c) = 0d2a52f1adae7ed1768974533ae92440954cf03e diff --git a/archivers/py-zstandard/patches/patch-c-ext_compressionparams.c b/archivers/py-zstandard/patches/patch-c-ext_compressionparams.c deleted file mode 100644 index b6e953393e5..00000000000 --- a/archivers/py-zstandard/patches/patch-c-ext_compressionparams.c +++ /dev/null @@ -1,48 +0,0 @@ -$NetBSD: patch-c-ext_compressionparams.c,v 1.1 2019/05/02 10:10:56 wiz Exp $ - -Adapt for zstd-1.4.0 -https://github.com/indygreg/python-zstandard/commit/f00431bf3b8a16b6cc17fa7c7a442e80d558e5e8 - ---- c-ext/compressionparams.c.orig 2019-02-26 00:17:23.000000000 +0000 -+++ c-ext/compressionparams.c -@@ -11,7 +11,7 @@ - extern PyObject* ZstdError; - - int set_parameter(ZSTD_CCtx_params* params, ZSTD_cParameter param, int value) { -- size_t zresult = ZSTD_CCtxParam_setParameter(params, param, value); -+ size_t zresult = ZSTD_CCtxParams_setParameter(params, param, value); - if (ZSTD_isError(zresult)) { - PyErr_Format(ZstdError, "unable to set compression context parameter: %s", - ZSTD_getErrorName(zresult)); -@@ -25,11 +25,11 @@ int set_parameter(ZSTD_CCtx_params* para - - #define TRY_COPY_PARAMETER(source, dest, param) { \ - int result; \ -- size_t zresult = ZSTD_CCtxParam_getParameter(source, param, &result); \ -+ size_t zresult = ZSTD_CCtxParams_getParameter(source, param, &result); \ - if (ZSTD_isError(zresult)) { \ - return 1; \ - } \ -- zresult = ZSTD_CCtxParam_setParameter(dest, param, result); \ -+ zresult = ZSTD_CCtxParams_setParameter(dest, param, result); \ - if (ZSTD_isError(zresult)) { \ - return 1; \ - } \ -@@ -78,7 +78,7 @@ int reset_params(ZstdCompressionParamete - } - - #define TRY_GET_PARAMETER(params, param, value) { \ -- size_t zresult = ZSTD_CCtxParam_getParameter(params, param, value); \ -+ size_t zresult = ZSTD_CCtxParams_getParameter(params, param, value); \ - if (ZSTD_isError(zresult)) { \ - PyErr_Format(ZstdError, "unable to retrieve parameter: %s", ZSTD_getErrorName(zresult)); \ - return 1; \ -@@ -436,7 +436,7 @@ static void ZstdCompressionParameters_de - int result; \ - size_t zresult; \ - ZstdCompressionParametersObject* p = (ZstdCompressionParametersObject*)(self); \ -- zresult = ZSTD_CCtxParam_getParameter(p->params, param, &result); \ -+ zresult = ZSTD_CCtxParams_getParameter(p->params, param, &result); \ - if (ZSTD_isError(zresult)) { \ - PyErr_Format(ZstdError, "unable to get compression parameter: %s", \ - ZSTD_getErrorName(zresult)); \ diff --git a/archivers/py-zstandard/patches/patch-zstandard_cffi.py b/archivers/py-zstandard/patches/patch-zstandard_cffi.py deleted file mode 100644 index a47bb70cbdc..00000000000 --- a/archivers/py-zstandard/patches/patch-zstandard_cffi.py +++ /dev/null @@ -1,25 +0,0 @@ -$NetBSD: patch-zstandard_cffi.py,v 1.1 2019/05/02 10:10:56 wiz Exp $ - -Adapt for zstd-1.4.0 -https://github.com/indygreg/python-zstandard/commit/f00431bf3b8a16b6cc17fa7c7a442e80d558e5e8 - ---- zstandard/cffi.py.orig 2019-02-26 00:17:23.000000000 +0000 -+++ zstandard/cffi.py -@@ -416,7 +416,7 @@ def estimate_decompression_context_size( - - - def _set_compression_parameter(params, param, value): -- zresult = lib.ZSTD_CCtxParam_setParameter(params, param, value) -+ zresult = lib.ZSTD_CCtxParams_setParameter(params, param, value) - if lib.ZSTD_isError(zresult): - raise ZstdError('unable to set compression context parameter: %s' % - _zstd_error(zresult)) -@@ -425,7 +425,7 @@ def _set_compression_parameter(params, p - def _get_compression_parameter(params, param): - result = ffi.new('int *') - -- zresult = lib.ZSTD_CCtxParam_getParameter(params, param, result) -+ zresult = lib.ZSTD_CCtxParams_getParameter(params, param, result) - if lib.ZSTD_isError(zresult): - raise ZstdError('unable to get compression context parameter: %s' % - _zstd_error(zresult)) diff --git a/archivers/py-zstandard/patches/patch-zstd.c b/archivers/py-zstandard/patches/patch-zstd.c index e06573ea9d2..993832afa0a 100644 --- a/archivers/py-zstandard/patches/patch-zstd.c +++ b/archivers/py-zstandard/patches/patch-zstd.c @@ -1,14 +1,14 @@ -$NetBSD: patch-zstd.c,v 1.2 2019/02/26 06:42:27 adam Exp $ +$NetBSD: patch-zstd.c,v 1.3 2019/09/19 16:50:57 adam Exp $ Allow newer zstd. ---- zstd.c.orig 2019-02-26 00:17:23.000000000 +0000 +--- zstd.c.orig 2019-09-16 01:27:27.000000000 +0000 +++ zstd.c @@ -210,10 +210,6 @@ void zstd_module_init(PyObject* m) { We detect this mismatch here and refuse to load the module if this scenario is detected. */ -- if (ZSTD_VERSION_NUMBER != 10308 || ZSTD_versionNumber() != 10308) { +- if (ZSTD_VERSION_NUMBER != 10403 || ZSTD_versionNumber() != 10403) { - PyErr_SetString(PyExc_ImportError, "zstd C API mismatch; Python bindings not compiled against expected zstd version"); - return; - } diff --git a/archivers/py-zstandard/patches/patch-zstd_compress_zstd__compress.c b/archivers/py-zstandard/patches/patch-zstd_compress_zstd__compress.c deleted file mode 100644 index 2e976f82a80..00000000000 --- a/archivers/py-zstandard/patches/patch-zstd_compress_zstd__compress.c +++ /dev/null @@ -1,92 +0,0 @@ -$NetBSD: patch-zstd_compress_zstd__compress.c,v 1.1 2019/05/02 10:10:56 wiz Exp $ - -Adapt for zstd-1.4.0 -https://github.com/indygreg/python-zstandard/commit/f00431bf3b8a16b6cc17fa7c7a442e80d558e5e8 - ---- zstd/compress/zstd_compress.c.orig 2019-02-26 00:17:23.000000000 +0000 -+++ zstd/compress/zstd_compress.c -@@ -431,11 +431,11 @@ size_t ZSTD_CCtx_setParameter(ZSTD_CCtx* - switch(param) - { - case ZSTD_c_format : -- return ZSTD_CCtxParam_setParameter(&cctx->requestedParams, param, value); -+ return ZSTD_CCtxParams_setParameter(&cctx->requestedParams, param, value); - - case ZSTD_c_compressionLevel: - if (cctx->cdict) return ERROR(stage_wrong); -- return ZSTD_CCtxParam_setParameter(&cctx->requestedParams, param, value); -+ return ZSTD_CCtxParams_setParameter(&cctx->requestedParams, param, value); - - case ZSTD_c_windowLog: - case ZSTD_c_hashLog: -@@ -445,31 +445,31 @@ size_t ZSTD_CCtx_setParameter(ZSTD_CCtx* - case ZSTD_c_targetLength: - case ZSTD_c_strategy: - if (cctx->cdict) return ERROR(stage_wrong); -- return ZSTD_CCtxParam_setParameter(&cctx->requestedParams, param, value); -+ return ZSTD_CCtxParams_setParameter(&cctx->requestedParams, param, value); - - case ZSTD_c_contentSizeFlag: - case ZSTD_c_checksumFlag: - case ZSTD_c_dictIDFlag: -- return ZSTD_CCtxParam_setParameter(&cctx->requestedParams, param, value); -+ return ZSTD_CCtxParams_setParameter(&cctx->requestedParams, param, value); - - case ZSTD_c_forceMaxWindow : /* Force back-references to remain < windowSize, - * even when referencing into Dictionary content. - * default : 0 when using a CDict, 1 when using a Prefix */ -- return ZSTD_CCtxParam_setParameter(&cctx->requestedParams, param, value); -+ return ZSTD_CCtxParams_setParameter(&cctx->requestedParams, param, value); - - case ZSTD_c_forceAttachDict: -- return ZSTD_CCtxParam_setParameter(&cctx->requestedParams, param, value); -+ return ZSTD_CCtxParams_setParameter(&cctx->requestedParams, param, value); - - case ZSTD_c_nbWorkers: - if ((value!=0) && cctx->staticSize) { - return ERROR(parameter_unsupported); /* MT not compatible with static alloc */ - } -- return ZSTD_CCtxParam_setParameter(&cctx->requestedParams, param, value); -+ return ZSTD_CCtxParams_setParameter(&cctx->requestedParams, param, value); - - case ZSTD_c_jobSize: - case ZSTD_c_overlapLog: - case ZSTD_c_rsyncable: -- return ZSTD_CCtxParam_setParameter(&cctx->requestedParams, param, value); -+ return ZSTD_CCtxParams_setParameter(&cctx->requestedParams, param, value); - - case ZSTD_c_enableLongDistanceMatching: - case ZSTD_c_ldmHashLog: -@@ -477,16 +477,16 @@ size_t ZSTD_CCtx_setParameter(ZSTD_CCtx* - case ZSTD_c_ldmBucketSizeLog: - case ZSTD_c_ldmHashRateLog: - if (cctx->cdict) return ERROR(stage_wrong); -- return ZSTD_CCtxParam_setParameter(&cctx->requestedParams, param, value); -+ return ZSTD_CCtxParams_setParameter(&cctx->requestedParams, param, value); - - default: return ERROR(parameter_unsupported); - } - } - --size_t ZSTD_CCtxParam_setParameter(ZSTD_CCtx_params* CCtxParams, -+size_t ZSTD_CCtxParams_setParameter(ZSTD_CCtx_params* CCtxParams, - ZSTD_cParameter param, int value) - { -- DEBUGLOG(4, "ZSTD_CCtxParam_setParameter (%i, %i)", (int)param, value); -+ DEBUGLOG(4, "ZSTD_CCtxParams_setParameter (%i, %i)", (int)param, value); - switch(param) - { - case ZSTD_c_format : -@@ -636,10 +636,10 @@ size_t ZSTD_CCtxParam_setParameter(ZSTD_ - - size_t ZSTD_CCtx_getParameter(ZSTD_CCtx* cctx, ZSTD_cParameter param, int* value) - { -- return ZSTD_CCtxParam_getParameter(&cctx->requestedParams, param, value); -+ return ZSTD_CCtxParams_getParameter(&cctx->requestedParams, param, value); - } - --size_t ZSTD_CCtxParam_getParameter( -+size_t ZSTD_CCtxParams_getParameter( - ZSTD_CCtx_params* CCtxParams, ZSTD_cParameter param, int* value) - { - switch(param) |