Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 11 Feb 2019 06:25:12 +0000 (UTC)
From:      Emanuel Haupt <ehaupt@FreeBSD.org>
To:        ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org
Subject:   svn commit: r492668 - in head/finance/electrum: . files
Message-ID:  <201902110625.x1B6PCCF042221@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: ehaupt
Date: Mon Feb 11 06:25:12 2019
New Revision: 492668
URL: https://svnweb.freebsd.org/changeset/ports/492668

Log:
  - Update to 3.3.3
  - Remove conflict to electrum2 as the legacy port has been removed a while ago
  - Provide an option to install without GUI
  - Merge the two hardware crypto wallet options into one. This is the way it is
    handled by setup.py.
  - Install security/py-pycryptodomex to make use of much faster crypto operations
  - Discontinue the now deprecated use of optsuffix USES flag in favour
    PKGNAMEPREFIX

Added:
  head/finance/electrum/files/hardware_wallet.conf.sample   (contents, props changed)
Deleted:
  head/finance/electrum/files/ledger_wallet.conf.sample
  head/finance/electrum/files/trezor_wallet.conf.sample
Modified:
  head/finance/electrum/Makefile
  head/finance/electrum/distinfo
  head/finance/electrum/files/pkg-message-hwwallet.in

Modified: head/finance/electrum/Makefile
==============================================================================
--- head/finance/electrum/Makefile	Mon Feb 11 05:07:40 2019	(r492667)
+++ head/finance/electrum/Makefile	Mon Feb 11 06:25:12 2019	(r492668)
@@ -2,11 +2,11 @@
 # $FreeBSD$
 
 PORTNAME=	electrum
-PORTVERSION=	3.3.2
-PORTREVISION=	1
+PORTVERSION=	3.3.3
 CATEGORIES=	finance python
 MASTER_SITES=	https://download.electrum.org/${PORTVERSION}/ \
 		http://download.electrum.org/${PORTVERSION}/
+PKGNAMEPREFIX=	${PYTHON_PKGNAMEPREFIX}
 DISTNAME=	Electrum-${PORTVERSION}
 
 MAINTAINER=	ehaupt@FreeBSD.org
@@ -15,9 +15,11 @@ COMMENT=	Easy to use Bitcoin client
 LICENSE=	MIT
 LICENSE_FILE=	${WRKSRC}/LICENCE
 
-RUN_DEPENDS=	${PYTHON_PKGNAMEPREFIX}aiohttp-socks>=0.2:net/py-aiohttp-socks@${PY_FLAVOR} \
+RUN_DEPENDS=	${PYTHON_PKGNAMEPREFIX}aiohttp-socks>0:net/py-aiohttp-socks@${PY_FLAVOR} \
 		${PYTHON_PKGNAMEPREFIX}aiohttp>0:www/py-aiohttp@${PY_FLAVOR} \
 		${PYTHON_PKGNAMEPREFIX}aiorpcX>0:devel/py-aiorpcX@${PY_FLAVOR} \
+		${PYTHON_PKGNAMEPREFIX}certifi>0:security/py-certifi@${PY_FLAVOR} \
+		${PYTHON_PKGNAMEPREFIX}ecdsa>=0.9:security/py-ecdsa@${PY_FLAVOR} \
 		${PYTHON_PKGNAMEPREFIX}dnspython>0:dns/py-dnspython@${PY_FLAVOR} \
 		${PYTHON_PKGNAMEPREFIX}httplib2>=0:www/py-httplib2@${PY_FLAVOR} \
 		${PYTHON_PKGNAMEPREFIX}jsonrpclib-pelix>0:devel/py-jsonrpclib-pelix@${PY_FLAVOR} \
@@ -25,41 +27,45 @@ RUN_DEPENDS=	${PYTHON_PKGNAMEPREFIX}aiohttp-socks>=0.2
 		${PYTHON_PKGNAMEPREFIX}protobuf>=2.6.0:devel/py-protobuf@${PY_FLAVOR} \
 		${PYTHON_PKGNAMEPREFIX}pyaes>0:security/py-pyaes@${PY_FLAVOR} \
 		${PYTHON_PKGNAMEPREFIX}pysocks>=0:net/py-pysocks@${PY_FLAVOR} \
+		${PYTHON_PKGNAMEPREFIX}QDarkStyle>2.6:textproc/py-QDarkStyle@${PY_FLAVOR} \
 		${PYTHON_PKGNAMEPREFIX}qrcode>=5.1:textproc/py-qrcode@${PY_FLAVOR} \
 		${PYTHON_PKGNAMEPREFIX}requests>=2.4.3:www/py-requests@${PY_FLAVOR} \
-		${PYTHON_PKGNAMEPREFIX}secp256k1>0:math/py-secp256k1@${PY_FLAVOR}
+		${PYTHON_PKGNAMEPREFIX}secp256k1>0:math/py-secp256k1@${PY_FLAVOR} \
+		${PYTHON_PKGNAMEPREFIX}pycryptodomex>0:security/py-pycryptodomex@${PY_FLAVOR}
 
-CONFLICTS_INSTALL=	electrum2-*
-
 # Supports 3.4+ but aiorpcX is 3.6+
-USES=		desktop-file-utils pyqt:5 python:3.6+
-USE_PYQT=	gui_run sip widgets
-USE_PYTHON=	autoplist distutils optsuffix
+USES=		python:3.6+
+USE_PYTHON=	autoplist concurrent distutils
+
 PYDISTUTILS_PKGNAME=	Electrum
 NO_ARCH=	yes
 OPTIONS_SUB=	yes
 
