summaryrefslogtreecommitdiff
path: root/app-text
diff options
context:
space:
mode:
authorMarcin Deranek <marcin.deranek@booking.com>2022-12-27 21:31:47 +0100
committerMarcin Deranek <marcin.deranek@booking.com>2022-12-27 21:31:47 +0100
commit3e6a7e18703bd24d05900302c0f5160c93154919 (patch)
tree436979814dac72652334dff064bd17aed1aeffc5 /app-text
parent948456de1b862e13f58f95f083dd752cd726d8d2 (diff)
downloadportage-3e6a7e18703bd24d05900302c0f5160c93154919.tar.gz
portage-3e6a7e18703bd24d05900302c0f5160c93154919.tar.bz2
portage-3e6a7e18703bd24d05900302c0f5160c93154919.zip
Initial ebuild for app-text/OCRmyPDF
Diffstat (limited to 'app-text')
-rw-r--r--app-text/OCRmyPDF/Manifest3
-rw-r--r--app-text/OCRmyPDF/OCRmyPDF-14.0.1.ebuild67
-rw-r--r--app-text/OCRmyPDF/metadata.xml12
3 files changed, 82 insertions, 0 deletions
diff --git a/app-text/OCRmyPDF/Manifest b/app-text/OCRmyPDF/Manifest
new file mode 100644
index 0000000..50994ac
--- /dev/null
+++ b/app-text/OCRmyPDF/Manifest
@@ -0,0 +1,3 @@
+DIST OCRmyPDF-14.0.1.tar.gz 6503040 BLAKE2B b54f5b7960c9f5303f4c2d0f8d949a7c3a813674a28f2166d89aaaf6e5203d94f0dee368846578a0ac554e35ed3cf9f479b907973b06e3e663c98ea700888b19 SHA512 6872ba20cfd455b5421a25e45b6a06f7aaa821c59d4825822dac0898989917752c1018d4477bfa3a106b2b036ce6cf511a16990cca4226a490ad2a97f8eb5229
+EBUILD OCRmyPDF-14.0.1.ebuild 1938 BLAKE2B 528c61ba5183966cd6c1221d1f6ae2bcb2f4d9f1451ed1c005007f62075537ad6da1c24f367a7702028a28e2dbefd59122e3c6b9a2581580f72d138810d0a070 SHA512 daca3ba4280491cb0433cacae7ced8902e9074b428312359dbe0ca5665642594e726f7b40fb8a14a62f28baa4a6643a4648946a79bed17991f965ac41d5767e0
+MISC metadata.xml 402 BLAKE2B 449bc8a5ae10494ab0177e4220aa24018ca813be3e613f0098e84b57cc4d8ae29b8fec038f1cf221179adcc2e371ff9de0d22b5af9558e2505a7ac0561877180 SHA512 cd2a985178b2e0b80a5f5639e5844eb13d89e8d1f706e34e572ffc36ab1369405ef75cdaf0bd41ad627f1e83aee10b4f4f3dc7eefe42bd71ed4613c21c01371a
diff --git a/app-text/OCRmyPDF/OCRmyPDF-14.0.1.ebuild b/app-text/OCRmyPDF/OCRmyPDF-14.0.1.ebuild
new file mode 100644
index 0000000..3664bec
--- /dev/null
+++ b/app-text/OCRmyPDF/OCRmyPDF-14.0.1.ebuild
@@ -0,0 +1,67 @@
+# Copyright 2020-2022 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+DISTUTILS_USE_PEP517=setuptools
+PYTHON_COMPAT=( python3_{8..10} )
+
+inherit bash-completion-r1 distutils-r1 optfeature
+
+DESCRIPTION="OCRmyPDF adds an OCR text layer to scanned PDF files"
+HOMEPAGE="https://github.com/ocrmypdf/OCRmyPDF"
+SRC_URI="https://github.com/ocrmypdf/OCRmyPDF/archive/v${PV}.tar.gz -> ${P}.tar.gz"
+
+LICENSE="MPL-2.0"
+SLOT="0"
+KEYWORDS="~amd64"
+
+RDEPEND="
+ >=app-text/ghostscript-gpl-9.50
+ >=app-text/pdfminer-20201018[${PYTHON_USEDEP}]
+ >=app-text/tesseract-4.1.1[jpeg,tiff,png,webp]
+ >=dev-python/coloredlogs-14.0[${PYTHON_USEDEP}]
+ >=dev-python/deprecation-2.1.0[${PYTHON_USEDEP}]
+ >=dev-python/packaging-20[${PYTHON_USEDEP}]
+ >=dev-python/pikepdf-5.0.1[${PYTHON_USEDEP}]
+ >=dev-python/pillow-8.2.0[lcms,${PYTHON_USEDEP}]
+ >=dev-python/pluggy-0.13.0[${PYTHON_USEDEP}]
+ >=dev-python/reportlab-3.5.66[${PYTHON_USEDEP}]
+ >=dev-python/tqdm-4[${PYTHON_USEDEP}]
+ >=media-gfx/img2pdf-0.3.0[${PYTHON_USEDEP}]
+"
+BDEPEND="
+ >=dev-python/setuptools_scm-7.0.5[${PYTHON_USEDEP}]
+ test? (
+ >=app-text/unpaper-6.1
+ dev-python/pytest-helpers-namespace[${PYTHON_USEDEP}]
+ ~dev-python/python-xmp-toolkit-2.0.1[${PYTHON_USEDEP}]
+ >=media-libs/jbig2enc-0.29
+ >=media-gfx/pngquant-2.5
+ )
+"
+
+distutils_enable_tests pytest
+distutils_enable_sphinx docs \
+ dev-python/sphinx-issues \
+ dev-python/sphinx_rtd_theme
+
+export SETUPTOOLS_SCM_PRETEND_VERSION=${PV}
+
+src_prepare() {
+ distutils-r1_src_prepare
+ sed -e "/-n auto/d" -i pyproject.toml || die
+}
+
+src_install() {
+ distutils-r1_src_install
+ newbashcomp misc/completion/ocrmypdf.bash "${PN,,}"
+ insinto /usr/share/fish/vendor_completions.d
+ doins misc/completion/ocrmypdf.fish
+}
+
+pkg_postinst() {
+ optfeature "JBIG2 optimization support" media-libs/jbig2enc
+ optfeature "image cleaning support" app-text/unpaper
+ optfeature "PNG optimization support" media-gfx/pngquant
+}
diff --git a/app-text/OCRmyPDF/metadata.xml b/app-text/OCRmyPDF/metadata.xml
new file mode 100644
index 0000000..c3f1308
--- /dev/null
+++ b/app-text/OCRmyPDF/metadata.xml
@@ -0,0 +1,12 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+ <maintainer type="person">
+ <email>marcin.deranek@slonko.net</email>
+ <name>Marcin Deranek</name>
+ </maintainer>
+ <upstream>
+ <bugs-to>https://github.com/ocrmypdf/OCRmyPDF/issues</bugs-to>
+ <remote-id type="github">ocrmypdf/OCRmyPDF</remote-id>
+ </upstream>
+</pkgmetadata>