aboutsummaryrefslogtreecommitdiffstats
path: root/archivers/py-liblzma
diff options
context:
space:
mode:
authorwen <wen@FreeBSD.org>2011-06-08 16:26:45 +0800
committerwen <wen@FreeBSD.org>2011-06-08 16:26:45 +0800
commitf6181bd7e9e10f799838dfd49cfc68471044124a (patch)
treef4bd730f3c859ee7d5dbe96c47a9876fb07eea4b /archivers/py-liblzma
parentf64399f7eb2bc01cdf4b38b0e50c91057e71aac9 (diff)
downloadfreebsd-ports-gnome-f6181bd7e9e10f799838dfd49cfc68471044124a.tar.gz
freebsd-ports-gnome-f6181bd7e9e10f799838dfd49cfc68471044124a.tar.zst
freebsd-ports-gnome-f6181bd7e9e10f799838dfd49cfc68471044124a.zip
- Fix build with python-2.7
PR: ports/157300 Submitted by: David Naylor <naylor.b.david@gmail.com> (maintainer)
Diffstat (limited to 'archivers/py-liblzma')
-rw-r--r--archivers/py-liblzma/Makefile2
-rw-r--r--archivers/py-liblzma/files/patch-setup.py11
2 files changed, 11 insertions, 2 deletions
diff --git a/archivers/py-liblzma/Makefile b/archivers/py-liblzma/Makefile
index 84906e3728c7..6e486c373ed8 100644
--- a/archivers/py-liblzma/Makefile
+++ b/archivers/py-liblzma/Makefile
@@ -6,7 +6,7 @@
PORTNAME= liblzma
PORTVERSION= 0.5.3
-PORTREVISION= 1
+PORTREVISION= 2
CATEGORIES= archivers python
MASTER_SITES= ${MASTER_SITE_CHEESESHOP}source/p/pyliblzma/
PKGNAMEPREFIX= ${PYTHON_PKGNAMEPREFIX}
diff --git a/archivers/py-liblzma/files/patch-setup.py b/archivers/py-liblzma/files/patch-setup.py
index c1aaeaa42194..7ba8425aa010 100644
--- a/archivers/py-liblzma/files/patch-setup.py
+++ b/archivers/py-liblzma/files/patch-setup.py
@@ -9,7 +9,16 @@
descr = "Python bindings for liblzma"
long_descr = """PylibLZMA provides a python interface for the liblzma library
-@@ -74,7 +74,6 @@
+@@ -54,6 +54,8 @@
+ pc_libs = subprocess.Popen("pkg-config --libs liblzma", shell=True, stdout=subprocess.PIPE, close_fds=True).stdout.readline().strip()
+ if(pc_libs):
+ link_args.extend(pc_libs.split(' '))
++link_args.append('-L%s/lib' % os.environ["LOCALBASE"])
++link_args.append('-lpython%i.%i' % sys.version_info[:2])
+
+ extens=[Extension('lzma', c_files, extra_compile_args=compile_args, extra_link_args=link_args, define_macros=version_define)]
+
+@@ -74,7 +76,6 @@
],
py_modules = modules,
ext_modules = extens,