Gentoo Archives: gentoo-commits

From: "Robin H. Johnson" <robbat2@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: dev-python/pyxattr/
Date: Sat, 02 Nov 2019 04:45:19
Message-Id: 1572669906.e13f9e7ace62bfea1c548e6a1881e52ebc887609.robbat2@gentoo
1 commit: e13f9e7ace62bfea1c548e6a1881e52ebc887609
2 Author: Jeffrey Lin <jeffrey <AT> icurse <DOT> nl>
3 AuthorDate: Sun Oct 20 21:33:39 2019 +0000
4 Commit: Robin H. Johnson <robbat2 <AT> gentoo <DOT> org>
5 CommitDate: Sat Nov 2 04:45:06 2019 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=e13f9e7a
7
8 dev-python/pyxattr: add pypy3 to PYTHON_COMPAT
9
10 Package-Manager: Portage-2.3.77, Repoman-2.3.17
11 Signed-off-by: Jeffrey Lin <jeffrey <AT> icurse.nl>
12 (cherry picked from commit 61a15e5955cc63fcc94598977ebfa26780459ea1)
13 Signed-off-by: Robin H. Johnson <robbat2 <AT> gentoo.org>
14 Closes: https://github.com/gentoo/gentoo/pull/13363
15
16 dev-python/pyxattr/pyxattr-0.6.1-r1.ebuild | 66 ++++++++++++++++++++++++++++++
17 1 file changed, 66 insertions(+)
18
19 diff --git a/dev-python/pyxattr/pyxattr-0.6.1-r1.ebuild b/dev-python/pyxattr/pyxattr-0.6.1-r1.ebuild
20 new file mode 100644
21 index 00000000000..5ce00c43a28
22 --- /dev/null
23 +++ b/dev-python/pyxattr/pyxattr-0.6.1-r1.ebuild
24 @@ -0,0 +1,66 @@
25 +# Copyright 1999-2019 Gentoo Authors
26 +# Distributed under the terms of the GNU General Public License v2
27 +
28 +EAPI=7
29 +PYTHON_COMPAT=( python2_7 python3_{5,6,7} pypy{,3} )
30 +
31 +inherit distutils-r1 eutils
32 +
33 +DESCRIPTION="Python interface to xattr"
34 +HOMEPAGE="https://pyxattr.k1024.org/"
35 +SRC_URI="mirror://pypi/${PN:0:1}/${PN}/${P}.tar.gz
36 + https://pyxattr.k1024.org/downloads/${P}.tar.gz"
37 +
38 +LICENSE="LGPL-2.1"
39 +SLOT="0"
40 +KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~amd64-linux ~x86-linux"
41 +IUSE="doc test"
42 +RESTRICT="!test? ( test )"
43 +
44 +RDEPEND="sys-apps/attr"
45 +DEPEND="${RDEPEND}
46 + dev-python/setuptools[${PYTHON_USEDEP}]
47 + doc? ( >=dev-python/sphinx-1.3.1[${PYTHON_USEDEP}] )
48 + test? ( dev-python/nose[${PYTHON_USEDEP}] )"
49 +
50 +python_prepare_all() {
51 + sed -i -e 's:, "-Werror"::' setup.py || die
52 + # Bug 548486
53 + sed -e "s:html_theme = 'default':html_theme = 'classic':" \
54 + -i doc/conf.py || die
55 +
56 + distutils-r1_python_prepare_all
57 +}
58 +
59 +python_compile_all() {
60 + use doc && emake doc
61 +}
62 +
63 +src_test() {
64 + # Perform the tests in /var/tmp; that location is more likely
65 + # to have xattr support than /tmp which is often tmpfs.
66 + local -x TEST_DIR="${TEST_DIR:-/var/tmp}"
67 + # Ignore selinux attributes by default, bug #503946.
68 + local -x TEST_IGNORE_XATTRS="${TEST_IGNORE_XATTRS:-security.selinux}"
69 +
70 + einfo "Please note that the tests fail if xattrs are not supported"
71 + einfo "by the filesystem used for ${TEST_DIR}."
72 + einfo
73 + einfo "The location for tests can be overriden using TEST_DIR variable:"
74 + einfo " $ export TEST_DIR=/my/test/place"
75 + einfo
76 + einfo "Additionally, TEST_IGNORE_XATTRS can be set to control which"
77 + einfo "external attributes are ignored by the tests."
78 + einfo "See https://bugs.gentoo.org/503946 for details."
79 + einfo
80 + distutils-r1_src_test
81 +}
82 +
83 +python_test() {
84 + nosetests -v || die "Tests fail with ${EPYTHON}"
85 +}
86 +
87 +python_install_all() {
88 + use doc && local HTML_DOCS=( doc/html/. )
89 + distutils-r1_python_install_all
90 +}