1 |
commit: 3b9bd5829d31679d7a26483f6b11940c1cda78fe |
2 |
Author: Michał Górny <mgorny <AT> gentoo <DOT> org> |
3 |
AuthorDate: Wed May 18 07:10:28 2022 +0000 |
4 |
Commit: Michał Górny <mgorny <AT> gentoo <DOT> org> |
5 |
CommitDate: Wed May 18 07:36:09 2022 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=3b9bd582 |
7 |
|
8 |
app-misc/votrify: Modernize |
9 |
|
10 |
Signed-off-by: Michał Górny <mgorny <AT> gentoo.org> |
11 |
|
12 |
app-misc/votrify/votrify-5-r1.ebuild | 58 ++++++++++++++++++++++++++++++++++++ |
13 |
1 file changed, 58 insertions(+) |
14 |
|
15 |
diff --git a/app-misc/votrify/votrify-5-r1.ebuild b/app-misc/votrify/votrify-5-r1.ebuild |
16 |
new file mode 100644 |
17 |
index 000000000000..333d87cf357d |
18 |
--- /dev/null |
19 |
+++ b/app-misc/votrify/votrify-5-r1.ebuild |
20 |
@@ -0,0 +1,58 @@ |
21 |
+# Copyright 2019-2022 Gentoo Authors |
22 |
+# Distributed under the terms of the GNU General Public License v2 |
23 |
+ |
24 |
+EAPI=8 |
25 |
+ |
26 |
+PYTHON_COMPAT=( python3_{8..9} ) |
27 |
+ |
28 |
+inherit python-single-r1 |
29 |
+ |
30 |
+DESCRIPTION="Tool for community verification of Gentoo elections" |
31 |
+HOMEPAGE="https://github.com/mgorny/votrify/" |
32 |
+SRC_URI=" |
33 |
+ https://github.com/mgorny/votrify/archive/v${PV}.tar.gz |
34 |
+ -> ${P}.tar.gz |
35 |
+" |
36 |
+ |
37 |
+LICENSE="BSD-2" |
38 |
+SLOT="0" |
39 |
+KEYWORDS="~amd64 ~x86" |
40 |
+REQUIRED_USE=${PYTHON_REQUIRED_USE} |
41 |
+ |
42 |
+RDEPEND=" |
43 |
+ ${PYTHON_DEPS} |
44 |
+ app-misc/gentoo-elections |
45 |
+" |
46 |
+ |
47 |
+src_configure() { |
48 |
+ # update default location for election scripts |
49 |
+ sed -i -e "s^os.path.dirname(__file__)^'${EPREFIX}/usr/lib'^" \ |
50 |
+ votrify-make-confirmation || die |
51 |
+ |
52 |
+ python_fix_shebang votrify-{make,verify}-* |
53 |
+} |
54 |
+ |
55 |
+make_wrappers() { |
56 |
+ local election=${1} |
57 |
+ |
58 |
+ newbin - "votrify-${election}-make" \ |
59 |
+ < <(sed -e "s^@ELECTION@^${election}^" \ |
60 |
+ votrify-wrapper-make.bash.in || die) |
61 |
+ newbin - "votrify-${election}-verify" \ |
62 |
+ < <(sed -e "s^@ELECTION@^${election}^" \ |
63 |
+ votrify-wrapper-verify.bash.in || die) |
64 |
+} |
65 |
+ |
66 |
+src_install() { |
67 |
+ dobin votrify-{make,verify}-* |
68 |
+ make_wrappers council-201906 |
69 |
+ einstalldocs |
70 |
+} |
71 |
+ |
72 |
+pkg_postinst() { |
73 |
+ elog "In order to interactively create confirmation for Council 2019 election:" |
74 |
+ elog " votrify-council-201906-make" |
75 |
+ elog |
76 |
+ elog "In order to verify the results for Council 2019 election:" |
77 |
+ elog " votrify-council-201906-verify" |
78 |
+} |