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/pycdio/
Date: Sat, 31 Dec 2022 15:54:57
Message-Id: 1672502091.3f64e11797d30cd54100ffeca585b09b549c328f.mgorny@gentoo
1 commit: 3f64e11797d30cd54100ffeca585b09b549c328f
2 Author: Michał Górny <mgorny <AT> gentoo <DOT> org>
3 AuthorDate: Sat Dec 31 15:49:58 2022 +0000
4 Commit: Michał Górny <mgorny <AT> gentoo <DOT> org>
5 CommitDate: Sat Dec 31 15:54:51 2022 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=3f64e117
7
8 dev-python/pycdio: PEP517, pytest
9
10 Closes: https://bugs.gentoo.org/888255
11 Signed-off-by: Michał Górny <mgorny <AT> gentoo.org>
12
13 dev-python/pycdio/pycdio-2.1.1-r1.ebuild | 55 ++++++++++++++++++++++++++++++++
14 1 file changed, 55 insertions(+)
15
16 diff --git a/dev-python/pycdio/pycdio-2.1.1-r1.ebuild b/dev-python/pycdio/pycdio-2.1.1-r1.ebuild
17 new file mode 100644
18 index 000000000000..94f8d9a685c4
19 --- /dev/null
20 +++ b/dev-python/pycdio/pycdio-2.1.1-r1.ebuild
21 @@ -0,0 +1,55 @@
22 +# Copyright 1999-2022 Gentoo Authors
23 +# Distributed under the terms of the GNU General Public License v2
24 +
25 +EAPI=8
26 +
27 +DISTUTILS_USE_PEP517=setuptools
28 +PYTHON_COMPAT=( python3_{8..11} )
29 +
30 +inherit distutils-r1
31 +
32 +DESCRIPTION="Python OO interface to libcdio (CD Input and Control library)"
33 +HOMEPAGE="
34 + https://savannah.gnu.org/projects/libcdio/
35 + https://pypi.org/project/pycdio/
36 +"
37 +SRC_URI="mirror://pypi/${PN:0:1}/${PN}/${P}.tar.gz"
38 +
39 +LICENSE="GPL-3+"
40 +SLOT="0"
41 +KEYWORDS="~amd64 ~x86"
42 +IUSE="examples"
43 +
44 +DEPEND="
45 + >=dev-libs/libcdio-2.0.0
46 +"
47 +RDEPEND="
48 + ${DEPEND}
49 +"
50 +BDEPEND="
51 + dev-lang/swig
52 +"
53 +
54 +distutils_enable_tests pytest
55 +
56 +python_prepare_all() {
57 + # Remove obsolete sys.path and adjust 'data' paths in examples.
58 + sed -i \
59 + -e "s:^sys.path.insert.*::" \
60 + -e "s:\.\./data:./data:g" \
61 + example/*.py || die
62 + distutils-r1_python_prepare_all
63 +}
64 +
65 +python_test() {
66 + epytest -opython_files='test-*.py'
67 +}
68 +
69 +python_install_all() {
70 + distutils-r1_python_install_all
71 + if use examples; then
72 + docinto examples
73 + dodoc -r example/.
74 + docompress -x /usr/share/doc/${PF}/examples
75 + fi
76 +}