diff options
author | V3n3RiX <venerix@redcorelinux.org> | 2021-03-27 06:06:27 +0000 |
---|---|---|
committer | V3n3RiX <venerix@redcorelinux.org> | 2021-03-27 06:06:27 +0000 |
commit | 8d5dbd847cbc704a6a06405856e94b461011afe3 (patch) | |
tree | 4d26462d027b14926335894749d2e01d982234d0 /dev-python/brotlicffi | |
parent | 5bb9ff1ee56d2b5e75e01a7f066d8b0cec84ec02 (diff) |
gentoo resync : 27.03.2021
Diffstat (limited to 'dev-python/brotlicffi')
-rw-r--r-- | dev-python/brotlicffi/Manifest | 5 | ||||
-rw-r--r-- | dev-python/brotlicffi/brotlicffi-0.8.0.ebuild | 54 | ||||
-rw-r--r-- | dev-python/brotlicffi/brotlicffi-1.0.9.1.ebuild | 2 | ||||
-rw-r--r-- | dev-python/brotlicffi/files/brotlicffi-0.8.0-remove-dict.patch | 132 |
4 files changed, 2 insertions, 191 deletions
diff --git a/dev-python/brotlicffi/Manifest b/dev-python/brotlicffi/Manifest index 7266e1083286..dd66acf6af60 100644 --- a/dev-python/brotlicffi/Manifest +++ b/dev-python/brotlicffi/Manifest @@ -1,7 +1,4 @@ -AUX brotlicffi-0.8.0-remove-dict.patch 5333 BLAKE2B e68065d06c072f61b0115925706e1476ef58d4217635c2d29e32a503cc0a98a2b55a9155f8bc189659b986a8bc7ca213b4b1f1405b0379e3f2813db50b5b949b SHA512 8e1acde07e98c609e295d0c2408823de026ffdfa88b3a45880ab5321b5293ce19791000bc5fd0d37ba96ccecb243151ac52ac2beaa2447ca912ae21d5a4a711c DIST brotli-46c1a881b41bb638c76247558aa04b1591af3aa7.tar.gz 19840371 BLAKE2B b9a1c3c2e5b62bd63b392debe54bd1732ac1cb31f88500f0142108b453649d96901d9a03b6db98642cb9abaf9188c06d440f2b8bd3cf57fbbb52196a931f5079 SHA512 dc573c90491032a205f32f0ce9c93e95b06c70a3107caa9501e038a212226c37117d63709a29843367344bf7d18cf32d0c0578b11166387198e12b38b1522406 -DIST brotlicffi-0.8.0.gh.tar.gz 21997 BLAKE2B 5e817e228ce01cd7a831c59cca5bab3e851d676f1daa5efab8f61a203c0854bcc92605c88896dff5f4ce27fc880718da5ddfcf02a3bddbbd7b2e18c33f1e77a4 SHA512 fd0c64b400d3b48e0e2d113b4d75e32a2b33fd99505c7661d6d51ba9aedf5cc1f58be09bc90a5f1f7e3424addef2b54cc085a41e6291c87d53dd7d4e8fc7eb4e DIST brotlicffi-1.0.9.1.gh.tar.gz 22589 BLAKE2B 14ebb3f6168d334abe3ba72bd88697ee98aba87ace6aaf634395ef50ecd9325723f0da0a9ce56a5e4dcfebfe3183a190e2ec183eff95492b25e3542161b32322 SHA512 669c73ed6dd18be6b916bb8cfb240657dcc10d67df5a32b3359f05cadf75aa654c27b53e8b964251f6d6cd74870e159efddf87ef0cfb59b7777eacd3cda66852 -EBUILD brotlicffi-0.8.0.ebuild 1340 BLAKE2B 48039a8d87f6a9108fd9bf0556a596ef9e69ffd5e30034b960023696638de4cb1f7d87e3c24d936c57f642926cc049714cd4f013f8ef81dc739528357f57b0b8 SHA512 b31f7b9941c0bcbce2ab56fe2158ae861f5cfe87edd0981e361a8a15000a885a886f0967d16a93a25547c9a83efd8c933553ce2f0774c11f098cfed04583468c -EBUILD brotlicffi-1.0.9.1.ebuild 1424 BLAKE2B dd67807ef9042427f1d3f2db9919f0938ac9fa036797dc98b7b0a2eca110f79292fab27c8f314aa64bae3dba50c4359ec896f10799ca36fba6c2b490fc4e6358 SHA512 da9c110153113322183c6a0a3e2fa80d7e047c0f9a1834aa114b4c6e4839f109c138f3577a7a16451583c2a7d33966ee32977441d527ef9a80f7f8c59a7963d2 +EBUILD brotlicffi-1.0.9.1.ebuild 1423 BLAKE2B b9ae8a682323abd0a1fbd306554f7bc0c81cad737ed613154678690b91c5294d59fe824bb4e922e7cdf22a4113b63bb6e49663edcabbab8be88fffc683ac12e7 SHA512 0f39e19b66b0675c0ffd2ce374ce609bfad05f0369cc8656cea8edad6716d2c0b959b8b74f3ecbf888311b357ce735fda91b6a31bd44f15d47f1c3ce79bbafd0 MISC metadata.xml 376 BLAKE2B 7044a00a2d66d5f983cc9485bc9a3124d24162cb72fb65c716653f1b4bddf7c6a1d3e7a407726098650167f74d5c10bab2582cabbb533cbf966ac0b8292cbe70 SHA512 51fee847f41d497493f69a12962df09d1229357502538b00c1941025230745bda4595619dca1277e6c01840c788e677ec0d1033d897350373e84ca6e9222ddd4 diff --git a/dev-python/brotlicffi/brotlicffi-0.8.0.ebuild b/dev-python/brotlicffi/brotlicffi-0.8.0.ebuild deleted file mode 100644 index 2afad43d1940..000000000000 --- a/dev-python/brotlicffi/brotlicffi-0.8.0.ebuild +++ /dev/null @@ -1,54 +0,0 @@ -# Copyright 1999-2021 Gentoo Authors -# Distributed under the terms of the GNU General Public License v2 - -EAPI=7 - -PYTHON_COMPAT=( python3_{7..9} pypy3 ) - -inherit distutils-r1 - -# Commit of the Brotli library bundled within brotlipy. -BROTLI_BUNDLED_COMMIT="46c1a881b41bb638c76247558aa04b1591af3aa7" - -DESCRIPTION="Python binding to the Brotli library" -HOMEPAGE=" - https://github.com/python-hyper/brotlicffi/ - https://pypi.org/project/brotlicffi/" -SRC_URI=" - https://github.com/python-hyper/${PN}/archive/v${PV}.tar.gz - -> ${P}.gh.tar.gz - test? ( - https://github.com/google/brotli/archive/${BROTLI_BUNDLED_COMMIT}.tar.gz - -> brotli-${BROTLI_BUNDLED_COMMIT}.tar.gz - )" - -LICENSE="MIT" -SLOT="0" -KEYWORDS="~alpha amd64 arm arm64 hppa ~ia64 ppc ppc64 ~riscv ~s390 sparc x86 ~x64-cygwin ~amd64-linux ~ppc-macos ~x64-macos ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris" - -RDEPEND=" - app-arch/brotli:= - virtual/python-cffi[${PYTHON_USEDEP}]" -DEPEND=" - test? ( - dev-python/hypothesis[${PYTHON_USEDEP}] - ) -" - -distutils_enable_tests pytest - -PATCHES=( - # remove custom dictionary code that isn't supported by new brotli - "${FILESDIR}"/brotlicffi-0.8.0-remove-dict.patch -) - -src_unpack() { - default - if use test; then - mv "brotli-${BROTLI_BUNDLED_COMMIT}"/tests "${S}"/libbrotli/ || die - fi -} - -src_configure() { - export USE_SHARED_BROTLI=1 -} diff --git a/dev-python/brotlicffi/brotlicffi-1.0.9.1.ebuild b/dev-python/brotlicffi/brotlicffi-1.0.9.1.ebuild index 0ef276a501d1..55423b5c51be 100644 --- a/dev-python/brotlicffi/brotlicffi-1.0.9.1.ebuild +++ b/dev-python/brotlicffi/brotlicffi-1.0.9.1.ebuild @@ -24,7 +24,7 @@ SRC_URI=" LICENSE="MIT" SLOT="0" -KEYWORDS="~alpha amd64 arm arm64 ~hppa ~ia64 ppc ppc64 ~riscv ~s390 sparc x86 ~x64-cygwin ~amd64-linux ~ppc-macos ~x64-macos ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris" +KEYWORDS="~alpha amd64 arm arm64 hppa ~ia64 ppc ppc64 ~riscv ~s390 sparc x86 ~x64-cygwin ~amd64-linux ~ppc-macos ~x64-macos ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris" RDEPEND=" app-arch/brotli:= diff --git a/dev-python/brotlicffi/files/brotlicffi-0.8.0-remove-dict.patch b/dev-python/brotlicffi/files/brotlicffi-0.8.0-remove-dict.patch deleted file mode 100644 index bfb1b61b951b..000000000000 --- a/dev-python/brotlicffi/files/brotlicffi-0.8.0-remove-dict.patch +++ /dev/null @@ -1,132 +0,0 @@ -From 0fe3dc70240ea62b56861ab830f9ab44644b18e5 Mon Sep 17 00:00:00 2001 -From: Seth Michael Larson <sethmichaellarson@gmail.com> -Date: Sat, 28 Nov 2020 14:36:59 -0600 -Subject: [PATCH] Update libbrotli to 1.0.9 - -(stripped down to removing custom dictionary support) - ---- - src/brotlicffi/_api.py | 21 ++---------- - src/brotlicffi/_build.py | 25 +------------- - test/test_simple_compression.py | 8 ----- - -diff --git a/src/brotlicffi/_api.py b/src/brotlicffi/_api.py -index 49da0a3..8358d3f 100644 ---- a/src/brotlicffi/_api.py -+++ b/src/brotlicffi/_api.py -@@ -95,8 +95,7 @@ def compress(data, - mode=DEFAULT_MODE, - quality=lib.BROTLI_DEFAULT_QUALITY, - lgwin=lib.BROTLI_DEFAULT_WINDOW, -- lgblock=0, -- dictionary=b''): -+ lgblock=0): - """ - Compress a string using Brotli. - -@@ -124,11 +123,6 @@ def compress(data, - based on ``quality``. - :type lgblock: ``int`` - -- :param dictionary: A pre-set dictionary for LZ77. Please use this with -- caution: if a dictionary is used for compression, the same dictionary -- **must** be used for decompression! -- :type dictionary: ``bytes`` -- - :returns: The compressed bytestring. - :rtype: ``bytes`` - """ -@@ -141,8 +135,7 @@ def compress(data, - mode=mode, - quality=quality, - lgwin=lgwin, -- lgblock=lgblock, -- dictionary=dictionary -+ lgblock=lgblock - ) - compressed_data = compressor._compress(data, lib.BROTLI_OPERATION_FINISH) - assert lib.BrotliEncoderIsFinished(compressor._encoder) == lib.BROTLI_TRUE -@@ -255,8 +248,7 @@ def __init__(self, - mode=DEFAULT_MODE, - quality=lib.BROTLI_DEFAULT_QUALITY, - lgwin=lib.BROTLI_DEFAULT_WINDOW, -- lgblock=0, -- dictionary=b''): -+ lgblock=0): - enc = lib.BrotliEncoderCreateInstance( - ffi.NULL, ffi.NULL, ffi.NULL - ) -@@ -271,13 +263,6 @@ def __init__(self, - _set_parameter(enc, lib.BROTLI_PARAM_LGWIN, "lgwin", lgwin) - _set_parameter(enc, lib.BROTLI_PARAM_LGBLOCK, "lgblock", lgblock) - -- if dictionary: -- self._dictionary = ffi.new("uint8_t []", dictionary) -- self._dictionary_size = len(dictionary) -- lib.BrotliEncoderSetCustomDictionary( -- enc, self._dictionary_size, self._dictionary -- ) -- - self._encoder = enc - - def _compress(self, data, operation): -diff --git a/src/brotlicffi/_build.py b/src/brotlicffi/_build.py -index d2a2d85..45dccb6 100644 ---- a/src/brotlicffi/_build.py -+++ b/src/brotlicffi/_build.py -@@ -93,20 +93,6 @@ - uint8_t** next_out, - size_t* total_out); - -- /* Fills the new state with a dictionary for LZ77, warming up the -- ringbuffer, e.g. for custom static dictionaries for data formats. -- Not to be confused with the built-in transformable dictionary of Brotli. -- |size| should be less or equal to 2^24 (16MiB), otherwise the dictionary -- will be ignored. The dictionary must exist in memory until decoding is -- done and is owned by the caller. To use: -- 1) Allocate and initialize state with BrotliCreateInstance -- 2) Use BrotliSetCustomDictionary -- 3) Use BrotliDecompressStream -- 4) Clean up and free state with BrotliDestroyState -- */ -- void BrotliDecoderSetCustomDictionary( -- BrotliDecoderState* s, size_t size, const uint8_t* dict); -- - /* Returns true, if decoder has some unconsumed output. - Otherwise returns false. */ - BROTLI_BOOL BrotliDecoderHasMoreOutput(const BrotliDecoderState* s); -@@ -205,15 +191,6 @@ - BrotliEncoderParameter p, - uint32_t value); - -- /* Fills the new state with a dictionary for LZ77, warming up the -- ringbuffer, e.g. for custom static dictionaries for data formats. -- Not to be confused with the built-in transformable dictionary of Brotli. -- To decode, use BrotliSetCustomDictionary() of the decoder with the same -- dictionary. */ -- void BrotliEncoderSetCustomDictionary(BrotliEncoderState* state, -- size_t size, -- const uint8_t* dict); -- - /* Check if encoder is in "finished" state, i.e. no more input is - acceptable and no more output will be produced. - Works only with BrotliEncoderCompressStream workflow. -diff --git a/test/test_simple_compression.py b/test/test_simple_compression.py -index 45c322d..a480587 100644 ---- a/test/test_simple_compression.py -+++ b/test/test_simple_compression.py -@@ -110,14 +110,6 @@ def test_compressed_data_roundtrips(s): - assert brotlicffi.decompress(brotlicffi.compress(s)) == s - - --@given(binary(), binary()) --def test_compressed_data_with_dictionaries(s, dictionary): -- d = brotlicffi.Decompressor(dictionary) -- compressed = brotlicffi.compress(s, dictionary=dictionary) -- uncompressed = d.decompress(compressed) -- assert uncompressed == s -- -- - @given(binary()) - def test_process_alias(s): - c1 = brotlicffi.Compressor() |