diff options
author | Zac Medico <zmedico@gentoo.org> | 2019-04-24 13:14:39 -0700 |
---|---|---|
committer | Zac Medico <zmedico@gentoo.org> | 2019-04-24 20:54:34 -0700 |
commit | 489c63f236db243320a634914e16bbe0bdf6f054 (patch) | |
tree | 81cb8bb74a1062a9984fd970374e5487249edf4f /net-misc/electrum-ltc | |
parent | dev-perl/JSON: arm64 stable (diff) | |
download | gentoo-489c63f236db243320a634914e16bbe0bdf6f054.tar.gz gentoo-489c63f236db243320a634914e16bbe0bdf6f054.tar.bz2 gentoo-489c63f236db243320a634914e16bbe0bdf6f054.zip |
net-misc/electrum-ltc: version bump to 3.3.4.1
Bug: https://bugs.gentoo.org/684218
Package-Manager: Portage-2.3.64, Repoman-2.3.12
Signed-off-by: Zac Medico <zmedico@gentoo.org>
Diffstat (limited to 'net-misc/electrum-ltc')
-rw-r--r-- | net-misc/electrum-ltc/Manifest | 1 | ||||
-rw-r--r-- | net-misc/electrum-ltc/electrum-ltc-3.3.4.1.ebuild | 155 | ||||
-rw-r--r-- | net-misc/electrum-ltc/files/3.1.2-no-user-root.patch | 17 | ||||
-rw-r--r-- | net-misc/electrum-ltc/files/3.2.3-pip-optional-pkgs.patch | 11 | ||||
-rw-r--r-- | net-misc/electrum-ltc/files/3.3.2-desktop.patch | 20 |
5 files changed, 204 insertions, 0 deletions
diff --git a/net-misc/electrum-ltc/Manifest b/net-misc/electrum-ltc/Manifest index ffd70ec6776d..a0319fa5806a 100644 --- a/net-misc/electrum-ltc/Manifest +++ b/net-misc/electrum-ltc/Manifest @@ -1 +1,2 @@ DIST electrum-ltc-3.0.6.2.tar.gz 2387515 BLAKE2B 3093aad114dd96d0a0ecac48adfe45c9b7be37d831f67fd8a230617bb45131b5045e70433c0ed0fe87a3028356de3884e78c3eb2c1bda38e5804e97952dcd13f SHA512 c9de8f490eddbf269fb5a034fc4bf5712173a09df8fe4ea01dafe516cd1b684dce253278c4c4128e4284c89bd7f8fbd51e0633710abbb22720b53507ecbd102c +DIST electrum-ltc-3.3.4.1.tar.gz 3897254 BLAKE2B 113e4175adad0d404f9677913bd24cbda569f20183de75d341d60b954f0423ff13042e0b05f66f7953729368412fc181d2c8da7caee15899f6810cb77c4be241 SHA512 cab85edbe9189fffd2a4b8d57dd89dc55f68cf3f02cd4a7427c53de852ab2001b82b1484126699c8eee36d765a8ca58936eba82e3c153f654bf5629b9cd50745 diff --git a/net-misc/electrum-ltc/electrum-ltc-3.3.4.1.ebuild b/net-misc/electrum-ltc/electrum-ltc-3.3.4.1.ebuild new file mode 100644 index 000000000000..1e6465700a4a --- /dev/null +++ b/net-misc/electrum-ltc/electrum-ltc-3.3.4.1.ebuild @@ -0,0 +1,155 @@ +# Copyright 1999-2019 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI="6" + +PYTHON_COMPAT=( python3_6 ) +PYTHON_REQ_USE="ncurses?" + +inherit desktop distutils-r1 gnome2-utils xdg-utils + +EGIT_COMMIT="${PV}" +DESCRIPTION="Litecoin thin client" +HOMEPAGE="https://electrum-ltc.org/" +SRC_URI="https://github.com/pooler/electrum-ltc/archive/${EGIT_COMMIT}.tar.gz -> ${P}.tar.gz" + +LICENSE="MIT" +SLOT="0" +KEYWORDS="~amd64 ~x86" + +IUSE="audio_modem cli cosign digitalbitbox email ncurses qrcode +qt5 sync vkb + l10n_es l10n_ja l10n_pt-BR l10n_pt-PT l10n_zh-CN" + +REQUIRED_USE=" + || ( cli ncurses qt5 ) + audio_modem? ( qt5 ) + cosign? ( qt5 ) + digitalbitbox? ( qt5 ) + email? ( qt5 ) + qrcode? ( qt5 ) + sync? ( qt5 ) + vkb? ( qt5 ) +" + +RDEPEND="${PYTHON_DEPS} + dev-python/aiohttp-socks[${PYTHON_USEDEP}] + dev-python/aiorpcX[${PYTHON_USEDEP}] + dev-python/ecdsa[${PYTHON_USEDEP}] + dev-python/jsonrpclib[${PYTHON_USEDEP}] + dev-python/pbkdf2[${PYTHON_USEDEP}] + dev-python/pyaes[${PYTHON_USEDEP}] + dev-python/PySocks[${PYTHON_USEDEP}] + dev-python/qrcode[${PYTHON_USEDEP}] + dev-python/requests[${PYTHON_USEDEP}] + dev-python/setuptools[${PYTHON_USEDEP}] + dev-python/six[${PYTHON_USEDEP}] + dev-python/tlslite[${PYTHON_USEDEP}] + dev-python/protobuf-python[${PYTHON_USEDEP}] + virtual/python-dnspython[${PYTHON_USEDEP}] + qrcode? ( media-gfx/zbar[v4l] ) + qt5? ( + dev-python/PyQt5[gui,widgets,${PYTHON_USEDEP}] + ) + ncurses? ( dev-lang/python ) +" + +S="${WORKDIR}/${PN}-${EGIT_COMMIT}" + +DOCS="RELEASE-NOTES" + +src_prepare() { + eapply "${FILESDIR}/3.1.2-no-user-root.patch" + eapply "${FILESDIR}/3.2.3-pip-optional-pkgs.patch" + eapply "${FILESDIR}/3.3.2-desktop.patch" + + # Prevent icon from being installed in the wrong location + sed -i '/icons_dirname/d' setup.py || die + + if ! use qt5; then + sed "/'electrum_ltc.gui.qt',/d" -i setup.py || die + fi + + local wordlist= + for wordlist in \ + $(usex l10n_ja '' japanese) \ + $(usex l10n_pt-BR '' $(usex l10n_pt-PT '' portuguese)) \ + $(usex l10n_es '' spanish) \ + $(usex l10n_zh-CN '' chinese_simplified) \ + ; do + rm -f "${PN}/wordlist/${wordlist}.txt" || die + sed -i "/${wordlist}\\.txt/d" ${PN/-/_}/mnemonic.py || die + done + + # Remove unrequested GUI implementations: + local gui setup_py_gui + for gui in \ + $(usex cli '' stdio) \ + kivy \ + $(usex qt5 '' qt ) \ + $(usex ncurses '' text ) \ + ; do + rm ${PN/-/_}/gui/"${gui}"* -r || die + done + + # And install requested ones... + for gui in \ + $(usex qt5 qt '') \ + ; do + setup_py_gui="${setup_py_gui}'electrum_gui.${gui}'," + done + + sed -i "s/'electrum_gui\\.qt',/${setup_py_gui}/" setup.py || die + + local bestgui + if use qt5; then + bestgui=qt + elif use ncurses; then + bestgui=text + else + bestgui=stdio + fi + sed -i 's/^\([[:space:]]*\)\(config_options\['\''cwd'\''\] = .*\)$/\1\2\n\1config_options.setdefault("gui", "'"${bestgui}"'")\n/' ${PN/-/_}/${PN} || die + + local plugin + # trezor requires python trezorlib module + # keepkey requires trezor + for plugin in \ + $(usex audio_modem '' audio_modem ) \ + $(usex cosign '' cosigner_pool ) \ + $(usex digitalbitbox '' digitalbitbox ) \ + $(usex email '' email_requests ) \ + hw_wallet \ + ledger \ + keepkey \ + $(usex sync '' labels ) \ + trezor \ + $(usex vkb '' virtualkeyboard ) \ + ; do + rm -r ${PN/-/_}/plugins/"${plugin}"* || die + sed -i "/${plugin}/d" setup.py || die + done + + eapply_user + + xdg_environment_reset + distutils-r1_src_prepare +} + +src_install() { + doicon -s 128 ${PN/-/_}/gui/icons/${PN}.png + distutils-r1_src_install +} + +pkg_preinst() { + gnome2_icon_savelist +} + +pkg_postinst() { + gnome2_icon_cache_update + xdg_desktop_database_update +} + +pkg_postrm() { + gnome2_icon_cache_update + xdg_desktop_database_update +} diff --git a/net-misc/electrum-ltc/files/3.1.2-no-user-root.patch b/net-misc/electrum-ltc/files/3.1.2-no-user-root.patch new file mode 100644 index 000000000000..0d4781717714 --- /dev/null +++ b/net-misc/electrum-ltc/files/3.1.2-no-user-root.patch @@ -0,0 +1,17 @@ +diff -Naur Electrum-3.1.2.orig/setup.py Electrum-3.1.2/setup.py +--- Electrum-3.1.2.orig/setup.py 2018-03-28 04:51:11.000000000 -0400 ++++ Electrum-3.1.2/setup.py 2018-03-31 15:05:45.540757981 -0400 +@@ -28,13 +28,6 @@ + opts, _ = parser.parse_known_args(sys.argv[1:]) + usr_share = os.path.join(sys.prefix, "share") + icons_dirname = 'pixmaps' +- if not os.access(opts.root_path + usr_share, os.W_OK) and \ +- not os.access(opts.root_path, os.W_OK): +- icons_dirname = 'icons' +- if 'XDG_DATA_HOME' in os.environ.keys(): +- usr_share = os.environ['XDG_DATA_HOME'] +- else: +- usr_share = os.path.expanduser('~/.local/share') + data_files += [ + (os.path.join(usr_share, 'applications/'), ['electrum.desktop']), + (os.path.join(usr_share, icons_dirname), ['icons/electrum.png']) diff --git a/net-misc/electrum-ltc/files/3.2.3-pip-optional-pkgs.patch b/net-misc/electrum-ltc/files/3.2.3-pip-optional-pkgs.patch new file mode 100644 index 000000000000..6d62f5675764 --- /dev/null +++ b/net-misc/electrum-ltc/files/3.2.3-pip-optional-pkgs.patch @@ -0,0 +1,11 @@ +diff -Naur a/setup.py b/setup.py +--- a/setup.py 2018-09-17 12:56:34.000000000 +0100 ++++ b/setup.py 2018-10-14 14:46:16.524385198 +0100 +@@ -72,7 +72,6 @@ + name="Electrum", + version=version.ELECTRUM_VERSION, + install_requires=requirements, +- extras_require=extras_require, + packages=[ + 'electrum', + 'electrum.gui', diff --git a/net-misc/electrum-ltc/files/3.3.2-desktop.patch b/net-misc/electrum-ltc/files/3.3.2-desktop.patch new file mode 100644 index 000000000000..c75f282182e7 --- /dev/null +++ b/net-misc/electrum-ltc/files/3.3.2-desktop.patch @@ -0,0 +1,20 @@ +--- a/electrum-ltc.desktop ++++ b/electrum-ltc.desktop +@@ -3,7 +3,7 @@ + + [Desktop Entry] + Comment=Lightweight Litecoin Client +-Exec=sh -c "PATH=\"\\$HOME/.local/bin:\\$PATH\"; electrum-ltc %u" ++Exec=electrum-ltc %u + GenericName[en_US]=Litecoin Wallet + GenericName=Litecoin Wallet + Icon=electrum-ltc +@@ -15,8 +15,3 @@ + Terminal=false + Type=Application + MimeType=x-scheme-handler/litecoin; +-Actions=Testnet; +- +-[Desktop Action Testnet] +-Exec=sh -c "PATH=\"\\$HOME/.local/bin:\\$PATH\"; electrum-ltc --testnet %u" +-Name=Testnet mode |