dev-python/pillow: add 11.0.0-r2

Closes: #4216
Signed-off-by: Andreas Billmeier <b@edevau.net>
This commit is contained in:
Andreas Billmeier 2025-02-22 13:34:53 +01:00
parent 786a548834
commit 4b38646857
Signed by: onkelbeh
GPG Key ID: E6DB12C8C550F3C0
6 changed files with 239 additions and 2 deletions

View File

@ -606,12 +606,12 @@ A daily compile test is run at Github with Python 3.9 to catch general faults. E
## Licenses
This repository itself is released under GPL-3 (like most Gentoo repositories), all work on the depending components under the licenses they came from. Perhaps you came here because I filed an issue at your component about a bad or missing license. It is easy to [assign a license](https://docs.github.com/en/communities/setting-up-your-project-for-healthy-contributions/adding-a-license-to-a-repository). During cleanups and license investigations I have been asked often which license to choose. I am not a lawyer, but I can offer the following table, counted over this repository, perhaps this helps your decision. If a package has more than one license listed, all of them are counted.
There are 2382 Ebuilds in total, 2364 of them have in total 2408 (43 different) licenses assigned.
There are 2383 Ebuilds in total, 2365 of them have in total 2409 (43 different) licenses assigned.
|License| Ebuilds using it|
|-------|-----|
|MIT|1354|
|Apache-2.0|550|
|Apache-2.0|551|
|GPL-3|149|
|BSD|128|
|GPL-2|30|

View File

@ -1,6 +1,11 @@
AUX pillow-10.2.0-cross.patch 2390 BLAKE2B d690b3f93d59c32d0f1b209b51ea4787230892488059ec206f548276a1f697394ca539fcd9f92fa7c547b37dd6b4fc738400a3034f54eec6260f0f98ae372b39 SHA512 4afaec6964298e2f1c21fea77791ce0cdacdbc65bf9798d46e99681c772065c1ad1175f5821162157cacac64f556e320af2ca7dcbd0806c07d04f8116f8f508c
AUX pillow-10.3.0-py313.patch 691 BLAKE2B acd10146af5467543c44a29bd8236f79fee803d1d0b3bf97b3db2e6ae817f81f30382e9751ae694039ae589a04e4f1ac5169e9a2e60ba5a10c9d2bee1fe00dfb SHA512 5ecd82ae120e3456902f3ab44b0c7a3491ba33de987d005e2a966e8150c45baef46dd357db997662c02734ac00eeaa6a544372610c06e6435e282f5e4fed73aa
AUX pillow-11.0.0-automagic-disable.patch 909 BLAKE2B 39a431178a8f7d1382cfaeea4e2bb1bd0eba3d9a520bfa6116d62ae85220e334347533335ec8a035d849ccd16abe7cc7171d3105e9f79269184a0295685b0c06 SHA512 b72351c27e89884125878538a3ee4bf38765e12b7fb4ad6ec5cf776ce262a6e6ef6a43640822c55958ccb98276b5496b5a1bc889301951137999204455356ed4
AUX pillow-11.0.0-wrong-arg.patch 1242 BLAKE2B 0da76fa225e8107ad15639e540b3935e868e7682d4a241ca609fb019e1269f473b084c35e35d30102c20ee1ca505d1290953e3393e382dcf15bd6f794e080415 SHA512 5f74e04d76f7280bd053b02b01bbff22ce2fc95c1fa8e7c279df9171c61d6a747bbf46644a065fde15457ac6ec008713d8746d611561caf2a0058a84448be15f
DIST pillow-10.4.0.gh.tar.gz 46617167 BLAKE2B 3eb7852ab087d18e5b9a03d6cbf83ead96b637a71d4209a4574d66c9d098936d240c0be3235d9e951ec094b9b0def196b265a8e68f59802f843171c74ca7bbac SHA512 835a8766c384ec3fcf67b42c9bbad35dad0848cc5bd9eba1b0768a864e174a1d9c4a5e989f22496a40f2c29dd7f492f6f80465903fe872b10749cfa0340e1bc5
DIST pillow-11.0.0.gh.tar.gz 46807844 BLAKE2B c91b92152d2f763fd20a74e2bddf413a669430074b8c5304b623ff63df177346ec4031e928fbc9765e1e0ca5f21cc101d5b7688a09dea19c5828f0cea02fe018 SHA512 0a74d7b12311acb3c9b39af87dc4e1e2ecae22134300a2a8c979daa3947a20f78bf77a93cd7f0029e98936a07e8d5e4fae826322fe0ccc1d1a8200350f9cbb7b
DIST pillow-9.3.0.gh.tar.gz 50370806 BLAKE2B d0d4775c8b60e40560328e4f1c14055743d1a826b0ab01353075f1f48a461bcd8bf5883f18713976399f9b0f688125f3a883ea5818a359db9e540aac8895f02a SHA512 60c529d8a222a521a0c3f4254917aa3f6c5a47c7cb8930b4b9a05ef442d1a7e776018dc4ac834a9effc1342f8457898cae79820531ff430728f6c39d6297b2d7
EBUILD pillow-10.4.0.ebuild 3260 BLAKE2B cffd5f498b1842ed0a387e23283dd5230a1a42e8f9fe79f791837d286b172f0604ec67a2d5b0cd7e343163b302d9ee4c71f1f1197b46ddfd806625e275785af3 SHA512 6b2e6c55e73a478306ee0047c627fac0a4bf022fa109551304ab95ff15386a924965e552c9003b5abc4654c30c5ec3709193e2ce3b8eddc7d0e6a93c67d58971
EBUILD pillow-11.0.0-r2.ebuild 3695 BLAKE2B 5c315b65f39bae72c1fdad2f3aa61ce999aeda4f73544d1e972d1ac0747d64443c06a8d879294920f0bde2f192ced39c8f0f6f5a1a94b041213134741ff13540 SHA512 919ccea1347dde72433cb87e7604c9fa3a500e948357f83bf09e9ac825611e674a8cacb2af2ff5fb41f02ab1bf62c7e3e207aef11fd198cf4ea923ce405f00af
EBUILD pillow-9.3.0-r1.ebuild 3133 BLAKE2B 2ffb1f928439f1ccf987aa6fb136efd8e829c539d1e64006490fbbe8a4574278efd5ff5cee7cc7cf4d5de3164ece8ddcd543461a1902bd4ce423648074158930 SHA512 8154590708f0f629f482971b852de23dcee13f9440ba49ea8d77a37fb05b3862fe87a6e9e40afc59cbdb8eb36eabe4a7f33779474d826ed84577c2361d2d086d
MISC metadata.xml 631 BLAKE2B cda3df63a3bacffde043eef6ba61724901c162a16c78c91aed77d86a8b945b1e433f861d7598d3090bb3a99ac6b7b84d6625f310d6aff7430edb38af8d64f269 SHA512 186c23985165836f73248a6f610e61af6d8998d1df597ffc91e2b23dff5215e2d100b85232b9dd388dfd6055f93fc03d295f23863ba2f3037537b31f6258f98a

View File

@ -0,0 +1,23 @@
From 57399ce204d79c74c80612c622bb788e20d786e8 Mon Sep 17 00:00:00 2001
From: Andrew Murray <radarhere@users.noreply.github.com>
Date: Fri, 10 May 2024 22:43:56 +1000
Subject: [PATCH] Parse _version contents instead of using exec()
---
setup.py | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/setup.py b/setup.py
index 7d8e1c1ee21..abdd87ea252 100644
--- a/setup.py
+++ b/setup.py
@@ -23,8 +23,7 @@
def get_version():
version_file = "src/PIL/_version.py"
with open(version_file, encoding="utf-8") as f:
- exec(compile(f.read(), version_file, "exec"))
- return locals()["__version__"]
+ return f.read().split('"')[1]
configuration = {}

View File

@ -0,0 +1,26 @@
https://bugs.gentoo.org/947136
https://github.com/python-pillow/Pillow/issues/8468
https://github.com/python-pillow/Pillow/pull/8469
From 7c194b54ef3e7a04c5b669353622687075b5ebb4 Mon Sep 17 00:00:00 2001
From: Andrew Murray <radarhere@users.noreply.github.com>
Date: Wed, 16 Oct 2024 21:37:14 +1100
Subject: [PATCH] Fixed disabling a feature
---
setup.py | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/setup.py b/setup.py
index 60707083f6e..def3417845d 100644
--- a/setup.py
+++ b/setup.py
@@ -389,7 +389,7 @@ def finalize_options(self) -> None:
pass
for x in self.feature:
if getattr(self, f"disable_{x}"):
- setattr(self.feature, x, False)
+ self.feature.set(x, False)
self.feature.required.discard(x)
_dbg("Disabling %s", x)
if getattr(self, f"enable_{x}"):

View File

@ -0,0 +1,32 @@
From 180c1d1ef0c0ef12e0c56adfe10c7779dff3b55f Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Micha=C5=82=20G=C3=B3rny?= <mgorny@gentoo.org>
Date: Sun, 3 Nov 2024 16:35:54 +0100
Subject: [PATCH] Revert "Corrected passing TIFF_LONG to libtiff"
This is the wrong solution to the problem at hand, and results
in passing an int64_t where libtiff expects uint32_t. This seems
to miraculously work on most of our platforms but it is clearly wrong,
and it breaks ppc32.
Bug: https://github.com/python-pillow/Pillow/issues/8522
Reverts: b1b0353d17bcdca99cfcb2ea48c6af7861fb43ba
---
src/encode.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/src/encode.c b/src/encode.c
index 1a4cd489d..ba350c39a 100644
--- a/src/encode.c
+++ b/src/encode.c
@@ -929,7 +929,7 @@ PyImaging_LibTiffEncoderNew(PyObject *self, PyObject *args) {
);
} else if (type == TIFF_LONG) {
status = ImagingLibTiffSetField(
- &encoder->state, (ttag_t)key_int, PyLong_AsLongLong(value)
+ &encoder->state, (ttag_t)key_int, (UINT32)PyLong_AsLong(value)
);
} else if (type == TIFF_SSHORT) {
status = ImagingLibTiffSetField(
--
2.47.0

View File

@ -0,0 +1,151 @@
# Copyright 1999-2024 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
DISTUTILS_EXT=1
# setuptools wrapper
DISTUTILS_USE_PEP517=standalone
PYTHON_COMPAT=( python3_{11..13} )
PYTHON_REQ_USE='tk?,threads(+)'
inherit distutils-r1 toolchain-funcs virtualx
MY_PN=Pillow
MY_P=${MY_PN}-${PV}
DESCRIPTION="Python Imaging Library (fork)"
HOMEPAGE="
https://python-pillow.org/
https://github.com/python-pillow/Pillow/
https://pypi.org/project/pillow/
"
SRC_URI="
https://github.com/python-pillow/Pillow/archive/${PV}.tar.gz
-> ${P}.gh.tar.gz
"
S="${WORKDIR}/${MY_P}"
LICENSE="HPND"
SLOT="0"
KEYWORDS="amd64 arm arm64 x86"
IUSE="examples imagequant +jpeg jpeg2k lcms test tiff tk truetype webp xcb zlib"
REQUIRED_USE="test? ( jpeg jpeg2k lcms tiff truetype )"
RESTRICT="!test? ( test )"
DEPEND="
imagequant? ( media-gfx/libimagequant:= )
jpeg? ( media-libs/libjpeg-turbo:= )
jpeg2k? ( media-libs/openjpeg:2= )
lcms? ( media-libs/lcms:2= )
tiff? ( media-libs/tiff:=[jpeg,zlib] )
truetype? ( media-libs/freetype:2= )
webp? ( media-libs/libwebp:= )
xcb? ( x11-libs/libxcb )
zlib? ( sys-libs/zlib:= )
"
RDEPEND="
${DEPEND}
dev-python/olefile[${PYTHON_USEDEP}]
"
BDEPEND="
dev-python/setuptools[${PYTHON_USEDEP}]
dev-python/wheel[${PYTHON_USEDEP}]
virtual/pkgconfig
test? (
dev-python/defusedxml[${PYTHON_USEDEP}]
dev-python/packaging[${PYTHON_USEDEP}]
dev-python/pytest-timeout[${PYTHON_USEDEP}]
|| (
media-gfx/imagemagick[png]
media-gfx/graphicsmagick[png]
)
)
"
EPYTEST_XDIST=1
distutils_enable_tests pytest
PATCHES=(
# https://github.com/python-pillow/pillow/pull/7634
"${FILESDIR}/${PN}-10.2.0-cross.patch"
# https://github.com/python-pillow/Pillow/issues/8522
"${FILESDIR}/${P}-wrong-arg.patch"
# https://github.com/python-pillow/Pillow/pull/8469
"${FILESDIR}/${P}-automagic-disable.patch"
)
usepil() {
usex "${1}" enable disable
}
python_configure_all() {
cat >> setup.cfg <<-EOF || die
[build_ext]
debug = True
disable_platform_guessing = True
$(usepil truetype)_freetype = True
$(usepil jpeg)_jpeg = True
$(usepil jpeg2k)_jpeg2000 = True
$(usepil lcms)_lcms = True
$(usepil tiff)_tiff = True
$(usepil imagequant)_imagequant = True
$(usepil webp)_webp = True
$(usepil xcb)_xcb = True
$(usepil zlib)_zlib = True
EOF
if use truetype; then
# these dependencies are implicitly disabled by USE=-truetype
# and we can't pass both disable_* and vendor_*
# https://bugs.gentoo.org/935124
cat >> setup.cfg <<-EOF || die
vendor_raqm = False
vendor_fribidi = False
EOF
fi
tc-export PKG_CONFIG
}
src_test() {
virtx distutils-r1_src_test
}
python_test() {
local EPYTEST_DESELECT=(
# TODO (is clipboard unreliable in Xvfb?)
Tests/test_imagegrab.py::TestImageGrab::test_grabclipboard
# requires xz-utils[extra-filters]?
Tests/test_file_libtiff.py::TestFileLibTiff::test_lzma
)
case ${ARCH} in
ppc)
EPYTEST_DESELECT+=(
# https://github.com/python-pillow/Pillow/issues/7008
# (we've reverted the upstream patch because it was worse
# than the original issue)
Tests/test_file_libtiff.py::TestFileLibTiff::test_exif_ifd
)
;;
esac
"${EPYTHON}" selftest.py --installed || die "selftest failed with ${EPYTHON}"
local -x PYTEST_DISABLE_PLUGIN_AUTOLOAD=1
# leak tests are fragile and broken under xdist
epytest -k "not leak" -p timeout || die "Tests failed with ${EPYTHON}"
}
python_install() {
python_doheader src/libImaging/*.h
distutils-r1_python_install
}
python_install_all() {
if use examples ; then
docinto example
dodoc docs/example/*
docompress -x /usr/share/doc/${PF}/example
fi
distutils-r1_python_install_all
}