forked from pool/python-imagecodecs
Accepting request 903287 from home:bnavigator:branches:devel:languages:python
- Update to 2021.6.8 * Pass 5185 tests. * Fix building with Cython 0.3a7. * Decode TIFF with JPEG compression, YCBCR or CMYK colorspace as RGB24. * Vendor cfitsio/ricecomp.c for shared library builds on Windows (#18). - Release 2021.5.20 * Add ZLIBNG codec via zlib-ng library. * Add RCOMP (Rice) codec via cfitsio library. * Fix decoding of 16-bit JPEG with jpeg_decode. * Relax user provided output array shape requirement. - Release 2021.4.28 * Change WebP default compression level to lossless. * Rename jpegxl codec to brunsli (breaking). * Add new JPEG XL codec via jpeg-xl library. * Add PGLZ codec via PostgreSQL's pg_lzcompress.c. * Update to libtiff 4.3 and libjpeg-turbo 2.1. * Enable JPEG 12-bit codec in manylinux wheels. * Drop manylinux2010 wheels. - Release 2021.3.31 * Add numcodecs compatible codecs for use by Zarr (experimental). * Support separate JPEG header in jpeg_decode. * Do not decode JPEG LS and XL in jpeg_decode (breaking). * Fix ZFP with partial header. * Fix JPEG LS tests (#15). * Fix LZ4F contentchecksum. * Remove blosc Snappy tests. * Fix docstrings. - drop imagecodecs-pr15-test_jpegls.patch fixed upstream- - refresh always-cythonize.patch OBS-URL: https://build.opensuse.org/request/show/903287 OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-imagecodecs?expand=0&rev=16
This commit is contained in:
parent
b8f177977f
commit
c84e56f8fa
@ -1,12 +1,12 @@
|
||||
Index: imagecodecs-2021.1.28/setup.py
|
||||
Index: imagecodecs-2021.6.8/setup.py
|
||||
===================================================================
|
||||
--- imagecodecs-2021.1.28.orig/setup.py
|
||||
+++ imagecodecs-2021.1.28/setup.py
|
||||
--- imagecodecs-2021.6.8.orig/setup.py
|
||||
+++ imagecodecs-2021.6.8/setup.py
|
||||
@@ -105,7 +105,7 @@ def ext(**kwargs):
|
||||
|
||||
|
||||
OPTIONS = {
|
||||
- 'cythonize': sys.version_info >= (3, 10) or 'PyPy' in sys.version,
|
||||
- 'cythonize': 'PyPy' in sys.version, # or sys.version_info >= (3, 10)
|
||||
+ 'cythonize': True,
|
||||
'include_dirs': ['imagecodecs'],
|
||||
'library_dirs': [],
|
||||
|
@ -1,3 +0,0 @@
|
||||
version https://git-lfs.github.com/spec/v1
|
||||
oid sha256:b479064983ea963b520dbd63b388f69ec8ddc4b12a8c77142d868982f17f400b
|
||||
size 9419303
|
3
imagecodecs-2021.6.8.tar.gz
Normal file
3
imagecodecs-2021.6.8.tar.gz
Normal file
@ -0,0 +1,3 @@
|
||||
version https://git-lfs.github.com/spec/v1
|
||||
oid sha256:4b2799ee39a3bc465d2068b70dc6eb643aa4817435d3ef38cc087f5e863dc9da
|
||||
size 10181378
|
@ -1,31 +0,0 @@
|
||||
From b14af25da949b88fb09339fd84ac97e67aa9109f Mon Sep 17 00:00:00 2001
|
||||
From: Ben Greiner <code@bnavigator.de>
|
||||
Date: Wed, 10 Mar 2021 13:22:50 +0100
|
||||
Subject: [PATCH] Check if JPEGLS is present when testing that codec
|
||||
|
||||
---
|
||||
tests/test_imagecodecs.py | 4 ++--
|
||||
1 file changed, 2 insertions(+), 2 deletions(-)
|
||||
|
||||
diff --git a/tests/test_imagecodecs.py b/tests/test_imagecodecs.py
|
||||
index a057e15..c70a155 100644
|
||||
--- a/tests/test_imagecodecs.py
|
||||
+++ b/tests/test_imagecodecs.py
|
||||
@@ -1535,7 +1535,7 @@ def test_jpeg2k_ycbc():
|
||||
assert tuple(decoded[-1, -1]) == (0, 0, 0)
|
||||
|
||||
|
||||
-@pytest.mark.skipif(not imagecodecs.JPEGXL, reason='jpegls missing')
|
||||
+@pytest.mark.skipif(not imagecodecs.JPEGLS, reason='jpegls missing')
|
||||
@pytest.mark.parametrize('output', ['new', 'out', 'bytearray'])
|
||||
def test_jpegls_decode(output):
|
||||
"""Test JPEG LS decoder with RGBA32 image."""
|
||||
@@ -1889,7 +1889,7 @@ def encode(data, *args, **kwargs):
|
||||
)
|
||||
|
||||
elif codec == 'jpegls':
|
||||
- if not imagecodecs.JPEGXL:
|
||||
+ if not imagecodecs.JPEGLS:
|
||||
pytest.skip(f'{codec} missing')
|
||||
if itype in ('view', 'graya') or deout == 'view':
|
||||
pytest.xfail('jpegls does not support this case')
|
@ -11,7 +11,8 @@ def customize_build(EXTENSIONS, OPTIONS):
|
||||
del EXTENSIONS['jpeg12'] # jpeg12 requires custom build
|
||||
del EXTENSIONS['lerc'] # LERC library not available
|
||||
del EXTENSIONS['lz4f'] # requires static linking
|
||||
del EXTENSIONS['jpegxl'] # Brunsli library not available
|
||||
del EXTENSIONS['jpegxl'] # jpeg-xl library not available
|
||||
del EXTENSIONS['brunsli'] # Brunsli library not available
|
||||
|
||||
EXTENSIONS['avif']['libraries'] = [
|
||||
'avif',
|
||||
@ -19,10 +20,13 @@ def customize_build(EXTENSIONS, OPTIONS):
|
||||
'dav1d',
|
||||
'rav1e',
|
||||
]
|
||||
|
||||
|
||||
# no zfp on 32-bit platforms
|
||||
if sys.maxsize < 2**63 - 1:
|
||||
# no zfp on 32-bit platforms
|
||||
del EXTENSIONS['zfp']
|
||||
# avif tests fail on 32-bit
|
||||
del EXTENSIONS['avif']
|
||||
|
||||
|
||||
openjpeg_inc = subprocess.check_output(
|
||||
@ -30,6 +34,6 @@ def customize_build(EXTENSIONS, OPTIONS):
|
||||
text=True,
|
||||
).strip()
|
||||
EXTENSIONS['jpeg2k']['include_dirs'].append(openjpeg_inc)
|
||||
|
||||
EXTENSIONS['jpegxr']['include_dirs'].append(includedir + 'jxrlib')
|
||||
EXTENSIONS['rcomp']['include_dirs'].append(includedir + 'cfitsio')
|
||||
EXTENSIONS['zopfli']['include_dirs'].append(includedir + 'zopfli')
|
||||
|
@ -1,3 +1,36 @@
|
||||
-------------------------------------------------------------------
|
||||
Wed Jun 30 07:28:42 UTC 2021 - Ben Greiner <code@bnavigator.de>
|
||||
|
||||
- Update to 2021.6.8
|
||||
* Pass 5185 tests.
|
||||
* Fix building with Cython 0.3a7.
|
||||
* Decode TIFF with JPEG compression, YCBCR or CMYK colorspace as RGB24.
|
||||
* Vendor cfitsio/ricecomp.c for shared library builds on Windows (#18).
|
||||
- Release 2021.5.20
|
||||
* Add ZLIBNG codec via zlib-ng library.
|
||||
* Add RCOMP (Rice) codec via cfitsio library.
|
||||
* Fix decoding of 16-bit JPEG with jpeg_decode.
|
||||
* Relax user provided output array shape requirement.
|
||||
- Release 2021.4.28
|
||||
* Change WebP default compression level to lossless.
|
||||
* Rename jpegxl codec to brunsli (breaking).
|
||||
* Add new JPEG XL codec via jpeg-xl library.
|
||||
* Add PGLZ codec via PostgreSQL's pg_lzcompress.c.
|
||||
* Update to libtiff 4.3 and libjpeg-turbo 2.1.
|
||||
* Enable JPEG 12-bit codec in manylinux wheels.
|
||||
* Drop manylinux2010 wheels.
|
||||
- Release 2021.3.31
|
||||
* Add numcodecs compatible codecs for use by Zarr (experimental).
|
||||
* Support separate JPEG header in jpeg_decode.
|
||||
* Do not decode JPEG LS and XL in jpeg_decode (breaking).
|
||||
* Fix ZFP with partial header.
|
||||
* Fix JPEG LS tests (#15).
|
||||
* Fix LZ4F contentchecksum.
|
||||
* Remove blosc Snappy tests.
|
||||
* Fix docstrings.
|
||||
- drop imagecodecs-pr15-test_jpegls.patch fixed upstream-
|
||||
- refresh always-cythonize.patch
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Wed Mar 10 10:42:55 UTC 2021 - Ben Greiner <code@bnavigator.de>
|
||||
|
||||
|
@ -1,5 +1,5 @@
|
||||
#
|
||||
# spec file for package python-imagecodecs
|
||||
# spec file
|
||||
#
|
||||
# Copyright (c) 2021 SUSE LLC
|
||||
#
|
||||
@ -28,7 +28,7 @@
|
||||
%define skip_python2 1
|
||||
%define skip_python36 1
|
||||
Name: python-imagecodecs%{psuffix}
|
||||
Version: 2021.2.26
|
||||
Version: 2021.6.8
|
||||
Release: 0
|
||||
Summary: Image transformation, compression, and decompression codecs
|
||||
License: BSD-3-Clause
|
||||
@ -36,8 +36,6 @@ URL: https://github.com/cgohlke/imagecodecs/
|
||||
Source: https://files.pythonhosted.org/packages/source/i/imagecodecs/imagecodecs-%{version}.tar.gz
|
||||
Source1: imagecodecs_distributor_setup.py
|
||||
Patch0: always-cythonize.patch
|
||||
# PATCH-FIX-UPSTREAM imagecodecs-pr15-test_jpegls.patch -- gh#cgohlke/imagecodecs#15
|
||||
Patch1: https://github.com/cgohlke/imagecodecs/pull/15.patch#/imagecodecs-pr15-test_jpegls.patch
|
||||
BuildRequires: %{python_module Cython >= 0.29.19}
|
||||
BuildRequires: %{python_module numpy-devel >= 1.15.1}
|
||||
BuildRequires: %{python_module setuptools >= 18.0}
|
||||
@ -46,12 +44,13 @@ BuildRequires: fdupes
|
||||
BuildRequires: python-rpm-macros
|
||||
Requires: python-numpy >= 1.15.1
|
||||
Requires(post): update-alternatives
|
||||
Requires(postun): update-alternatives
|
||||
Requires(postun):update-alternatives
|
||||
Recommends: python-Pillow
|
||||
Recommends: python-blosc
|
||||
Recommends: python-lz4
|
||||
Recommends: python-matplotlib >= 3.1
|
||||
Recommends: python-tifffile >= 2020.5.25
|
||||
Recommends: python-numcodecs
|
||||
Recommends: python-tifffile >= 2021.1.11
|
||||
Recommends: python-zstd
|
||||
%if %{with test}
|
||||
BuildRequires: %{python_module Brotli}
|
||||
@ -61,10 +60,12 @@ BuildRequires: %{python_module czifile}
|
||||
BuildRequires: %{python_module imagecodecs >= %{version}}
|
||||
BuildRequires: %{python_module lz4}
|
||||
BuildRequires: %{python_module matplotlib >= 3.1}
|
||||
BuildRequires: %{python_module numcodecs}
|
||||
BuildRequires: %{python_module pytest}
|
||||
BuildRequires: %{python_module python-snappy}
|
||||
BuildRequires: %{python_module scikit-image}
|
||||
BuildRequires: %{python_module tifffile >= 2020.5.25}
|
||||
BuildRequires: %{python_module tifffile >= 2021.1.11}
|
||||
BuildRequires: %{python_module zarr}
|
||||
BuildRequires: %{python_module zstd}
|
||||
# libraries and python modules not (yet) available:
|
||||
#BuildRequires: %%{python_module bitshuffle}
|
||||
@ -86,8 +87,8 @@ BuildRequires: rav1e-devel
|
||||
BuildRequires: snappy-devel
|
||||
BuildRequires: pkgconfig(blosc)
|
||||
BuildRequires: pkgconfig(bzip2)
|
||||
BuildRequires: pkgconfig(cfitsio)
|
||||
BuildRequires: pkgconfig(lcms2)
|
||||
BuildRequires: pkgconfig(libavif)
|
||||
BuildRequires: pkgconfig(libbrotlicommon)
|
||||
BuildRequires: pkgconfig(libjpeg)
|
||||
BuildRequires: pkgconfig(liblz4)
|
||||
@ -98,9 +99,13 @@ BuildRequires: pkgconfig(libtiff-4)
|
||||
BuildRequires: pkgconfig(libwebp)
|
||||
BuildRequires: pkgconfig(libzstd)
|
||||
BuildRequires: pkgconfig(zlib)
|
||||
BuildRequires: pkgconfig(zlib-ng)
|
||||
%ifnarch %ix86 %arm
|
||||
# zfp is 64 bit only. Note that upstream deprecated 32-bit as a whole
|
||||
# Note that upstream deprecated 32-bit as a whole
|
||||
# zfp is 64 bit only.
|
||||
BuildRequires: zfp-devel
|
||||
# 32-bit tests fail
|
||||
BuildRequires: pkgconfig(libavif)
|
||||
%endif
|
||||
%endif
|
||||
# Upstream: big endian is not supported
|
||||
@ -132,7 +137,7 @@ ldd %{_libdir}/libblosc.so.1 | grep -q libsnappy && sed -i "s/if not IS_CG and c
|
||||
%build
|
||||
%if !%{with test}
|
||||
export CFLAGS="%{optflags}"
|
||||
export INCDIR="%{_includedir}"
|
||||
export INCDIR="%{_includedir}"
|
||||
%python_build
|
||||
%endif
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user