Gentoo Archives: gentoo-commits

From: "Michał Górny" <mgorny@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: dev-python/pylibmc/
Date: Sat, 29 Jan 2022 21:19:30
Message-Id: 1643490903.1535a00b0a5e4c8813e1628f6b8c343cb09186ce.mgorny@gentoo
1 commit: 1535a00b0a5e4c8813e1628f6b8c343cb09186ce
2 Author: Michał Górny <mgorny <AT> gentoo <DOT> org>
3 AuthorDate: Sat Jan 29 21:15:03 2022 +0000
4 Commit: Michał Górny <mgorny <AT> gentoo <DOT> org>
5 CommitDate: Sat Jan 29 21:15:03 2022 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=1535a00b
7
8 dev-python/pylibmc: Switch to PEP 517 build
9
10 Signed-off-by: Michał Górny <mgorny <AT> gentoo.org>
11
12 dev-python/pylibmc/pylibmc-1.6.1-r2.ebuild | 57 ++++++++++++++++++++++++++++++
13 1 file changed, 57 insertions(+)
14
15 diff --git a/dev-python/pylibmc/pylibmc-1.6.1-r2.ebuild b/dev-python/pylibmc/pylibmc-1.6.1-r2.ebuild
16 new file mode 100644
17 index 000000000000..93cd31ed9d80
18 --- /dev/null
19 +++ b/dev-python/pylibmc/pylibmc-1.6.1-r2.ebuild
20 @@ -0,0 +1,57 @@
21 +# Copyright 1999-2022 Gentoo Authors
22 +# Distributed under the terms of the GNU General Public License v2
23 +
24 +EAPI=8
25 +
26 +DISTUTILS_USE_PEP517=setuptools
27 +PYTHON_COMPAT=( python3_{8..10} )
28 +
29 +inherit distutils-r1
30 +
31 +DESCRIPTION="Libmemcached wrapper written as a Python extension"
32 +HOMEPAGE="
33 + https://sendapatch.se/projects/pylibmc/
34 + https://pypi.org/project/pylibmc/
35 + https://github.com/lericson/pylibmc/"
36 +# One image is missing from the doc at PyPI
37 +# https://github.com/lericson/pylibmc/pull/221
38 +SRC_URI="https://github.com/lericson/${PN}/archive/${PV}.tar.gz -> ${P}.tar.gz"
39 +
40 +LICENSE="BSD"
41 +SLOT="0"
42 +KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~ia64 ~ppc ~ppc64 ~x86"
43 +
44 +RDEPEND=">=dev-libs/libmemcached-0.32"
45 +# Older sphinx versions fail to compile the doc
46 +# https://github.com/sphinx-doc/sphinx/issues/3266
47 +DEPEND="${RDEPEND}"
48 +BDEPEND="
49 + test? (
50 + net-misc/memcached
51 + )"
52 +
53 +PATCHES=(
54 + "${FILESDIR}/pylibmc-1.6.1-fix-test-failures-r1.patch"
55 +)
56 +
57 +distutils_enable_sphinx docs
58 +distutils_enable_tests nose
59 +
60 +python_prepare_all() {
61 + sed -e "/with-info=1/d" -i setup.cfg || die
62 +
63 + # some amazon thing, expects to be in AWS
64 + rm tests/test_autoconf.py || die
65 + distutils-r1_python_prepare_all
66 +
67 + # needed for docs
68 + export PYLIBMC_DIR=.
69 +}
70 +
71 +src_test() {
72 + local -x MEMCACHED_PORT=11219
73 + memcached -d -p "${MEMCACHED_PORT}" -u nobody -l localhost \
74 + -P "${T}/m.pid" || die
75 + distutils-r1_src_test
76 + kill "$(<"${T}/m.pid")" || die
77 +}