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: net-misc/electrum/
Date: Sat, 28 May 2022 05:00:25
Message-Id: 1653714015.6378f9ea2767792799024ec4390aa9daea0cb2d8.mgorny@gentoo
1 commit: 6378f9ea2767792799024ec4390aa9daea0cb2d8
2 Author: Michał Górny <mgorny <AT> gentoo <DOT> org>
3 AuthorDate: Sat May 28 04:49:18 2022 +0000
4 Commit: Michał Górny <mgorny <AT> gentoo <DOT> org>
5 CommitDate: Sat May 28 05:00:15 2022 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=6378f9ea
7
8 net-misc/electrum: Bump to 4.2.2
9
10 Signed-off-by: Michał Górny <mgorny <AT> gentoo.org>
11
12 net-misc/electrum/Manifest | 1 +
13 net-misc/electrum/electrum-4.2.2.ebuild | 99 +++++++++++++++++++++++++++++++++
14 2 files changed, 100 insertions(+)
15
16 diff --git a/net-misc/electrum/Manifest b/net-misc/electrum/Manifest
17 index 305abd47b912..656adb310ef9 100644
18 --- a/net-misc/electrum/Manifest
19 +++ b/net-misc/electrum/Manifest
20 @@ -1 +1,2 @@
21 DIST electrum-4.2.1.gh.tar.gz 5066728 BLAKE2B 66b1ef4ec21f74f2f5c25de97a31c2ec23f907526df2ac661fdcb563e1e857ca88f4f534f2373e809ba978c66b78af72260af27944ac7aa8a92e86531827fef6 SHA512 b32ee5f8779bdb9bcda6a163f3f0a4cd95e91efb37418734c9f08930221ad15e54868fca0d5d0fb1dd3b1fac91b8cdea6c6ec822d98ad6b3d6ee01c841972e88
22 +DIST electrum-4.2.2.gh.tar.gz 5071636 BLAKE2B a13ae03e513736e5f24ded46a9b6ce13312a7d9243082f1d5b1948e7519f40f1fab238ec73550f72607ff2463a54a31f47c6ab8e511efddfcec362d5e427c6c1 SHA512 ae39ca0b548f3e4c7454096a7a05f9400a738e3b1c217ae9d41bf6156f7d642d3f1911f97829bfadbf6fdb6873538f38525363d256b363dac41d378c6b41002d
23
24 diff --git a/net-misc/electrum/electrum-4.2.2.ebuild b/net-misc/electrum/electrum-4.2.2.ebuild
25 new file mode 100644
26 index 000000000000..24459edb0784
27 --- /dev/null
28 +++ b/net-misc/electrum/electrum-4.2.2.ebuild
29 @@ -0,0 +1,99 @@
30 +# Copyright 1999-2022 Gentoo Authors
31 +# Distributed under the terms of the GNU General Public License v2
32 +
33 +EAPI=8
34 +
35 +DISTUTILS_USE_PEP517=setuptools
36 +PYTHON_COMPAT=( python3_{8..10} )
37 +PYTHON_REQ_USE="ncurses?"
38 +
39 +inherit desktop distutils-r1 xdg-utils
40 +
41 +DESCRIPTION="User friendly Bitcoin client"
42 +HOMEPAGE="https://electrum.org/"
43 +SRC_URI="
44 + https://github.com/spesmilo/electrum/archive/${PV}.tar.gz
45 + -> ${P}.gh.tar.gz
46 +"
47 +
48 +LICENSE="MIT"
49 +SLOT="0"
50 +KEYWORDS="~amd64 ~x86"
51 +IUSE="cli ncurses qrcode +qt5"
52 +REQUIRED_USE="|| ( cli ncurses qt5 )"
53 +
54 +RDEPEND="
55 + ${PYTHON_DEPS}
56 + dev-libs/libsecp256k1
57 + >=dev-python/aiohttp-socks-0.3[${PYTHON_USEDEP}]
58 + =dev-python/aiorpcX-0.22*[${PYTHON_USEDEP}]
59 + >=dev-python/attrs-19.2.0[${PYTHON_USEDEP}]
60 + dev-python/bitstring[${PYTHON_USEDEP}]
61 + dev-python/cryptography[${PYTHON_USEDEP}]
62 + >=dev-python/dnspython-2[${PYTHON_USEDEP}]
63 + dev-python/pbkdf2[${PYTHON_USEDEP}]
64 + dev-python/PySocks[${PYTHON_USEDEP}]
65 + dev-python/qrcode[${PYTHON_USEDEP}]
66 + dev-python/requests[${PYTHON_USEDEP}]
67 + dev-python/setuptools[${PYTHON_USEDEP}]
68 + dev-python/six[${PYTHON_USEDEP}]
69 + >=dev-python/protobuf-python-3.12[${PYTHON_USEDEP}]
70 + qrcode? ( media-gfx/zbar[v4l] )
71 + qt5? (
72 + dev-python/PyQt5[gui,widgets,${PYTHON_USEDEP}]
73 + )
74 + ncurses? ( $(python_gen_impl_dep 'ncurses') )
75 +"
76 +BDEPEND="
77 + test? (
78 + dev-python/pyaes[${PYTHON_USEDEP}]
79 + dev-python/pycryptodome[${PYTHON_USEDEP}]
80 + )
81 +"
82 +
83 +distutils_enable_tests pytest
84 +
85 +src_prepare() {
86 + eapply "${FILESDIR}/3.1.2-no-user-root.patch"
87 +
88 + # Prevent data files from being installed in the wrong location
89 + sed -i -e '/icons_dirname/d' -e '/applications/d' setup.py || die
90 +
91 + # use backwards-compatible cryptodome API
92 + sed -i -e 's:Cryptodome:Crypto:' electrum/crypto.py || die
93 +
94 + # make qdarkstyle dep optional
95 + sed -i -e '/qdarkstyle/d' contrib/requirements/requirements.txt || die
96 +
97 + local bestgui
98 + if use qt5; then
99 + bestgui=qt
100 + elif use ncurses; then
101 + bestgui=text
102 + else
103 + bestgui=stdio
104 + fi
105 + sed -i 's/^\([[:space:]]*\)\(config_options\['\''cwd'\''\] = .*\)$/\1\2\n\1config_options.setdefault("gui", "'"${bestgui}"'")\n/' ${PN}/${PN} || die
106 +
107 + eapply_user
108 +
109 + xdg_environment_reset
110 + distutils-r1_src_prepare
111 +}
112 +
113 +src_install() {
114 + doicon -s 128 electrum/gui/icons/${PN}.png
115 + domenu electrum.desktop
116 + dodoc RELEASE-NOTES
117 + distutils-r1_src_install
118 +}
119 +
120 +pkg_postinst() {
121 + xdg_icon_cache_update
122 + xdg_desktop_database_update
123 +}
124 +
125 +pkg_postrm() {
126 + xdg_icon_cache_update
127 + xdg_desktop_database_update
128 +}