1
0
mirror of https://git.FreeBSD.org/ports.git synced 2025-01-11 07:22:22 +00:00

- make this port aware of python3 version distribution (different codebase)

Submitted by:	Bertrand Petit <elrond@phoe.frmug.org> (by mail)
This commit is contained in:
Ruslan Makhmatkhanov 2013-03-01 19:32:05 +00:00
parent ad3e05b470
commit 86e76a45bb
Notes: svn2git 2021-03-31 03:12:20 +00:00
svn path=/head/; revision=313164
4 changed files with 133 additions and 12 deletions

View File

@ -4,38 +4,61 @@
PORTNAME= dnspython
PORTVERSION= 1.10.0
CATEGORIES= dns python
MASTER_SITES= http://www.dnspython.org/kits/${PORTVERSION}/
MASTER_SITES= http://www.dnspython.org/kits${PORTVERSIONSUFFIX}/${PORTVERSION}/
PKGNAMEPREFIX= ${PYTHON_PKGNAMEPREFIX}
DISTNAME= ${PORTNAME}${PORTVERSIONSUFFIX}-${PORTVERSION}
MAINTAINER= rm@FreeBSD.org
COMMENT= A DNS toolkit for Python
COMMENT= DNS toolkit for Python
USE_PYTHON= -2.7
USE_PYDISTUTILS=yes
USE_PYTHON= yes
USE_PYDISTUTILS= yes
PYDISTUTILS_PKGNAME= ${PORTNAME}${PORTVERSIONSUFFIX}
PYDISTUTILS_NOEGGINFO= yes
OPTIONSFILE= ${PORT_DBDIR}/${PORTNAME}/options
OPTIONS_DEFINE= PYCRYPTO
PYCRYPTO_DESC= Enable pycrypto (part of dnssec needs it)
PORTDOCS= ChangeLog README
EXAMPLE_FILES= ddns.py e164.py mx.py name.py reverse.py reverse_name.py xfr.py \
zonediff.py
DOCSDIR= ${PREFIX}/share/doc/${PYTHON_PKGNAMEPREFIX}${PORTNAME}
.include <bsd.port.options.mk>
EXAMPLE_FILES= ddns.py e164.py mx.py name.py reverse.py reverse_name.py \
xfr.py zonediff.py
EXAMPLESDIR= ${PREFIX}/share/examples/${PYTHON_PKGNAMEPREFIX}${PORTNAME}
.include <bsd.port.pre.mk>
.if ${PYTHON_MAJOR_VER} < 3
PORTVERSIONSUFFIX=
PLIST= ${PKGDIR}/pkg-plist-py2
.else
PORTVERSIONSUFFIX=3
PLIST= ${PKGDIR}/pkg-plist-py3
EXAMPLESDIR:= ${EXAMPLESDIR}3
.endif
PLIST_SUB+= PORTVERSION=${PORTVERSION} PYTHON_VER=${PYTHON_VER}
post-patch:
for example in ${EXAMPLE_FILES} ; \
do ${REINPLACE_CMD} -e 's|python3|${PYTHON_VERSION}|1' \
${WRKSRC}/examples/$${example} ; \
done
post-install:
# docs
.if ${PORT_OPTIONS:MDOCS}
@${MKDIR} ${DOCSDIR}
.for file in ${PORTDOCS}
@${INSTALL_DATA} ${WRKSRC}/${file} ${DOCSDIR}
.for docfile in ${PORTDOCS}
@${INSTALL_DATA} ${WRKSRC}/${docfile} ${DOCSDIR}
.endfor
.endif
# examples
.if ${PORT_OPTIONS:MEXAMPLES}
@${MKDIR} ${EXAMPLESDIR}
.for file in ${EXAMPLE_FILES}
@${INSTALL_DATA} ${WRKSRC}/examples/${file} ${EXAMPLESDIR}
.for docfile in ${EXAMPLE_FILES}
@${INSTALL_DATA} ${WRKSRC}/examples/${docfile} ${EXAMPLESDIR}
.endfor
.endif
# permission safeness
@ -46,4 +69,4 @@ post-install:
RUN_DEPENDS+= ${PYTHON_PKGNAMEPREFIX}pycrypto>0:${PORTSDIR}/security/py-pycrypto
.endif
.include <bsd.port.mk>
.include <bsd.port.post.mk>

View File