-OPTIONS_DEFINE=	LEDGER TREZOR
-OPTIONS_DEFAULT=LEDGER TREZOR
+OPTIONS_DEFINE=	GUI HARDWARE
+OPTIONS_DEFAULT=GUI HARDWARE
 
-LEDGER_DESC=	Enable LEDGER Bitcoin hardware wallet support
-TREZOR_DESC=	Enable TREZOR Bitcoin hardware wallet support
+GUI_USES=	desktop-file-utils pyqt:5
+GUI_USE=	PYQT=gui_run,sip,widgets
 
-LEDGER_RUN_DEPENDS=	${PYTHON_PKGNAMEPREFIX}btchip-python>0:security/py-btchip-python@${PY_FLAVOR}
-TREZOR_RUN_DEPENDS=	${PYTHON_PKGNAMEPREFIX}trezor>0:security/py-trezor@${PY_FLAVOR}
+HARDWARE_USE=	PYTHON=cython
+HARDWARE_DESC=	Enable Bitcoin hardware wallet support
 
-LEDGER_PLIST_FILES=	"@sample etc/devd/ledger_wallet.conf.sample"
-TREZOR_PLIST_FILES=	"@sample etc/devd/trezor_wallet.conf.sample"
+HARDWARE_RUN_DEPENDS=	${PYTHON_PKGNAMEPREFIX}btchip-python>=0.1.26:security/py-btchip-python@${PY_FLAVOR} \
+			${PYTHON_PKGNAMEPREFIX}trezor>=0.11.0:security/py-trezor@${PY_FLAVOR} \
+			${PYTHON_PKGNAMEPREFIX}hidapi>=0:comms/py-hidapi@${PY_FLAVOR} \
+			${PYTHON_PKGNAMEPREFIX}keepkey>0:security/py-keepkey@${PY_FLAVOR} \
+			${PYTHON_PKGNAMEPREFIX}websocket-client>0:www/py-websocket-client@${PY_FLAVOR} \
+			${PYTHON_PKGNAMEPREFIX}ckcc-protocol>=0.7.2:security/py-ckcc-protocol@${PY_FLAVOR}
 
-LEDGER_SUB_FILES=	pkg-message-hwwallet
-TREZOR_SUB_FILES=	pkg-message-hwwallet
+HARDWARE_PLIST_FILES=	"@sample etc/devd/hardware_wallet.conf.sample"
 
-post-install-LEDGER-on:
-	${INSTALL_DATA} ${FILESDIR}/ledger_wallet.conf.sample \
-		${STAGEDIR}${PREFIX}/etc/devd
+HARDWARE_SUB_FILES=	pkg-message-hwwallet
 
-post-install-TREZOR-on:
-	${INSTALL_DATA} ${FILESDIR}/trezor_wallet.conf.sample \
+post-patch-GUI-off:
+	@${REINPLACE_CMD} -e '/electrum\.desktop/d' ${WRKSRC}/setup.py
+
+post-install-HARDWARE-on:
+	${INSTALL_DATA} ${FILESDIR}/hardware_wallet.conf.sample \
 		${STAGEDIR}${PREFIX}/etc/devd
 
 .include <bsd.port.mk>

Modified: head/finance/electrum/distinfo
==============================================================================
--- head/finance/electrum/distinfo	Mon Feb 11 05:07:40 2019	(r492667)
+++ head/finance/electrum/distinfo	Mon Feb 11 06:25:12 2019	(r492668)
@@ -1,3 +1,3 @@
-TIMESTAMP = 1545693433
-SHA256 (Electrum-3.3.2.tar.gz) = 51b2a5dd3b0e924a9525dc1da801a87d113050ee109296496e86e6bc396cee6d
-SIZE (Electrum-3.3.2.tar.gz) = 8934781
+TIMESTAMP = 1548496758
+SHA256 (Electrum-3.3.3.tar.gz) = c2692f1e1a21907a2b3e47564f06954a73d20017ca081238d07f65ae3c745f7c
+SIZE (Electrum-3.3.3.tar.gz) = 9192110

Added: head/finance/electrum/files/hardware_wallet.conf.sample
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/finance/electrum/files/hardware_wallet.conf.sample	Mon Feb 11 06:25:12 2019	(r492668)
@@ -0,0 +1,23 @@
+# $FreeBSD$
+#
+# Allow members of group operator to access hardware wallet devices
+
+## Ledger Nano S
+#notify 301 {
+#        match "system"          "USB";
+#        match "subsystem"       "DEVICE";
+#        match "vendor"          "0x2c97";
+#        match "product"         "0x0001";
+#        match "type"            "ATTACH";
+#        action "/bin/chmod g=rw /dev/$cdev";
+#};
+
+## SatoshiLabs TREZOR
+#notify 301 {
+#        match "system"          "USB";
+#        match "subsystem"       "DEVICE";
+#        match "vendor"          "0x534c";
+#        match "product"         "0x0001";
+#        match "type"            "ATTACH";
+#        action "/bin/chmod g=rw /dev/$cdev";
+#};

Modified: head/finance/electrum/files/pkg-message-hwwallet.in
==============================================================================
--- head/finance/electrum/files/pkg-message-hwwallet.in	Mon Feb 11 05:07:40 2019	(r492667)
+++ head/finance/electrum/files/pkg-message-hwwallet.in	Mon Feb 11 06:25:12 2019	(r492668)
@@ -7,7 +7,7 @@ Add a user to operator group:
 
 Edit your configuration:
 
-%%PREFIX%%/etc/devd/*_wallet.conf
+%%PREFIX%%/etc/devd/hardware_wallet.conf
 
 Then restart devd to load the new rules:
 



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201902110625.x1B6PCCF042221>