commit:     f097d26a85cb22bd90128541d6d4a1b7fe6bf375
Author:     Marcin Deranek <marcin.deranek <AT> slonko <DOT> net>
AuthorDate: Tue May 14 18:20:52 2024 +0000
Commit:     Michał Górny <mgorny <AT> gentoo <DOT> org>
CommitDate: Tue Jun  4 05:34:25 2024 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=f097d26a

media-gfx/img2pdf: Version bump to 0.5.1

Signed-off-by: Marcin Deranek <marcin.deranek <AT> slonko.net>
Co-authored-by: Michał Górny <mgorny <AT> gentoo.org>
Closes: https://bugs.gentoo.org/921240
Closes: https://bugs.gentoo.org/929621
Closes: https://github.com/gentoo/gentoo/pull/36678
Signed-off-by: Michał Górny <mgorny <AT> gentoo.org>

 media-gfx/img2pdf/Manifest             |  1 +
 media-gfx/img2pdf/img2pdf-0.5.1.ebuild | 69 ++++++++++++++++++++++++++++++++++
 2 files changed, 70 insertions(+)

diff --git a/media-gfx/img2pdf/Manifest b/media-gfx/img2pdf/Manifest
index 35ac654c914e..73c1d21dd6d9 100644
--- a/media-gfx/img2pdf/Manifest
+++ b/media-gfx/img2pdf/Manifest
@@ -1 +1,2 @@
 DIST img2pdf-0.4.4.tar.gz 97796 BLAKE2B 
d04eae8c02490e4e73339dade92b2521ad410ed741ccc2987961543790589b14a5c8939cb9bbadcc795f5edcbb59a1a43bd522c75948f42dde1acffafb6266e0
 SHA512 
56943cd965b3e6b0680b7696ca4b5a2ba779474f945dd0d2648fb6f18ab18aab6d74640f9bd8e9c8683e3e641b0657cb84c691054910d84f0c9e8ad733f179e9
+DIST img2pdf-0.5.1.tar.gz 104241 BLAKE2B 
1ea89107654c91cea8b5f074c05c7376452dd2ebd40dafaadedb39ac3ee383c3c02c1375b130da73339e1f87eb1a6ffbe0553cdedf6ec997bc0731d1d100327f
 SHA512 
e17a920929f6ab08f501b205c38f9cf2fd5a6bd8d41ac4819a5d7463a3cfbeb5376cd5bbee36ab303248610f1d5c8a71a38ff85b14be564e2f39c6eb537ffcaf

diff --git a/media-gfx/img2pdf/img2pdf-0.5.1.ebuild 
b/media-gfx/img2pdf/img2pdf-0.5.1.ebuild
new file mode 100644
index 000000000000..623b63caa284
--- /dev/null
+++ b/media-gfx/img2pdf/img2pdf-0.5.1.ebuild
@@ -0,0 +1,69 @@
+# Copyright 1999-2024 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+DISTUTILS_USE_PEP517=setuptools
+PYTHON_COMPAT=( python3_{10..12} )
+
+inherit distutils-r1 pypi
+
+DESCRIPTION="Losslessly convert raster images to PDF"
+HOMEPAGE="
+       https://gitlab.mister-muffin.de/josch/img2pdf/
+       https://pypi.org/project/img2pdf/
+"
+
+LICENSE="LGPL-3+"
+SLOT="0"
+KEYWORDS="~amd64 ~x86"
+IUSE="gui"
+
+BDEPEND="
+       test? (
+               app-text/ghostscript-gpl
+               app-text/mupdf
+               app-text/poppler[cairo,png,tiff]
+               dev-python/numpy[${PYTHON_USEDEP}]
+               dev-python/pdfrw[${PYTHON_USEDEP}]
+               dev-python/pillow[tiff,${PYTHON_USEDEP}]
+               dev-python/scipy[${PYTHON_USEDEP}]
+               media-gfx/imagemagick[jpeg,jpeg2k,lcms,png,-q8,-q32,tiff]
+               media-libs/exiftool
+               media-libs/netpbm[jpeg]
+               sys-libs/libfaketime
+       )
+"
+RDEPEND="
+       dev-python/pikepdf[${PYTHON_USEDEP}]
+       dev-python/pillow[${PYTHON_USEDEP}]
+       media-libs/icc-profiles-openicc
+       gui? ( $(python_gen_impl_dep tk) )
+"
+
+distutils_enable_tests pytest
+
+src_prepare() {
+       distutils-r1_python_prepare_all
+
+       # Remove gui executable if there's no demand/support for it.
+       if ! use gui; then
+               sed -i -e '/gui_scripts/d' setup.py || die
+       fi
+}
+
+src_test() {
+       local EPYTEST_DESELECT=(
+               # https://gitlab.mister-muffin.de/josch/img2pdf/issues/187
+               src/img2pdf_test.py::test_miff_cmyk8
+       )
+
+       if has_version 'media-gfx/imagemagick[hdri]'; then
+               # https://gitlab.mister-muffin.de/josch/img2pdf/issues/178
+               EPYTEST_DESELECT+=(
+                       src/img2pdf_test.py::test_miff_cmyk16
+               )
+       fi
+
+       distutils-r1_src_test
+}

Reply via email to