forked from Lainports/freebsd-ports
Ports using USE_PYTHON=distutils are now flavored. They will
automatically get flavors (py27, py34, py35, py36) depending on what
versions they support.
There is also a USE_PYTHON=flavors for ports that do not use distutils
but need FLAVORS to be set. A USE_PYTHON=noflavors can be set if
using distutils but flavors are not wanted.
A new USE_PYTHON=optsuffix that will add PYTHON_PKGNAMESUFFIX has been
added to cope with Python ports that did not have the Python
PKGNAMEPREFIX but are flavored.
USES=python now also exports a PY_FLAVOR variable that contains the
current python flavor. It can be used in dependency lines when the
port itself is not python flavored. For example, deskutils/calibre.
By default, all the flavors are generated. To only generate flavors
for the versions in PYTHON2_DEFAULT and PYTHON3_DEFAULT, define
BUILD_DEFAULT_PYTHON_FLAVORS in your make.conf.
In all the ports with Python dependencies, the *_DEPENDS entries MUST
end with the flavor so that the framework knows which to build/use.
This is done by appending '@${PY_FLAVOR}' after the origin (or
@${FLAVOR} if in a Python module with Python flavors, as the content
will be the same). For example:
RUN_DEPENDS= ${PYTHON_PKGNAMEPREFIX}six>0:devel/py-six@${PY_FLAVOR}
PR: 223071
Reviewed by: portmgr, python
Sponsored by: Absolight
Differential Revision: https://reviews.freebsd.org/D12464
95 lines
2.8 KiB
Makefile
95 lines
2.8 KiB
Makefile
# Created by: Gerhard Häring <gh@ghaering.de>
|
|
# $FreeBSD$
|
|
|
|
PORTNAME= duplicity
|
|
PORTVERSION= 0.7.15
|
|
CATEGORIES= sysutils
|
|
MASTER_SITES= http://launchpad.net/duplicity/0.7-series/${PORTVERSION}/+download/
|
|
|
|
MAINTAINER= dbaio@FreeBSD.org
|
|
COMMENT= Backup tool that uses librsync and GnuPG
|
|
|
|
LICENSE= GPLv2+
|
|
LICENSE_FILE= ${WRKSRC}/COPYING
|
|
|
|
LIB_DEPENDS= librsync.so:net/librsync2
|
|
RUN_DEPENDS= ${PYTHON_PKGNAMEPREFIX}fasteners>=0:devel/py-fasteners@${FLAVOR}
|
|
|
|
USES= python:2
|
|
USE_PYTHON= autoplist distutils
|
|
USE_LDCONFIG= yes
|
|
|
|
PORTDOCS= CHANGELOG COPYING README README-REPO README-LOG
|
|
|
|
OPTIONS_DEFINE= DOCS FTP FTPS GDOCS GIO NLS S3
|
|
OPTIONS_GROUP= GPG SSH
|
|
OPTIONS_SINGLE= GPG
|
|
OPTIONS_SINGLE_GPG= GNUPG GNUPG2
|
|
OPTIONS_GROUP_SSH= PARAMIKO PEXPECT
|
|
OPTIONS_DEFAULT= FTP FTPS GNUPG PARAMIKO S3
|
|
FTP_DESC= FTP backend
|
|
FTPS_DESC= FTPS backend
|
|
GDOCS_DESC= Google Docs backend
|
|
GIO_DESC= GIO backend
|
|
GPG_DESC= GnuPG support
|
|
GNUPG_DESC= Use GnuPG 1
|
|
GNUPG2_DESC= Use GnuPG 2
|
|
S3_DESC= Amazon S3 backend
|
|
SSH_DESC= SSH/SCP/SFTP backend
|
|
PARAMIKO_DESC= python ssh implementation
|
|
PEXPECT_DESC= pexpect and use ssh binaries
|
|
|
|
FTP_RUN_DEPENDS= ncftp>=3.2.2:ftp/ncftp3
|
|
FTPS_RUN_DEPENDS= lftp>=3.7.15:ftp/lftp
|
|
GDOCS_RUN_DEPENDS= ${PYTHON_PKGNAMEPREFIX}gdata>0:devel/py-gdata@${FLAVOR}
|
|
GIO_RUN_DEPENDS= ${PYTHON_PKGNAMEPREFIX}gobject>0:devel/py-gobject@${FLAVOR} \
|
|
dbus>0:devel/dbus
|
|
GNUPG_RUN_DEPENDS= gnupg1>=1.4.7:security/gnupg1
|
|
GNUPG2_RUN_DEPENDS= gpg2:security/gnupg
|
|
NLS_USES= gettext
|
|
PARAMIKO_RUN_DEPENDS= ${PYTHON_PKGNAMEPREFIX}paramiko>=1.7.7.1:security/py-paramiko@${FLAVOR}
|
|
PEXPECT_RUN_DEPENDS= ${PYTHON_PKGNAMEPREFIX}pexpect>0:misc/py-pexpect@${FLAVOR}
|
|
S3_RUN_DEPENDS= ${PYTHON_PKGNAMEPREFIX}boto>=1.6b:devel/py-boto@${FLAVOR}
|
|
|
|
post-patch:
|
|
.for f in cfbackend _cf_cloudfiles _cf_pyrax
|
|
@${RM} ${WRKSRC}/${PORTNAME}/backends/${f}.py
|
|
.endfor
|
|
|
|
post-patch-NLS-off:
|
|
@${REINPLACE_CMD} -e '56,67d' \
|
|
${WRKSRC}/setup.py
|
|
|
|
post-patch-PARAMIKO-off:
|
|
@${FIND} ${WRKSRC}/${PORTNAME}/backends -type f -depth 1 \
|
|
-name '*ssh_paramiko*' -delete
|
|
|
|
post-patch-PEXPECT-off:
|
|
@${FIND} ${WRKSRC}/${PORTNAME}/backends -type f -depth 1 \
|
|
-name '*ssh_pexpect*' -delete
|
|
|
|
post-patch-FTP-off:
|
|
@${RM} ${WRKSRC}/${PORTNAME}/backends/ftpbackend.py
|
|
|
|
post-patch-FTPS-off:
|
|
@${RM} ${WRKSRC}/${PORTNAME}/backends/ftpsbackend.py
|
|
|
|
post-patch-S3-off:
|
|
.for f in botobackend _boto_multi _boto_single
|
|
@${RM} ${WRKSRC}/${PORTNAME}/backends/${f}.py
|
|
.endfor
|
|
|
|
post-patch-GDOCS-off:
|
|
@${RM} ${WRKSRC}/${PORTNAME}/backends/gdocsbackend.py
|
|
|
|
post-patch-GIO-off:
|
|
@${RM} ${WRKSRC}/${PORTNAME}/backends/giobackend.py
|
|
|
|
post-install:
|
|
@${STRIP_CMD} ${STAGEDIR}${PREFIX}/lib/python2.7/site-packages/duplicity/_librsync.so
|
|
|
|
post-install-DOCS-on:
|
|
@${MKDIR} ${STAGEDIR}${DOCSDIR}
|
|
${INSTALL_DATA} ${PORTDOCS:S|^|${WRKSRC}/|g} ${STAGEDIR}${DOCSDIR}
|
|
|
|
.include <bsd.port.mk>
|