Changeset View
Changeset View
Standalone View
Standalone View
graphics/py-cairocffi/Makefile
# Created by: Dave Cottlehuber <dch@skunkwerks.at> | # Created by: Dave Cottlehuber <dch@skunkwerks.at> | ||||
# $FreeBSD$ | # $FreeBSD$ | ||||
PORTNAME= cairocffi | PORTNAME= cairocffi | ||||
PORTVERSION= 0.8.0 | PORTVERSION= 1.0.2 | ||||
PORTREVISION= 2 | |||||
CATEGORIES= graphics python | CATEGORIES= graphics python | ||||
MASTER_SITES= CHEESESHOP | MASTER_SITES= CHEESESHOP | ||||
PKGNAMEPREFIX= ${PYTHON_PKGNAMEPREFIX} | PKGNAMEPREFIX= ${PYTHON_PKGNAMEPREFIX} | ||||
MAINTAINER= dch@skunkwerks.at | MAINTAINER= dch@skunkwerks.at | ||||
COMMENT= Cairo cffi-based cairo bindings for Python | COMMENT= CFFI-based Cairo bindings for Python | ||||
LICENSE= BSD3CLAUSE | LICENSE= BSD3CLAUSE | ||||
LICENSE_FILE= ${WRKSRC}/LICENSE | |||||
RUN_DEPENDS= ${PYTHON_PKGNAMEPREFIX}cffi>0:devel/py-cffi@${PY_FLAVOR} \ | BUILD_DEPENDS= ${PYTHON_PKGNAMEPREFIX}cffi>=1.1.0:devel/py-cffi@${PY_FLAVOR} | ||||
${PYTHON_PKGNAMEPREFIX}xcffib>=0.5.0:x11/py-xcffib@${PY_FLAVOR} | RUN_DEPENDS= ${PYTHON_PKGNAMEPREFIX}cffi>=1.1.0:devel/py-cffi@${PY_FLAVOR} \ | ||||
BUILD_DEPENDS= ${RUN_DEPENDS} | ${PYTHON_PKGNAMEPREFIX}xcffib>=0.3.2:x11/py-xcffib@${PY_FLAVOR} | ||||
TEST_DEPENDS= ${PYTHON_PKGNAMEPREFIX}pytest>0:devel/py-pytest@${PY_FLAVOR} \ | |||||
gdk-pixbuf2>0:graphics/gdk-pixbuf2 | |||||
USES= python | USES= gnome python:3.5+ | ||||
USE_PYTHON= distutils py3kplist | |||||
USE_GNOME= cairo | USE_GNOME= cairo | ||||
USE_PYTHON= distutils autoplist | |||||
# --record output is not complete so supplement w/ a plist for now | |||||
# https://github.com/Kozea/cairocffi/issues/108 | |||||
PLIST_SUB+= PYTHON_PYOEXTENSION=${PYTHON_PYOEXTENSION} | |||||
mat: PYTHON_PYOEXTENSION was removed from PLIST_SUB because for the 3.5+ case, it is **always** `opt… | |||||
koobsAuthorUnsubmitted Done Inline ActionsI'll remove it in this instance given the lack of use in the tree after its recent removal, but it's actually variable. It's only the same at the moment as we specify PYDISTUTILS_INSTALLARGS=-O1 in python.mk, but there are other values, which we may want to use/change to. Python can also change the format at any time, conditionally based on build type or globally, as it has in the past, which is a better argument than our -O1 use for keeping it a variable. Currently, a changing format would require sweeping every pkg-plist in the tree. But let's cross that bridge when we come to it. koobs: I'll remove it in this instance given the lack of use in the tree after its recent removal, but… | |||||
# _generated files only exist after install not build | |||||
# so copy them to the src directory so we can run tests against WRKSRC | |||||
# | |||||
# -v = verbose, -rs print skip reasons, -o override tox.ini/pytest.ini args | |||||
do-test: | |||||
${CP} -Rp ${STAGEDIR}${PYTHONPREFIX_SITELIBDIR}/${PORTNAME}/_generated ${WRKSRC}/${PORTNAME} | |||||
${TOUCH} ${WRKSRC}/${PORTNAME}/_generated/__init__.py | |||||
@cd ${WRKSRC} && ${PYTHON_CMD} -m pytest -v -rs -o addopts= | |||||
.include <bsd.port.mk> | .include <bsd.port.mk> |
PYTHON_PYOEXTENSION was removed from PLIST_SUB because for the 3.5+ case, it is always opt-1.pyc. Why add it back here? It would probably be better to simply write opt-1.pyc in the plist file, as it is a constant.