summaryrefslogtreecommitdiffstats
path: root/security/py-pynacl/Makefile
blob: 03a44e93caccf1b6ebc34e506a1927634de2f38d (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
# Created by: Yuri Victorovich <yuri@rawbw.com>
# $FreeBSD$

PORTNAME=	pynacl
PORTVERSION=	1.1.2
CATEGORIES=	security python
MASTER_SITES=	CHEESESHOP
PKGNAMEPREFIX=	${PYTHON_PKGNAMEPREFIX}
DISTNAME=	PyNaCl-${PORTVERSION}

MAINTAINER=	yuri@rawbw.com
COMMENT=	PyNaCl is a Python binding to the Networking and Cryptography library

LICENSE=	APACHE20
LICENSE_FILE=	${WRKSRC}/LICENSE

RUN_DEPENDS=	${PYTHON_PKGNAMEPREFIX}cffi>0:devel/py-cffi \
		${PYTHON_PKGNAMEPREFIX}six>0:devel/py-six
BUILD_DEPENDS=	${RUN_DEPENDS}
BUNDLED_NACL_LIB_DEPENDS_OFF=	libsodium.so:security/libsodium
TEST_DEPENDS=	${PYTHON_PKGNAMEPREFIX}pytest>0:devel/py-pytest

USES=		python localbase
USE_PYTHON=	autoplist distutils
BUNDLED_NACL_MAKE_ENV_OFF+=	SODIUM_INSTALL=system

OPTIONS_DEFINE=	BUNDLED_NACL
BUNDLED_NACL_DESC=	Use bundled NaCl version

post-install:
	${STRIP_CMD} ${STAGEDIR}${PYTHONPREFIX_SITELIBDIR}/nacl/_sodium.so

do-test:
	@cd ${WRKSRC} && ${SETENV} PYTHONPATH=../src ${PYTHON_CMD} -m pytest -rs tests

.include <bsd.port.mk>
OpenPOWER on IntegriCloud