aboutsummaryrefslogtreecommitdiffstats
path: root/archivers
diff options
context:
space:
mode:
authorjkim <jkim@FreeBSD.org>2015-09-05 01:24:08 +0800
committerjkim <jkim@FreeBSD.org>2015-09-05 01:24:08 +0800
commitcb1bd26c93b7f4f76f869a67a7611e3f8df556b1 (patch)
tree85e7469f3bdedf9df16e16df4f8573ab1723524a /archivers
parentfd1c125ee7f6a9048a878d7744e0eb757aef71bd (diff)
downloadfreebsd-ports-gnome-cb1bd26c93b7f4f76f869a67a7611e3f8df556b1.tar.gz
freebsd-ports-gnome-cb1bd26c93b7f4f76f869a67a7611e3f8df556b1.tar.zst
freebsd-ports-gnome-cb1bd26c93b7f4f76f869a67a7611e3f8df556b1.zip
- Add an upstream patch for archivers/py-lz4 to export its version number.
- Remove a local hack for x11/xpra to properly detect LZ4 version.
Diffstat (limited to 'archivers')
-rw-r--r--archivers/py-lz4/Makefile1
-rw-r--r--archivers/py-lz4/files/patch-setup.py19
-rw-r--r--archivers/py-lz4/files/patch-src_python-lz4.c13
3 files changed, 32 insertions, 1 deletions
diff --git a/archivers/py-lz4/Makefile b/archivers/py-lz4/Makefile
index a4da14af80fd..4ccf4f99fe95 100644
--- a/archivers/py-lz4/Makefile
+++ b/archivers/py-lz4/Makefile
@@ -2,6 +2,7 @@
PORTNAME= lz4
PORTVERSION= 0.7.0
+PORTREVISION= 1
CATEGORIES= archivers python
MASTER_SITES= CHEESESHOP
PKGNAMEPREFIX= ${PYTHON_PKGNAMEPREFIX}
diff --git a/archivers/py-lz4/files/patch-setup.py b/archivers/py-lz4/files/patch-setup.py
index 08278d35ed1e..57c736a5e2a6 100644
--- a/archivers/py-lz4/files/patch-setup.py
+++ b/archivers/py-lz4/files/patch-setup.py
@@ -1,6 +1,23 @@
--- setup.py.orig 2014-07-07 13:03:03 UTC
+++ setup.py
-@@ -29,7 +29,7 @@ setup(
+@@ -4,10 +4,11 @@
+ from setuptools import setup, find_packages, Extension
+
+ VERSION = (0, 7, 0)
++VERSION_STR = ".".join([str(x) for x in VERSION])
+
+ setup(
+ name='lz4',
+- version=".".join([str(x) for x in VERSION]),
++ version=VERSION_STR,
+ description="LZ4 Bindings for Python",
+ long_description=open('README.rst', 'r').read(),
+ author='Steeve Morin',
+@@ -26,10 +27,11 @@ setup(
+ "-Wall",
+ "-W",
+ "-Wundef",
++ "-DVERSION=\"%s\"" % VERSION_STR,
"-DLZ4_VERSION=\"r119\"",
])
],
diff --git a/archivers/py-lz4/files/patch-src_python-lz4.c b/archivers/py-lz4/files/patch-src_python-lz4.c
new file mode 100644
index 000000000000..942f087e3227
--- /dev/null
+++ b/archivers/py-lz4/files/patch-src_python-lz4.c
@@ -0,0 +1,13 @@
+--- src/python-lz4.c.orig 2014-07-07 13:03:03 UTC
++++ src/python-lz4.c
+@@ -202,6 +202,10 @@ void initlz4(void)
+ INITERROR;
+ }
+
++ PyModule_AddStringConstant(module, "VERSION", VERSION);
++ PyModule_AddStringConstant(module, "__version__", VERSION);
++ PyModule_AddStringConstant(module, "LZ4_VERSION", LZ4_VERSION);
++
+ #if PY_MAJOR_VERSION >= 3
+ return module;
+ #endif