1 |
commit: e5873eeb500bdf7e4f87e105574b42608948719a |
2 |
Author: Michał Górny <mgorny <AT> gentoo <DOT> org> |
3 |
AuthorDate: Sun Jan 30 09:55:25 2022 +0000 |
4 |
Commit: Michał Górny <mgorny <AT> gentoo <DOT> org> |
5 |
CommitDate: Sun Jan 30 10:04:22 2022 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=e5873eeb |
7 |
|
8 |
dev-python/python-systemd: Switch to PEP 517 build |
9 |
|
10 |
Signed-off-by: Michał Górny <mgorny <AT> gentoo.org> |
11 |
|
12 |
.../python-systemd/python-systemd-234-r2.ebuild | 44 ++++++++++++++++++++++ |
13 |
1 file changed, 44 insertions(+) |
14 |
|
15 |
diff --git a/dev-python/python-systemd/python-systemd-234-r2.ebuild b/dev-python/python-systemd/python-systemd-234-r2.ebuild |
16 |
new file mode 100644 |
17 |
index 000000000000..60d75ffb0ea8 |
18 |
--- /dev/null |
19 |
+++ b/dev-python/python-systemd/python-systemd-234-r2.ebuild |
20 |
@@ -0,0 +1,44 @@ |
21 |
+# Copyright 2015-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="Python module for native access to the systemd facilities" |
32 |
+HOMEPAGE="https://github.com/systemd/python-systemd" |
33 |
+SRC_URI="https://github.com/systemd/python-systemd/archive/v${PV}.tar.gz -> ${P}.tar.gz" |
34 |
+ |
35 |
+LICENSE="LGPL-2.1" |
36 |
+SLOT="0" |
37 |
+KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ppc ~ppc64 ~sparc ~x86" |
38 |
+ |
39 |
+DEPEND="sys-apps/systemd:0=" |
40 |
+RDEPEND="${DEPEND} |
41 |
+ !sys-apps/systemd[python(-)] |
42 |
+" |
43 |
+ |
44 |
+PATCHES=( |
45 |
+ "${FILESDIR}"/${P}-fix-py3.10.patch |
46 |
+) |
47 |
+ |
48 |
+distutils_enable_tests pytest |
49 |
+ |
50 |
+python_compile() { |
51 |
+ # https://bugs.gentoo.org/690316 |
52 |
+ distutils-r1_python_compile -j1 |
53 |
+} |
54 |
+ |
55 |
+src_test() { |
56 |
+ # prevent relative import |
57 |
+ rm -r systemd || die |
58 |
+ distutils-r1_src_test |
59 |
+} |
60 |
+ |
61 |
+python_test() { |
62 |
+ unset NOTIFY_SOCKET |
63 |
+ epytest --pyargs systemd -o cache_dir="${T}" |
64 |
+} |