Patch the setup script to use PREFIX/include and PREFIX/lib.

This should fix a build failure, where it failed to
find the installed version of zmq.  (It worked for me because
I had /usr/pkg/lib in /etc/ld.so.conf.)

Bump PKGREVISION to 1.
This commit is contained in:
apb 2012-03-02 18:44:44 +00:00
parent 06878032ba
commit d1076b3a4d
3 changed files with 21 additions and 2 deletions

View file

@ -1,7 +1,8 @@
# $NetBSD: Makefile,v 1.1 2012/01/21 20:17:27 apb Exp $
# $NetBSD: Makefile,v 1.2 2012/03/02 18:44:44 apb Exp $
#
DISTNAME= pyzmq-2.1.10
PKGREVISION= 1
PKGNAME= ${PYPKGPREFIX}-${DISTNAME:S/py//}
CATEGORIES= net
MASTER_SITES= https://github.com/zeromq/pyzmq/downloads/

View file

@ -1,5 +1,6 @@
$NetBSD: distinfo,v 1.1 2012/01/21 20:17:27 apb Exp $
$NetBSD: distinfo,v 1.2 2012/03/02 18:44:45 apb Exp $
SHA1 (pyzmq-2.1.10.tar.gz) = d583056f5b735899b4a6fe6844dfa40c2ebd35c9
RMD160 (pyzmq-2.1.10.tar.gz) = 11f358534da9e3d13b4a7bb203a0ac6fb6f6310c
Size (pyzmq-2.1.10.tar.gz) = 613843 bytes
SHA1 (patch-setup.py) = d3c9527a27bce998cd4eb65f5bd00a09b82ec97e

View file

@ -0,0 +1,17 @@
$NetBSD: patch-setup.py,v 1.1 2012/03/02 18:44:45 apb Exp $
Use PREFIX/include and PREFIX/lib for pkgsrc build.
--- setup.py.orig 2011-10-12 22:38:44.000000000 +0000
+++ setup.py
@@ -126,6 +126,10 @@ else:
if ZMQ is not None:
COMPILER_SETTINGS['include_dirs'] += [pjoin(ZMQ, 'include')]
COMPILER_SETTINGS['library_dirs'] += [pjoin(ZMQ, 'lib')]
+ elif os.environ['PREFIX']:
+ PREFIX = os.environ['PREFIX']
+ COMPILER_SETTINGS['include_dirs'] += [pjoin(PREFIX, 'include')]
+ COMPILER_SETTINGS['library_dirs'] += [pjoin(PREFIX, 'lib')]
elif sys.platform == 'darwin' and os.path.isdir('/opt/local/lib'):
# allow macports default
COMPILER_SETTINGS['include_dirs'] += ['/opt/local/include']