git: bfaa9b92afdc - main - math/py-mnnpy: Make march compiler argument depend on CPUTYPE
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Wed, 16 Aug 2023 00:26:15 UTC
The branch main has been updated by yuri: URL: https://cgit.FreeBSD.org/ports/commit/?id=bfaa9b92afdc9275aec98f145b2e731865fa6ecd commit bfaa9b92afdc9275aec98f145b2e731865fa6ecd Author: Yuri Victorovich <yuri@FreeBSD.org> AuthorDate: 2023-08-16 00:25:16 +0000 Commit: Yuri Victorovich <yuri@FreeBSD.org> CommitDate: 2023-08-16 00:26:13 +0000 math/py-mnnpy: Make march compiler argument depend on CPUTYPE Reported by: fallout --- math/py-mnnpy/Makefile | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/math/py-mnnpy/Makefile b/math/py-mnnpy/Makefile index adf1fd1e9a0b..30ff2a05ed11 100644 --- a/math/py-mnnpy/Makefile +++ b/math/py-mnnpy/Makefile @@ -1,5 +1,6 @@ PORTNAME= mnnpy DISTVERSION= 0.1.9.5 +PORTREVISION= 1 CATEGORIES= math python MASTER_SITES= PYPI PKGNAMEPREFIX= ${PYTHON_PKGNAMEPREFIX} @@ -22,6 +23,13 @@ RUN_DEPENDS= ${PY_DEPENDS} USES= python USE_PYTHON= distutils cython autoplist +post-patch: +.if defined(CPUTYPE) + @${REINPLACE_CMD} -e "s|'-march=native'|'-march=${CPUTYPE}'|" ${WRKSRC}/setup.py +.else + @${REINPLACE_CMD} -e "s|'-march=native', ||" ${WRKSRC}/setup.py +.endif + post-install: @${STRIP_CMD} ${STAGEDIR}${PYTHON_SITELIBDIR}/mnnpy/_utils.cpython-39.so