Subject: pkg/33478: [PATCH] databases/py-ldap: Update to 2.2.0
To: None <pkg-manager@netbsd.org, gnats-admin@netbsd.org,>
From: None <ykomatsu@akaumigame.org>
List: pkgsrc-bugs
Date: 05/14/2006 02:40:01
>Number:         33478
>Category:       pkg
>Synopsis:       [PATCH] databases/py-ldap: Update to 2.2.0
>Confidential:   no
>Severity:       non-critical
>Priority:       medium
>Responsible:    pkg-manager
>State:          open
>Class:          change-request
>Submitter-Id:   net
>Arrival-Date:   Sun May 14 02:40:00 +0000 2006
>Originator:     Yoshito Komatsu
>Release:        NetBSD 3.99.19
>Organization:
>Environment:
System: NetBSD c10.ln.akaumigame.org 3.99.19 NetBSD 3.99.19 (XENU) #0: Wed May 10 01:50:55 JST 2006 root@c8.ln.akaumigame.org:/usr/obj/sys/arch/i386/compile/XENU i386
Architecture: i386
Machine: i386
>Description:
	python-ldap 2.2.0 has been released.
>How-To-Repeat:
>Fix:
	I have made a patch for databases/py-ldap.

	diff -uNr databases/py-ldap.orig/Makefile databases/py-ldap/Makefile
	--- databases/py-ldap.orig/Makefile	2006-05-14 00:53:05.000000000 +0900
	+++ databases/py-ldap/Makefile	2006-05-14 10:16:49.000000000 +0900
	@@ -1,8 +1,7 @@
	 # $NetBSD: Makefile,v 1.28 2006/04/13 21:45:13 wiz Exp $
	 
	-DISTNAME=	python-ldap-2.0.10
	+DISTNAME=	python-ldap-2.2.0
	 PKGNAME=	${DISTNAME:S/python/${PYPKGPREFIX}/}
	-PKGREVISION=	2
	 CATEGORIES=	databases python
	 MASTER_SITES=	${MASTER_SITE_SOURCEFORGE:=python-ldap/}
	 
	@@ -10,21 +9,31 @@
	 HOMEPAGE=	http://sourceforge.net/projects/python-ldap/
	 COMMENT=	LDAP client API for Python
	 
	-PYTHON_VERSIONS_ACCEPTED=	21 22 23 24
	+PYTHON_VERSIONS_ACCEPTED=	23 24
	 PYDISTUTILSPKG=			yes
	 
	+PY_LDAP_LIBRARY_DIRS=		${BUILDLINK_PREFIX.openldap}/lib
	+PY_LDAP_INCLUDE_DIRS=		${BUILDLINK_PREFIX.openldap}/include
	+PY_LDAP_LIBS=			ldap_r lber ssl crypto
	+
	+.include "options.mk"
	+
	 SUBST_CLASSES+=			setup
	 SUBST_STAGE.setup=		pre-configure
	 SUBST_FILES.setup=		setup.cfg
	-SUBST_SED.setup=		-e "s|@EXTRALIBS@|${BUILDLINK_PREFIX.cyrus-sasl}/lib ${BUILDLINK_PREFIX.openldap}/lib|" 	\
	-				-e "s|@EXTRAINCS@|${BUILDLINK_PREFIX.cyrus-sasl}/include/sasl ${BUILDLINK_PREFIX.openldap}/include|"
	+SUBST_SED.setup=		-e "s|@PY_LDAP_LIBRARY_DIRS@|${PY_LDAP_LIBRARY_DIRS}|"
	+SUBST_SED.setup+=		-e "s|@PY_LDAP_INCLUDE_DIRS@|${PY_LDAP_INCLUDE_DIRS}|"
	+SUBST_SED.setup+=		-e "s|@PY_LDAP_LIBS@|${PY_LDAP_LIBS}|"
	+
	+PY_LDAP_DOCDIR=			${PREFIX}/share/doc/py-ldap
	+
	+post-install:
	+	${INSTALL_DATA_DIR} ${PY_LDAP_DOCDIR}
	+	cd ${WRKSRC} && ${PAX} -rw CHANGES README INSTALL TODO Demo \
	+		${PY_LDAP_DOCDIR}
	 
	 .include "../../databases/openldap/buildlink3.mk"
	-.include "../../security/cyrus-sasl/buildlink3.mk"
	+.include "../../security/openssl/buildlink3.mk"
	 .include "../../lang/python/extension.mk"
	 
	-.if defined(PTHREAD_TYPE) && ${PTHREAD_TYPE} == ""
	-SUBST_SED.setup+=		-e "s|crypto|& read|"
	-.endif
	-
	 .include "../../mk/bsd.pkg.mk"
	diff -uNr databases/py-ldap.orig/PLIST databases/py-ldap/PLIST
	--- databases/py-ldap.orig/PLIST	2006-05-14 00:53:05.000000000 +0900
	+++ databases/py-ldap/PLIST	2006-05-14 10:24:03.000000000 +0900
	@@ -1,4 +1,4 @@
	-@comment $NetBSD: PLIST,v 1.2 2005/08/04 11:17:04 drochner Exp $
	+@comment $NetBSD$
	 ${PYSITELIB}/_ldap.so
	 ${PYSITELIB}/dsml.py
	 ${PYSITELIB}/dsml.pyc
	@@ -51,5 +51,30 @@
	 ${PYSITELIB}/ldif.py
	 ${PYSITELIB}/ldif.pyc
	 ${PYSITELIB}/ldif.pyo
	+share/doc/py-ldap/CHANGES
	+share/doc/py-ldap/Demo/Lib/ldapurl/urlsearch.py
	+share/doc/py-ldap/Demo/Lib/ldif/ldifcopy.py
	+share/doc/py-ldap/Demo/initialize.py
	+share/doc/py-ldap/Demo/ldapcontrols.py
	+share/doc/py-ldap/Demo/options.py
	+share/doc/py-ldap/Demo/passwd_ext_op.py
	+share/doc/py-ldap/Demo/pickle_ldapobject.py
	+share/doc/py-ldap/Demo/reconnect.py
	+share/doc/py-ldap/Demo/rename.py
	+share/doc/py-ldap/Demo/sasl_bind.py
	+share/doc/py-ldap/Demo/schema.py
	+share/doc/py-ldap/Demo/schema_tree.py
	+share/doc/py-ldap/Demo/simple.py
	+share/doc/py-ldap/Demo/simplebrowse.py
	+share/doc/py-ldap/INSTALL
	+share/doc/py-ldap/README
	+share/doc/py-ldap/TODO
	+@dirrm share/doc/py-ldap/Demo/Lib/ldif
	+@dirrm share/doc/py-ldap/Demo/Lib/ldapurl
	+@dirrm share/doc/py-ldap/Demo/Lib/ldap/res
	+@dirrm share/doc/py-ldap/Demo/Lib/ldap
	+@dirrm share/doc/py-ldap/Demo/Lib
	+@dirrm share/doc/py-ldap/Demo
	+@dirrm share/doc/py-ldap/
	 @dirrm ${PYSITELIB}/ldap/schema
	 @dirrm ${PYSITELIB}/ldap
	diff -uNr databases/py-ldap.orig/buildlink3.mk databases/py-ldap/buildlink3.mk
	--- databases/py-ldap.orig/buildlink3.mk	2006-05-14 00:53:05.000000000 +0900
	+++ databases/py-ldap/buildlink3.mk	2006-05-14 01:05:26.000000000 +0900
	@@ -1,6 +1,6 @@
	 # $NetBSD: buildlink3.mk,v 1.5 2006/04/12 10:27:05 rillig Exp $
	 
	-BUILDLINK_DEPTH:=		${BUILDLINK_DEPTH}+
	+BUILDLINK_DEPTH:=	${BUILDLINK_DEPTH}+
	 PY_LDAP_BUILDLINK3_MK:=	${PY_LDAP_BUILDLINK3_MK}+
	 
	 .include "../../lang/python/pyversion.mk"
	@@ -13,8 +13,8 @@
	 BUILDLINK_PACKAGES+=	pyldap
	 
	 .if !empty(PY_LDAP_BUILDLINK3_MK:M+)
	-BUILDLINK_API_DEPENDS.pyldap+=	${PYPKGPREFIX}-ldap>=2.0.10nb1
	-BUILDLINK_ABI_DEPENDS.pyldap?=	${PYPKGPREFIX}-ldap>=2.0.10nb2
	+BUILDLINK_API_DEPENDS.pyldap+=	${PYPKGPREFIX}-ldap>=2.2.0
	+BUILDLINK_ABI_DEPENDS.pyldap?=	${PYPKGPREFIX}-ldap>=2.2.0
	 BUILDLINK_PKGSRCDIR.pyldap?=	../../databases/py-ldap
	 .endif	# PY_LDAP_BUILDLINK3_MK
	 
	diff -uNr databases/py-ldap.orig/distinfo databases/py-ldap/distinfo
	--- databases/py-ldap.orig/distinfo	2006-05-14 00:53:05.000000000 +0900
	+++ databases/py-ldap/distinfo	2006-05-14 08:48:51.000000000 +0900
	@@ -1,6 +1,6 @@
	 $NetBSD: distinfo,v 1.8 2005/10/25 17:09:33 drochner Exp $
	 
	-SHA1 (python-ldap-2.0.10.tar.gz) = 268dd0a8815080a84d4f410577873b4051da2a27
	-RMD160 (python-ldap-2.0.10.tar.gz) = 6c6e39c782812bdecf3f7325022f7aa78d9f9ff6
	-Size (python-ldap-2.0.10.tar.gz) = 80655 bytes
	-SHA1 (patch-aa) = 6285962cf3d0fa7d1a0cd4369c75db1b6d9b9476
	+SHA1 (python-ldap-2.2.0.tar.gz) = bc25275af4690b7438728787bd429e249e428260
	+RMD160 (python-ldap-2.2.0.tar.gz) = d0dc7f3852dc980b032e24bb89b6f7687d562412
	+Size (python-ldap-2.2.0.tar.gz) = 70993 bytes
	+SHA1 (patch-aa) = 4486e22126fa66be9df0f85f2f8e50303942aded
	diff -uNr databases/py-ldap.orig/options.mk databases/py-ldap/options.mk
	--- databases/py-ldap.orig/options.mk	1970-01-01 09:00:00.000000000 +0900
	+++ databases/py-ldap/options.mk	2006-05-14 10:36:12.000000000 +0900
	@@ -0,0 +1,13 @@
	+# $NetBSD$
	+
	+PKG_OPTIONS_VAR=	PKG_OPTIONS.py-ldap
	+PKG_SUPPORTED_OPTIONS=	sasl
	+
	+.include "../../mk/bsd.options.mk"
	+
	+.if !empty(PKG_OPTIONS:Msasl)
	+.include "../../security/cyrus-sasl/buildlink3.mk"
	+PY_LDAP_LIBRARY_DIRS+=	${BUILDLINK_PREFIX.cyrus-sasl}/lib
	+PY_LDAP_INCLUDE_DIRS+=	${BUILDLINK_PREFIX.cyrus-sasl}/include/sasl
	+PY_LDAP_LIBS+=		sasl2
	+.endif
	diff -uNr databases/py-ldap.orig/patches/patch-aa databases/py-ldap/patches/patch-aa
	--- databases/py-ldap.orig/patches/patch-aa	2006-05-14 00:53:05.000000000 +0900
	+++ databases/py-ldap/patches/patch-aa	2006-05-14 08:48:11.000000000 +0900
	@@ -1,15 +1,24 @@
	-$NetBSD: patch-aa,v 1.3 2005/10/25 17:09:33 drochner Exp $
	+$NetBSD$
	 
	---- setup.cfg.orig	2005-10-25 16:40:19.000000000 +0200
	+--- setup.cfg.orig	2005-07-28 21:56:49.000000000 +0900
	 +++ setup.cfg
	 @@ -7,8 +7,8 @@
	  # for wrapping OpenLDAP 2 libs
	  [_ldap]
	  
	--library_dirs = /opt/openldap-OPENLDAP_REL_ENG_2_3/lib /opt/sasl/lib
	--include_dirs = /opt/openldap-OPENLDAP_REL_ENG_2_3/include /opt/sasl/include/sasl /usr/include/sasl
	-+library_dirs = @EXTRALIBS@
	-+include_dirs = @EXTRAINCS@
	- #library_dirs = /opt/openldap-HEAD/lib /opt/sasl/lib
	- #include_dirs = /opt/openldap-HEAD/include /opt/sasl/include/sasl /usr/include/sasl
	+-library_dirs = /usr/local/openldap-REL_ENG_2_1/lib /usr/local/cyrus-sasl/lib
	+-include_dirs = /usr/local/openldap-REL_ENG_2_1/include /usr/local/cyrus-sasl/include
	++library_dirs = @PY_LDAP_LIBRARY_DIRS@
	++include_dirs = @PY_LDAP_INCLUDE_DIRS@
	  
	+ extra_compile_args = 
	+ extra_objects = 
	+@@ -23,7 +23,7 @@ extra_objects = 
	+ # Support for StartTLS/LDAPS, SASL bind and reentrant libldap_r.
	+ # This needs recent OpenLDAP 2.0.26+ or 2.1.3+ built with
	+ # ./configure --with-cyrus-sasl --with-tls
	+-libs = ldap_r lber sasl2 ssl crypto
	++libs = @PY_LDAP_LIBS@
	+ 
	+ # Installation options
	+ [install]