git: e13b0edc8bb2 - main - devel/py-greenlet: fix build with clang 16 on i386
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Mon, 05 Jun 2023 17:20:40 UTC
The branch main has been updated by dim: URL: https://cgit.FreeBSD.org/ports/commit/?id=e13b0edc8bb2f696676715abd54d65b9c0403b66 commit e13b0edc8bb2f696676715abd54d65b9c0403b66 Author: Dimitry Andric <dim@FreeBSD.org> AuthorDate: 2023-05-29 18:22:34 +0000 Commit: Dimitry Andric <dim@FreeBSD.org> CommitDate: 2023-06-05 17:19:29 +0000 devel/py-greenlet: fix build with clang 16 on i386 Since clang 16 (and gcc 11) the default C++ standard is now gnu++17. Because devel/py-greenlet's build infrastructure does not explicitly set its C++ standard, this leads to several errors: In file included from src/greenlet/greenlet.cpp:21: In file included from src/greenlet/greenlet_slp_switch.hpp:82: In file included from src/greenlet/slp_platformselect.h:18: src/greenlet/platform/switch_x86_unix.h:54:5: error: ISO C++17 does not allow 'register' storage class specifier [-Wregister] register int *stackref, stsizediff; ^~~~~~~~~ src/greenlet/platform/switch_x86_unix.h:54:5: error: ISO C++17 does not allow 'register' storage class specifier [-Wregister] register int *stackref, stsizediff; ^~~~~~~~~ The register keyword has already been removed from the similar switch_amd64_unix.h header, which is why the above problem does not occur on amd64. To work around the errors, define the register keyword away using CPPFLAGS. PR: 271712 Approved by: sunpoet (maintainer) MFH: 2023Q2 --- devel/py-greenlet/Makefile | 3 +++ 1 file changed, 3 insertions(+) diff --git a/devel/py-greenlet/Makefile b/devel/py-greenlet/Makefile index bf0be9f0ad5a..e433e84e57fa 100644 --- a/devel/py-greenlet/Makefile +++ b/devel/py-greenlet/Makefile @@ -1,5 +1,6 @@ PORTNAME= greenlet PORTVERSION= 2.0.2 +PORTREVISION= 1 CATEGORIES= devel python MASTER_SITES= PYPI PKGNAMEPREFIX= ${PYTHON_PKGNAMEPREFIX} @@ -17,6 +18,8 @@ NOT_FOR_ARCHS_REASON= greenlet needs to be ported to this platform USES= python:3.5+ USE_PYTHON= autoplist concurrent distutils +CPPFLAGS+= -Dregister= + post-install: ${FIND} ${STAGEDIR}${PYTHON_SITELIBDIR} -name '*.so' -exec ${STRIP_CMD} {} +