summaryrefslogtreecommitdiff
path: root/net/py-ifaddr
diff options
context:
space:
mode:
authormef <mef@pkgsrc.org>2020-06-20 02:08:55 +0000
committermef <mef@pkgsrc.org>2020-06-20 02:08:55 +0000
commit71e5069e81132e0de102afc190a266d0841071eb (patch)
treef8c220eb6c7cb315b0f93ff0b73c5ed233a2833c /net/py-ifaddr
parent16c5542fb19af922c3a32adda295bea1a4bde647 (diff)
downloadpkgsrc-71e5069e81132e0de102afc190a266d0841071eb.tar.gz
(net/py-ifaddr) fix build for py3, Explicitly read file as UTF-8, tks joerg@
Diffstat (limited to 'net/py-ifaddr')
-rw-r--r--net/py-ifaddr/distinfo3
-rw-r--r--net/py-ifaddr/patches/patch-setup.py19
2 files changed, 21 insertions, 1 deletions
diff --git a/net/py-ifaddr/distinfo b/net/py-ifaddr/distinfo
index cddf5da718d..e8b7cab74f5 100644
--- a/net/py-ifaddr/distinfo
+++ b/net/py-ifaddr/distinfo
@@ -1,6 +1,7 @@
-$NetBSD: distinfo,v 1.2 2020/06/10 10:18:17 adam Exp $
+$NetBSD: distinfo,v 1.3 2020/06/20 02:08:55 mef Exp $
SHA1 (ifaddr-0.1.7.tar.gz) = a74dd735a96427020774df550b997d1ad034743d
RMD160 (ifaddr-0.1.7.tar.gz) = b524efab1ae747efdba26a5a98bd8b84fa4e055d
SHA512 (ifaddr-0.1.7.tar.gz) = 9a428dd6bb022c8f483b77df9e9301f96e9ba64207eda8b3956a7ca5993bfe97f222c451149851135d379db1a819c75d0834566f3b6501456b2f237b0645e300
Size (ifaddr-0.1.7.tar.gz) = 9281 bytes
+SHA1 (patch-setup.py) = c96e7d5b7c4d31107d163f2868f2712d206eceb1
diff --git a/net/py-ifaddr/patches/patch-setup.py b/net/py-ifaddr/patches/patch-setup.py
new file mode 100644
index 00000000000..043b9e5f3ed
--- /dev/null
+++ b/net/py-ifaddr/patches/patch-setup.py
@@ -0,0 +1,19 @@
+$NetBSD: patch-setup.py,v 1.1 2020/06/20 02:08:56 mef Exp $
+
+Explicitly read file as UTF-8, thanks joerg@
+
+--- setup.py.orig 2020-06-06 18:56:10.000000000 +0000
++++ setup.py
+@@ -19,10 +19,11 @@
+ # IN THE SOFTWARE.
+
+ import os.path
++import sys
+ from setuptools import setup, find_packages
+
+ if os.path.exists('README.rst'):
+- with open('README.rst') as f:
++ with open('README.rst', **({'encoding': 'UTF-8'} if sys.version_info.major>=3 else {})) as f:
+ long_description = f.read()
+ else:
+ long_description = ""