@ -1,2 +1,4 @@
SHA256 (dnspython-1.10.0.tar.gz) = 4dc21450ec6ac94dd105b4e5f39a75b404ad45a30869ff73acb6fd4d9974f857
SIZE (dnspython-1.10.0.tar.gz) = 124416
SHA256 (dnspython3-1.10.0.tar.gz) = 1478051ba0ad24aa33ce4cd504190104ede99ca3c8c907163f4cc820ddfe2e95
SIZE (dnspython3-1.10.0.tar.gz) = 123929

View File

@ -1,3 +1,4 @@
%%PYTHON_SITELIBDIR%%/dnspython-%%PORTVERSION%%-py%%PYTHON_VER%%.egg-info
%%PYTHON_SITELIBDIR%%/dns/__init__.py
%%PYTHON_SITELIBDIR%%/dns/__init__.pyc
%%PYTHON_SITELIBDIR%%/dns/__init__.pyo

View File

@ -0,0 +1,95 @@
%%PYTHON_SITELIBDIR%%/dnspython3-%%PORTVERSION%%-py%%PYTHON_VER%%.egg-info
%%PYTHON_SITELIBDIR%%/dns/__init__.py
%%PYTHON_SITELIBDIR%%/dns/dnssec.py
%%PYTHON_SITELIBDIR%%/dns/e164.py
%%PYTHON_SITELIBDIR%%/dns/edns.py
%%PYTHON_SITELIBDIR%%/dns/entropy.py
%%PYTHON_SITELIBDIR%%/dns/exception.py
%%PYTHON_SITELIBDIR%%/dns/flags.py
%%PYTHON_SITELIBDIR%%/dns/hash.py
%%PYTHON_SITELIBDIR%%/dns/inet.py
%%PYTHON_SITELIBDIR%%/dns/ipv4.py
%%PYTHON_SITELIBDIR%%/dns/ipv6.py
%%PYTHON_SITELIBDIR%%/dns/message.py
%%PYTHON_SITELIBDIR%%/dns/name.py
%%PYTHON_SITELIBDIR%%/dns/namedict.py
%%PYTHON_SITELIBDIR%%/dns/node.py
%%PYTHON_SITELIBDIR%%/dns/opcode.py
%%PYTHON_SITELIBDIR%%/dns/query.py
%%PYTHON_SITELIBDIR%%/dns/rcode.py
%%PYTHON_SITELIBDIR%%/dns/rdata.py
%%PYTHON_SITELIBDIR%%/dns/rdataclass.py
%%PYTHON_SITELIBDIR%%/dns/rdataset.py
%%PYTHON_SITELIBDIR%%/dns/rdatatype.py
%%PYTHON_SITELIBDIR%%/dns/renderer.py
%%PYTHON_SITELIBDIR%%/dns/resolver.py
%%PYTHON_SITELIBDIR%%/dns/reversename.py
%%PYTHON_SITELIBDIR%%/dns/rrset.py
%%PYTHON_SITELIBDIR%%/dns/set.py
%%PYTHON_SITELIBDIR%%/dns/tokenizer.py
%%PYTHON_SITELIBDIR%%/dns/tsig.py
%%PYTHON_SITELIBDIR%%/dns/tsigkeyring.py
%%PYTHON_SITELIBDIR%%/dns/ttl.py
%%PYTHON_SITELIBDIR%%/dns/update.py
%%PYTHON_SITELIBDIR%%/dns/util.py
%%PYTHON_SITELIBDIR%%/dns/version.py
%%PYTHON_SITELIBDIR%%/dns/wiredata.py
%%PYTHON_SITELIBDIR%%/dns/zone.py
%%PYTHON_SITELIBDIR%%/dns/rdtypes/__init__.py
%%PYTHON_SITELIBDIR%%/dns/rdtypes/dsbase.py
%%PYTHON_SITELIBDIR%%/dns/rdtypes/mxbase.py
%%PYTHON_SITELIBDIR%%/dns/rdtypes/nsbase.py
%%PYTHON_SITELIBDIR%%/dns/rdtypes/txtbase.py
%%PYTHON_SITELIBDIR%%/dns/rdtypes/IN/__init__.py
%%PYTHON_SITELIBDIR%%/dns/rdtypes/IN/A.py
%%PYTHON_SITELIBDIR%%/dns/rdtypes/IN/AAAA.py
%%PYTHON_SITELIBDIR%%/dns/rdtypes/IN/APL.py
%%PYTHON_SITELIBDIR%%/dns/rdtypes/IN/DHCID.py
%%PYTHON_SITELIBDIR%%/dns/rdtypes/IN/IPSECKEY.py
%%PYTHON_SITELIBDIR%%/dns/rdtypes/IN/KX.py
%%PYTHON_SITELIBDIR%%/dns/rdtypes/IN/NAPTR.py
%%PYTHON_SITELIBDIR%%/dns/rdtypes/IN/NSAP.py
%%PYTHON_SITELIBDIR%%/dns/rdtypes/IN/NSAP_PTR.py
%%PYTHON_SITELIBDIR%%/dns/rdtypes/IN/PX.py
%%PYTHON_SITELIBDIR%%/dns/rdtypes/IN/SRV.py
%%PYTHON_SITELIBDIR%%/dns/rdtypes/IN/WKS.py
%%PYTHON_SITELIBDIR%%/dns/rdtypes/ANY/__init__.py
%%PYTHON_SITELIBDIR%%/dns/rdtypes/ANY/AFSDB.py
%%PYTHON_SITELIBDIR%%/dns/rdtypes/ANY/CERT.py
%%PYTHON_SITELIBDIR%%/dns/rdtypes/ANY/CNAME.py
%%PYTHON_SITELIBDIR%%/dns/rdtypes/ANY/DLV.py
%%PYTHON_SITELIBDIR%%/dns/rdtypes/ANY/DNAME.py
%%PYTHON_SITELIBDIR%%/dns/rdtypes/ANY/DNSKEY.py
%%PYTHON_SITELIBDIR%%/dns/rdtypes/ANY/DS.py
%%PYTHON_SITELIBDIR%%/dns/rdtypes/ANY/GPOS.py
%%PYTHON_SITELIBDIR%%/dns/rdtypes/ANY/HINFO.py
%%PYTHON_SITELIBDIR%%/dns/rdtypes/ANY/HIP.py
%%PYTHON_SITELIBDIR%%/dns/rdtypes/ANY/ISDN.py
%%PYTHON_SITELIBDIR%%/dns/rdtypes/ANY/LOC.py
%%PYTHON_SITELIBDIR%%/dns/rdtypes/ANY/MX.py
%%PYTHON_SITELIBDIR%%/dns/rdtypes/ANY/NS.py
%%PYTHON_SITELIBDIR%%/dns/rdtypes/ANY/NSEC.py
%%PYTHON_SITELIBDIR%%/dns/rdtypes/ANY/NSEC3.py
%%PYTHON_SITELIBDIR%%/dns/rdtypes/ANY/NSEC3PARAM.py
%%PYTHON_SITELIBDIR%%/dns/rdtypes/ANY/PTR.py
%%PYTHON_SITELIBDIR%%/dns/rdtypes/ANY/RP.py
%%PYTHON_SITELIBDIR%%/dns/rdtypes/ANY/RRSIG.py
%%PYTHON_SITELIBDIR%%/dns/rdtypes/ANY/RT.py
%%PYTHON_SITELIBDIR%%/dns/rdtypes/ANY/SOA.py
%%PYTHON_SITELIBDIR%%/dns/rdtypes/ANY/SPF.py
%%PYTHON_SITELIBDIR%%/dns/rdtypes/ANY/SSHFP.py
%%PYTHON_SITELIBDIR%%/dns/rdtypes/ANY/TXT.py
%%PYTHON_SITELIBDIR%%/dns/rdtypes/ANY/X25.py
%%PORTEXAMPLES%%%%EXAMPLESDIR%%/ddns.py
%%PORTEXAMPLES%%%%EXAMPLESDIR%%/e164.py
%%PORTEXAMPLES%%%%EXAMPLESDIR%%/mx.py
%%PORTEXAMPLES%%%%EXAMPLESDIR%%/name.py
%%PORTEXAMPLES%%%%EXAMPLESDIR%%/reverse.py
%%PORTEXAMPLES%%%%EXAMPLESDIR%%/reverse_name.py
%%PORTEXAMPLES%%%%EXAMPLESDIR%%/xfr.py
%%PORTEXAMPLES%%%%EXAMPLESDIR%%/zonediff.py
%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%
@dirrm %%PYTHON_SITELIBDIR%%/dns/rdtypes/IN
@dirrm %%PYTHON_SITELIBDIR%%/dns/rdtypes/ANY
@dirrm %%PYTHON_SITELIBDIR%%/dns/rdtypes
@dirrm %%PYTHON_SITELIBDIR%%/dns