From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from lists.gentoo.org (pigeon.gentoo.org [208.92.234.80]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits)) (No client certificate requested) by finch.gentoo.org (Postfix) with ESMTPS id 301DF158090 for ; Sat, 14 May 2022 08:26:01 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id 77FB1E0823; Sat, 14 May 2022 08:26:00 +0000 (UTC) Received: from smtp.gentoo.org (mail.gentoo.org [IPv6:2001:470:ea4a:1:5054:ff:fec7:86e4]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by pigeon.gentoo.org (Postfix) with ESMTPS id 5DF0DE0823 for ; Sat, 14 May 2022 08:26:00 +0000 (UTC) Received: from oystercatcher.gentoo.org (unknown [IPv6:2a01:4f8:202:4333:225:90ff:fed9:fc84]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits)) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTPS id 83D7C34150A for ; Sat, 14 May 2022 08:25:59 +0000 (UTC) Received: from localhost.localdomain (localhost [IPv6:::1]) by oystercatcher.gentoo.org (Postfix) with ESMTP id 3AB74466 for ; Sat, 14 May 2022 08:25:58 +0000 (UTC) From: "Michał Górny" To: gentoo-commits@lists.gentoo.org Content-Transfer-Encoding: 8bit Content-type: text/plain; charset=UTF-8 Reply-To: gentoo-dev@lists.gentoo.org, "Michał Górny" Message-ID: <1652516749.feb9b140b322bca4fd2e5d20e94ca34f4925c765.mgorny@gentoo> Subject: [gentoo-commits] repo/gentoo:master commit in: dev-python/docutils/ X-VCS-Repository: repo/gentoo X-VCS-Files: dev-python/docutils/docutils-0.17.1-r1.ebuild dev-python/docutils/docutils-0.18.1-r1.ebuild X-VCS-Directories: dev-python/docutils/ X-VCS-Committer: mgorny X-VCS-Committer-Name: Michał Górny X-VCS-Revision: feb9b140b322bca4fd2e5d20e94ca34f4925c765 X-VCS-Branch: master Date: Sat, 14 May 2022 08:25:58 +0000 (UTC) Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-commits@lists.gentoo.org X-Auto-Response-Suppress: DR, RN, NRN, OOF, AutoReply X-Archives-Salt: 51936559-1fa0-4553-8a3b-fe1fa98f73cd X-Archives-Hash: a701417e48ccc28bc25b7cf93269a7a7 commit: feb9b140b322bca4fd2e5d20e94ca34f4925c765 Author: Michał Górny gentoo org> AuthorDate: Sat May 14 07:35:43 2022 +0000 Commit: Michał Górny gentoo org> CommitDate: Sat May 14 08:25:49 2022 +0000 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=feb9b140 dev-python/docutils: Use PEP517 build Signed-off-by: Michał Górny gentoo.org> dev-python/docutils/docutils-0.17.1-r1.ebuild | 73 +++++++++++++++++++++++++++ dev-python/docutils/docutils-0.18.1-r1.ebuild | 73 +++++++++++++++++++++++++++ 2 files changed, 146 insertions(+) diff --git a/dev-python/docutils/docutils-0.17.1-r1.ebuild b/dev-python/docutils/docutils-0.17.1-r1.ebuild new file mode 100644 index 000000000000..5d0b53a49995 --- /dev/null +++ b/dev-python/docutils/docutils-0.17.1-r1.ebuild @@ -0,0 +1,73 @@ +# Copyright 1999-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} pypy3 ) + +inherit distutils-r1 + +DESCRIPTION="Python Documentation Utilities (reference reStructuredText impl.)" +HOMEPAGE=" + https://docutils.sourceforge.io/ + https://pypi.org/project/docutils/ +" +SRC_URI="mirror://pypi/${PN:0:1}/${PN}/${P}.tar.gz" + +LICENSE="BSD-2 GPL-3 public-domain" +SLOT="0" +KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~loong ~m68k ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86 ~x64-cygwin ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris" + +RDEPEND=" + dev-python/pygments[${PYTHON_USEDEP}] +" +BDEPEND=" + ${RDEPEND} +" + +python_compile_all() { + # Generate html docs from reStructured text sources. + + # Place html4css1.css in base directory to ensure that the generated reference to it is correct. + cp docutils/writers/html4css1/html4css1.css . || die + + cd tools || die + "${EPYTHON}" buildhtml.py --input-encoding=utf-8 \ + --stylesheet-path=../html4css1.css, --traceback ../docs || die +} + +src_test() { + cd test || die + distutils-r1_src_test +} + +python_test() { + "${EPYTHON}" alltests.py -v || die "Testing failed with ${EPYTHON}" +} + +python_install() { + distutils-r1_python_install + + # Install tools. + python_doscript tools/{buildhtml,quicktest}.py +} + +install_txt_doc() { + local doc="${1}" + local dir="txt/$(dirname ${doc})" + docinto "${dir}" + dodoc "${doc}" +} + +python_install_all() { + local DOCS=( *.txt ) + local HTML_DOCS=( docs tools docutils/writers/html4css1/html4css1.css ) + + distutils-r1_python_install_all + + local doc + while IFS= read -r -d '' doc; do + install_txt_doc "${doc}" + done < <(find docs tools -name '*.txt' -print0) +} diff --git a/dev-python/docutils/docutils-0.18.1-r1.ebuild b/dev-python/docutils/docutils-0.18.1-r1.ebuild new file mode 100644 index 000000000000..5d0b53a49995 --- /dev/null +++ b/dev-python/docutils/docutils-0.18.1-r1.ebuild @@ -0,0 +1,73 @@ +# Copyright 1999-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} pypy3 ) + +inherit distutils-r1 + +DESCRIPTION="Python Documentation Utilities (reference reStructuredText impl.)" +HOMEPAGE=" + https://docutils.sourceforge.io/ + https://pypi.org/project/docutils/ +" +SRC_URI="mirror://pypi/${PN:0:1}/${PN}/${P}.tar.gz" + +LICENSE="BSD-2 GPL-3 public-domain" +SLOT="0" +KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~loong ~m68k ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86 ~x64-cygwin ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris" + +RDEPEND=" + dev-python/pygments[${PYTHON_USEDEP}] +" +BDEPEND=" + ${RDEPEND} +" + +python_compile_all() { + # Generate html docs from reStructured text sources. + + # Place html4css1.css in base directory to ensure that the generated reference to it is correct. + cp docutils/writers/html4css1/html4css1.css . || die + + cd tools || die + "${EPYTHON}" buildhtml.py --input-encoding=utf-8 \ + --stylesheet-path=../html4css1.css, --traceback ../docs || die +} + +src_test() { + cd test || die + distutils-r1_src_test +} + +python_test() { + "${EPYTHON}" alltests.py -v || die "Testing failed with ${EPYTHON}" +} + +python_install() { + distutils-r1_python_install + + # Install tools. + python_doscript tools/{buildhtml,quicktest}.py +} + +install_txt_doc() { + local doc="${1}" + local dir="txt/$(dirname ${doc})" + docinto "${dir}" + dodoc "${doc}" +} + +python_install_all() { + local DOCS=( *.txt ) + local HTML_DOCS=( docs tools docutils/writers/html4css1/html4css1.css ) + + distutils-r1_python_install_all + + local doc + while IFS= read -r -d '' doc; do + install_txt_doc "${doc}" + done < <(find docs tools -name '*.txt' -print0) +}