aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorwg <wg@FreeBSD.org>2015-06-24 00:32:16 +0800
committerwg <wg@FreeBSD.org>2015-06-24 00:32:16 +0800
commit4a703fad72431c4d80727ed6e8588e11f7c300b1 (patch)
treea829192bc43a544f698768eb9d0a9543d854399d
parentd448cb3bb88bddf8859d9d66af9b12923d2e796d (diff)
downloadfreebsd-ports-graphics-4a703fad72431c4d80727ed6e8588e11f7c300b1.tar.gz
freebsd-ports-graphics-4a703fad72431c4d80727ed6e8588e11f7c300b1.tar.zst
freebsd-ports-graphics-4a703fad72431c4d80727ed6e8588e11f7c300b1.zip
devel/py-cffi: update to 1.1.1
PR: 200699 Submitted by: dbn
-rw-r--r--devel/py-cffi/Makefile3
-rw-r--r--devel/py-cffi/distinfo4
-rw-r--r--devel/py-cffi/files/patch-cffi_verifier.py68
3 files changed, 3 insertions, 72 deletions
diff --git a/devel/py-cffi/Makefile b/devel/py-cffi/Makefile
index 565eeb1692b..de7271d7f51 100644
--- a/devel/py-cffi/Makefile
+++ b/devel/py-cffi/Makefile
@@ -2,8 +2,7 @@
# $FreeBSD$
PORTNAME= cffi
-PORTVERSION= 0.8.6
-PORTREVISION= 3
+PORTVERSION= 1.1.1
CATEGORIES= devel python
MASTER_SITES= CHEESESHOP
PKGNAMEPREFIX= ${PYTHON_PKGNAMEPREFIX}
diff --git a/devel/py-cffi/distinfo b/devel/py-cffi/distinfo
index 3b34c930077..4d59a679014 100644
--- a/devel/py-cffi/distinfo
+++ b/devel/py-cffi/distinfo
@@ -1,2 +1,2 @@
-SHA256 (cffi-0.8.6.tar.gz) = 2532d9e3af9e3c6d0f710fc98b0295b563c7f39cfd97dd2242bd36fbf4900610
-SIZE (cffi-0.8.6.tar.gz) = 196835
+SHA256 (cffi-1.1.1.tar.gz) = 81fbaf121a67a0c4d390cc0ce7a69661f987f5cf34997575131e8a1bbe1ee1c6
+SIZE (cffi-1.1.1.tar.gz) = 326663
diff --git a/devel/py-cffi/files/patch-cffi_verifier.py b/devel/py-cffi/files/patch-cffi_verifier.py
deleted file mode 100644
index c11fc7f00eb..00000000000
--- a/devel/py-cffi/files/patch-cffi_verifier.py
+++ /dev/null
@@ -1,68 +0,0 @@
-# Backport: PR #56: Actually check if the file exists rather than assume it doesn't
-# https://bitbucket.org/cffi/cffi/pull-request/56/
-
---- cffi/verifier.py.orig 2015-02-11 08:57:05 UTC
-+++ cffi/verifier.py
-@@ -1,7 +1,16 @@
--import sys, os, binascii, imp, shutil
-+import sys, os, binascii, imp, shutil, io
- from . import __version__
- from . import ffiplatform
-
-+if sys.version_info >= (3,):
-+ NativeIO = io.StringIO
-+else:
-+ class NativeIO(io.BytesIO):
-+ def write(self, s):
-+ if isinstance(s, unicode):
-+ s = s.encode('ascii')
-+ super(NativeIO, self).write(s)
-+
-
- class Verifier(object):
-
-@@ -118,19 +127,36 @@ class Verifier(object):
- self._vengine.collect_types()
- self._has_module = True
-
-- def _write_source(self, file=None):
-- must_close = (file is None)
-- if must_close:
-- _ensure_dir(self.sourcefilename)
-- file = open(self.sourcefilename, 'w')
-+ def _write_source_to(self, file):
- self._vengine._f = file
- try:
- self._vengine.write_source_to_f()
- finally:
- del self._vengine._f
-- if must_close:
-- file.close()
-- if must_close:
-+
-+ def _write_source(self, file=None):
-+ if file is not None:
-+ self._write_source_to(file)
-+ else:
-+ # Write our source file to an in memory file.
-+ f = NativeIO()
-+ self._write_source_to(f)
-+ source_data = f.getvalue()
-+
-+ # Determine if this matches the current file
-+ if os.path.exists(self.sourcefilename):
-+ with open(self.sourcefilename, "r") as fp:
-+ needs_written = not (fp.read() == source_data)
-+ else:
-+ needs_written = True
-+
-+ # Actually write the file out if it doesn't match
-+ if needs_written:
-+ _ensure_dir(self.sourcefilename)
-+ with open(self.sourcefilename, "w") as fp:
-+ fp.write(source_data)
-+
-+ # Set this flag
- self._has_source = True
-
- def _compile_module(self):