summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'dev-python/pyx')
-rw-r--r--dev-python/pyx/Manifest1
-rw-r--r--dev-python/pyx/pyx-0.16.ebuild68
2 files changed, 69 insertions, 0 deletions
diff --git a/dev-python/pyx/Manifest b/dev-python/pyx/Manifest
index 8bd5de6708f1..aa4d5cb50dcc 100644
--- a/dev-python/pyx/Manifest
+++ b/dev-python/pyx/Manifest
@@ -1,2 +1,3 @@
DIST W3C_SVG_11_TestSuite.tar.gz 14651624 BLAKE2B 680059d8b20775725cebb3aed4444acbc3222fde880ba93ee5186c99fc12afa8df2c790bdacbcd6e5ff4ab00e697d8317a9a6ae3039b8b2f02cf7774a18ca533 SHA512 e28e3996284c3f3e423e2b6957cddea71980bcb781d4180894e08f37a7ecce9c6021917329d6d433dcba792cbabb15c7cd503076e616ba5189193a5c554374ca
DIST pyx-0.15_p1.tar.bz2 746171 BLAKE2B 5b2325c7bb279e4f6425f0ba7f3808b7e540c7455738c617efdf1ad9d383a466d1b67b90e20e0bdbfa7d2fc56f1c80a4ae2badc5ef78f63ec410370d516f4ab3 SHA512 97809a38029011735d2cdea8f7e8326890d748d4159f44379f89c396b7ea4d2a026ca3370bb069974b07215da91a47b9334d8dd1f7db954c2dd272122bde8ff0
+DIST pyx-0.16.gh.tar.gz 626703 BLAKE2B fa1f1a54e958fa4c1c3efd1df4cf744a1d591ac17671a6da4b2d2f15ae5f2a6cb6260bd1c5f189c60b0683e4f54545f5d3c0ed0c7698f14fa390396c18bf4ebd SHA512 613212a7a7d983432aab574bdccd402132da2b1ae563cb672e2766dbcda3ce91977780ab5e4097de77e6499d36537b54089327e448cf4e7855889087c3b9a9f8
diff --git a/dev-python/pyx/pyx-0.16.ebuild b/dev-python/pyx/pyx-0.16.ebuild
new file mode 100644
index 000000000000..3f9d45e61825
--- /dev/null
+++ b/dev-python/pyx/pyx-0.16.ebuild
@@ -0,0 +1,68 @@
+# Copyright 1999-2023 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+DISTUTILS_USE_PEP517=setuptools
+#DISTUTILS_USE_SETUPTOOLS=no
+PYTHON_COMPAT=( python3_{9..11} )
+
+inherit distutils-r1
+
+DESCRIPTION="Python package for the generation of encapsulated PostScript figures"
+MY_PN="PyX"
+MY_P=${MY_PN}-${PV}
+HOMEPAGE="
+ https://github.com/pyx-project/pyx
+ https://pyx-project.org/
+ https://pypi.org/project/PyX/"
+SRC_URI="https://github.com/pyx-project/${PN}/releases/download/${PV}/${MY_P}.tar.gz -> ${P}.gh.tar.gz"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="~amd64 ~x86"
+IUSE="doc"
+
+RDEPEND="
+ dev-python/pillow[${PYTHON_USEDEP}]
+ virtual/tex-base
+ virtual/latex-base
+ dev-texlive/texlive-basic"
+
+BDEPEND="${RDEPEND}
+ doc? (
+ $(python_gen_any_dep '
+ dev-python/sphinx[latex,${PYTHON_USEDEP}]
+ dev-python/sphinx_selective_exclude[${PYTHON_USEDEP}]
+ ')
+ )"
+
+PATCHES=( "${FILESDIR}"/pyx-0.14.1-unicode-latex.patch )
+S="${WORKDIR}"/${MY_P}
+
+python_check_deps() {
+ use doc || return 0
+ python_has_version "dev-python/sphinx[latex,${PYTHON_USEDEP}]" \
+ "dev-python/sphinx_selective_exclude[${PYTHON_USEDEP}]"
+}
+
+src_prepare() {
+ sed -i \
+ -e 's/^build_t1code=.*/build_t1code=1/' \
+ -e 's/^build_pykpathsea=.*/build_pykpathsea=1/' \
+ setup.cfg || die "setup.cfg fix failed"
+ distutils-r1_src_prepare
+}
+
+python_compile_all() {
+ if use doc; then
+ local -x VARTEXFONTS="${T}"/fonts
+ emake -C "${S}"/manual latexpdf
+ emake -C "${S}"/faq latexpdf
+ fi
+}
+
+python_install_all() {
+ use doc && dodoc manual/_build/latex/manual.pdf faq/_build/latex/pyxfaq.pdf
+ distutils-r1_python_install_all
+}