From 8227eaa7218ea5bc784ef5b38cf82e0bc6afe636 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20G=C3=B3rny?= Date: Sun, 18 Nov 2018 20:36:05 +0100 Subject: [PATCH] dev-python/filelock: New package, dep of dev-python/tox MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Michał Górny --- dev-python/filelock/filelock-3.0.10.ebuild | 34 ++++++++++++++++++++++ dev-python/filelock/metadata.xml | 11 +++++++ 2 files changed, 45 insertions(+) create mode 100644 dev-python/filelock/filelock-3.0.10.ebuild create mode 100644 dev-python/filelock/metadata.xml diff --git a/dev-python/filelock/filelock-3.0.10.ebuild b/dev-python/filelock/filelock-3.0.10.ebuild new file mode 100644 index 0000000000000..04e239ae7c4e2 --- /dev/null +++ b/dev-python/filelock/filelock-3.0.10.ebuild @@ -0,0 +1,34 @@ +# Copyright 2018 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=7 + +PYTHON_COMPAT=( python2_7 python3_{4,5,6,7} pypy{,3} ) +inherit distutils-r1 + +MY_P=py-filelock-${PV} +DESCRIPTION="A platform independent file lock for Python" +HOMEPAGE="https://github.com/benediktschmitt/py-filelock + https://pypi.org/project/filelock/" +SRC_URI="https://github.com/benediktschmitt/py-filelock/archive/v${PV}.tar.gz -> ${MY_P}.tar.gz" + +LICENSE="Unlicense" +SLOT="0" +KEYWORDS="~amd64 ~x86" +IUSE="" + +DEPEND="dev-python/setuptools[${PYTHON_USEDEP}]" + +S=${WORKDIR}/${MY_P} + +src_prepare() { + # test_del is relying on CPython behavior, so it breaks PyPy + # (and it's not very valuable anyway) + sed -i -e '/test_del/i\ \ \ \ @unittest.skipIf(hasattr(sys, "pypy_version_info"), "del() does not trigger GC on PyPy")' test.py || die + + distutils-r1_src_prepare +} + +python_test() { + "${EPYTHON}" test.py -v || die "Tests fail with ${EPYTHON}" +} diff --git a/dev-python/filelock/metadata.xml b/dev-python/filelock/metadata.xml new file mode 100644 index 0000000000000..8684444c6acec --- /dev/null +++ b/dev-python/filelock/metadata.xml @@ -0,0 +1,11 @@ + + + + + python@gentoo.org + + + filelock + benediktschmitt/py-filelock + +