svn commit: r525712 - head/math/py-yt
Alexey Dokuchaev
danfe at FreeBSD.org
Mon Feb 10 15:42:52 UTC 2020
Author: danfe
Date: Mon Feb 10 15:42:52 2020
New Revision: 525712
URL: https://svnweb.freebsd.org/changeset/ports/525712
Log:
Make Embree ray-tracing engine support optional, to simplify the upcoming
update of `graphics/embree'. No changes in generated package by default.
Modified:
head/math/py-yt/Makefile
Modified: head/math/py-yt/Makefile
==============================================================================
--- head/math/py-yt/Makefile Mon Feb 10 15:36:48 2020 (r525711)
+++ head/math/py-yt/Makefile Mon Feb 10 15:42:52 2020 (r525712)
@@ -14,21 +14,34 @@ COMMENT= Analysis and visualization toolkit for volume
LICENSE= BSD3CLAUSE
LICENSE_FILE= ${WRKSRC}/COPYING.txt
-BUILD_DEPENDS= ${PYNUMPY} \
- ${PYTHON_PKGNAMEPREFIX}pyembree>0:graphics/py-pyembree@${PY_FLAVOR}
-LIB_DEPENDS= libembree.so:graphics/embree \
- libomp.so:devel/openmp
+BUILD_DEPENDS= ${PYNUMPY}
+LIB_DEPENDS= libomp.so:devel/openmp
RUN_DEPENDS= ${PYTHON_PKGNAMEPREFIX}sympy>=1.0:math/py-sympy@${PY_FLAVOR} \
${PYNUMPY} \
- ${PYTHON_PKGNAMEPREFIX}pyembree>0:graphics/py-pyembree@${PY_FLAVOR} \
${PYTHON_PKGNAMEPREFIX}matplotlib>=1.5.3:math/py-matplotlib@${PY_FLAVOR} \
${PYTHON_PKGNAMEPREFIX}ipython5>=1.0:devel/ipython5@${PY_FLAVOR}
USES= dos2unix localbase python
USE_PYTHON= distutils cython autoplist concurrent
+OPTIONS_DEFINE= EMBREE
+OPTIONS_DEFAULT= EMBREE
+EMBREE_DESC= Embree ray-tracing engine support
+
+EMBREE_BUILD_DEPENDS= ${PYTHON_PKGNAMEPREFIX}pyembree>0:graphics/py-pyembree@${PY_FLAVOR}
+EMBREE_LIB_DEPENDS= libembree.so:graphics/embree
+EMBREE_RUN_DEPENDS= ${EMBREE_BUILD_DEPENDS}
+
+post-patch-EMBREE-on:
+ @${REINPLACE_CMD} -e "s|check_for_pyembree() is not None|True|" \
+ ${WRKSRC}/setup.py
+
+post-patch-EMBREE-off:
+ @${REINPLACE_CMD} -e "s|check_for_pyembree() is not None|False|" \
+ ${WRKSRC}/setup.py
+
post-patch:
- @${REINPLACE_CMD} -e "s|check_for_pyembree() is not None|True|; s|check_for_openmp() is True|True|" \
+ @${REINPLACE_CMD} -e "s|check_for_openmp() is True|True|" \
${WRKSRC}/setup.py
@${REINPLACE_CMD} -e "s|\['-fopenmp', filename\]|['-I${LOCALBASE}/include', '-L${LOCALBASE}/lib', '-lm', '-fopenmp', filename]|" \
${WRKSRC}/setupext.py
More information about the svn-ports-all
mailing list