summaryrefslogtreecommitdiff
path: root/dev-python/pypdf
diff options
context:
space:
mode:
Diffstat (limited to 'dev-python/pypdf')
-rw-r--r--dev-python/pypdf/Manifest4
-rw-r--r--dev-python/pypdf/metadata.xml12
-rw-r--r--dev-python/pypdf/pypdf-3.2.0.ebuild62
3 files changed, 78 insertions, 0 deletions
diff --git a/dev-python/pypdf/Manifest b/dev-python/pypdf/Manifest
new file mode 100644
index 000000000000..fbbc574c74e0
--- /dev/null
+++ b/dev-python/pypdf/Manifest
@@ -0,0 +1,4 @@
+DIST pypdf-3.2.0.gh.tar.gz 6618810 BLAKE2B 33ade8743339415b58f2397a55972479bdfd6ed87c68ea9cc1c9f05c80210a6265e97f1f26dfc3bd2bd74c6c11ab45d8a3d9ded1b150e96f804f9893c74fb517 SHA512 a3db36086733f6bfdfd4e6b56dc976e30c2940362fcf1e8b4c61b3c8d421c870821eb7c5dcbc41e6362f487d474c5d2bcfbe6b9aabd8c496d3a030aa40d1af57
+DIST pypdf-sample-files-0fe84b30ed33ff3daa9293e44349b8618f135699.gh.tar.gz 9027166 BLAKE2B 912bb9fbd632bd0ad2cc2e865a1e6870ad7064aa2cf4d6f96217f63ac685e9a511f0bb20c22d48ae970a2eb171b27a0fa680fa42892425531f69735840cf741b SHA512 07a71a3566dabcea5dc8a549949d0f0c0f9483d5d9f85851d6e4e702dd374b348469a80e5300d18983e560ee9a44d0639b55eb338023b9ebbdb26c6f8c455e07
+EBUILD pypdf-3.2.0.ebuild 1369 BLAKE2B b99f53187896e697e3c7ec900edfd81b1760e01c939880bb6c46275f38cddc1df7c59873e35b70112d09becc58dd859dd4830d9004ca0e3ec82b0e937ed0507a SHA512 4f3bef000ecd0190809323dd1dd25cfb53367e60b9fe780bc40c0aeca167fd3b43a48cde3bb380c8dcc2894463c7013b7dce4fc02928495fae0486cf117ec9c3
+MISC metadata.xml 373 BLAKE2B a829b7048eb3a95caeb1be83b6172603df6a031d40995294f2687bf3c3cb70e66fafb9ba8339d9979fc85f5936b9552963a8fcd072a20661fa78f3aa3c4b89c0 SHA512 775ac2de487f11fba1ea8d283b42b9ef56e42cd95ea11f50a06b099420e69c0567f65c506b14891ac641da90ea05ca70da4f8a3e4a028cf41bdbc823021dccfe
diff --git a/dev-python/pypdf/metadata.xml b/dev-python/pypdf/metadata.xml
new file mode 100644
index 000000000000..75594da4e373
--- /dev/null
+++ b/dev-python/pypdf/metadata.xml
@@ -0,0 +1,12 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "https://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+ <maintainer type="project">
+ <email>python@gentoo.org</email>
+ <name>Python</name>
+ </maintainer>
+ <upstream>
+ <remote-id type="pypi">pypdf</remote-id>
+ <remote-id type="github">py-pdf/pypdf</remote-id>
+ </upstream>
+</pkgmetadata>
diff --git a/dev-python/pypdf/pypdf-3.2.0.ebuild b/dev-python/pypdf/pypdf-3.2.0.ebuild
new file mode 100644
index 000000000000..14f4890dfa3f
--- /dev/null
+++ b/dev-python/pypdf/pypdf-3.2.0.ebuild
@@ -0,0 +1,62 @@
+# Copyright 1999-2023 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+DISTUTILS_USE_PEP517=flit
+PYTHON_COMPAT=( python3_{8..11} )
+
+inherit distutils-r1
+
+SAMPLE_COMMIT=0fe84b30ed33ff3daa9293e44349b8618f135699
+DESCRIPTION="Python library to work with PDF files"
+HOMEPAGE="
+ https://pypi.org/project/pypdf/
+ https://github.com/py-pdf/pypdf/
+"
+SRC_URI="
+ https://github.com/py-pdf/pypdf/archive/${PV}.tar.gz
+ -> ${P}.gh.tar.gz
+ test? (
+ https://github.com/py-pdf/sample-files/archive/${SAMPLE_COMMIT}.tar.gz
+ -> ${PN}-sample-files-${SAMPLE_COMMIT}.gh.tar.gz
+ )
+"
+S=${WORKDIR}/pypdf-${PV}
+
+LICENSE="BSD-2"
+SLOT="0"
+KEYWORDS="~amd64 ~arm64 ~ppc64 ~x86"
+RESTRICT="test"
+# 150+ tests require network, too many to deselect
+PROPERTIES="test_network"
+
+RDEPEND="
+ $(python_gen_cond_dep '
+ dev-python/typing-extensions[${PYTHON_USEDEP}]
+ ' 3.8 3.9)
+"
+BDEPEND="
+ dev-python/pillow[${PYTHON_USEDEP}]
+ test? (
+ dev-python/pycryptodome[${PYTHON_USEDEP}]
+ )
+"
+
+distutils_enable_tests pytest
+
+EPYTEST_DESELECT=(
+ # rely on -Werror
+ tests/test_utils.py::test_deprecate_no_replacement
+ tests/test_workflows.py::test_orientations
+ # dead URL
+ # https://github.com/py-pdf/pypdf/issues/1526
+ tests/test_xmp.py::test_issue585
+)
+
+src_unpack() {
+ default
+ if use test; then
+ mv "sample-files-${SAMPLE_COMMIT}"/* "${S}"/sample-files/ || die
+ fi
+}