diff options
author | Michał Górny <mgorny@gentoo.org> | 2023-01-19 06:26:27 +0100 |
---|---|---|
committer | Michał Górny <mgorny@gentoo.org> | 2023-01-19 07:08:20 +0100 |
commit | 85efafbf902a9a3e2fca78e8dac422ad132f34ac (patch) | |
tree | 7b3703f741b48927678a5ea6121f067182566388 /dev-python/jaraco-context/jaraco-context-4.2.1.ebuild | |
parent | dev-python/translate-toolkit: Bump to 3.8.3 (diff) | |
download | gentoo-85efafbf902a9a3e2fca78e8dac422ad132f34ac.tar.gz gentoo-85efafbf902a9a3e2fca78e8dac422ad132f34ac.tar.bz2 gentoo-85efafbf902a9a3e2fca78e8dac422ad132f34ac.zip |
dev-python/jaraco-context: Bump to 4.2.1
Signed-off-by: Michał Górny <mgorny@gentoo.org>
Diffstat (limited to 'dev-python/jaraco-context/jaraco-context-4.2.1.ebuild')
-rw-r--r-- | dev-python/jaraco-context/jaraco-context-4.2.1.ebuild | 48 |
1 files changed, 48 insertions, 0 deletions
diff --git a/dev-python/jaraco-context/jaraco-context-4.2.1.ebuild b/dev-python/jaraco-context/jaraco-context-4.2.1.ebuild new file mode 100644 index 000000000000..100882e1beea --- /dev/null +++ b/dev-python/jaraco-context/jaraco-context-4.2.1.ebuild @@ -0,0 +1,48 @@ +# Copyright 1999-2023 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +# please keep this ebuild at EAPI 7 -- sys-apps/portage dep +EAPI=7 + +DISTUTILS_USE_PEP517=flit +PYTHON_COMPAT=( python3_{9..11} pypy3 ) + +inherit distutils-r1 + +MY_P=${P/-/.} +DESCRIPTION="Context managers by jaraco" +HOMEPAGE=" + https://github.com/jaraco/jaraco.context/ + https://pypi.org/project/jaraco.context/ +" +SRC_URI="mirror://pypi/${PN:0:1}/${PN/-/.}/${MY_P}.tar.gz" +S="${WORKDIR}/${MY_P}" + +LICENSE="MIT" +SLOT="0" +KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~loong ~m68k ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86 ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris" + +distutils_enable_tests pytest + +src_configure() { + grep -q 'build-backend = "setuptools' pyproject.toml || + die "Upstream changed build-backend, recheck" + # write a custom pyproject.toml to ease setuptools bootstrap + cat > pyproject.toml <<-EOF || die + [build-system] + requires = ["flit_core >=3.2,<4"] + build-backend = "flit_core.buildapi" + + [project] + name = "jaraco.context" + version = "${PV}" + description = "Context managers by jaraco" + EOF +} + +python_install() { + distutils-r1_python_install + # rename to workaround a bug in pkg_resources + # https://bugs.gentoo.org/834522 + mv "${D}$(python_get_sitedir)"/jaraco{_,.}context-${PV}.dist-info || die +} |