git: 96a2ccd630ae - main - graphics/py-h3: Fix build with setuptools 58.0.0+

From: Po-Chuan Hsieh <sunpoet_at_FreeBSD.org>
Date: Fri, 25 Mar 2022 13:44:38 UTC
The branch main has been updated by sunpoet:

URL: https://cgit.FreeBSD.org/ports/commit/?id=96a2ccd630ae3f6d4d071578dd28cf4ee19a59ed

commit 96a2ccd630ae3f6d4d071578dd28cf4ee19a59ed
Author:     Po-Chuan Hsieh <sunpoet@FreeBSD.org>
AuthorDate: 2022-03-25 13:00:17 +0000
Commit:     Po-Chuan Hsieh <sunpoet@FreeBSD.org>
CommitDate: 2022-03-25 13:37:04 +0000

    graphics/py-h3: Fix build with setuptools 58.0.0+
---
 graphics/py-h3/Makefile | 5 +++++
 1 file changed, 5 insertions(+)

diff --git a/graphics/py-h3/Makefile b/graphics/py-h3/Makefile
index 43f53e28d3d2..19ada687f886 100644
--- a/graphics/py-h3/Makefile
+++ b/graphics/py-h3/Makefile
@@ -30,6 +30,11 @@ NUMPY_DESC=	NumPy support
 
 NUMPY_RUN_DEPENDS=	${PYTHON_PKGNAMEPREFIX}numpy>=0,1:math/py-numpy@${PY_FLAVOR}
 
+post-install:
+	${FIND} ${STAGEDIR}${PYTHON_SITELIBDIR} -name '*.so' -exec ${STRIP_CMD} {} +
+	${PYTHON_CMD} -m compileall -d ${PYTHON_SITELIBDIR} ${STAGEDIR}${PYTHON_SITELIBDIR}
+	${PYTHON_CMD} -O -m compileall -d ${PYTHON_SITELIBDIR} ${STAGEDIR}${PYTHON_SITELIBDIR}
+
 do-test:
 	cd ${WRKSRC} && ${SETENV} PYTHONPATH=${STAGEDIR}${PYTHON_SITELIBDIR} ${PYTHON_CMD} -m pytest -rs -v