git: 5b0b801228eb - main - lang/python311: Fix build on armv7 with LLVM 17
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Sun, 04 Feb 2024 19:30:57 UTC
The branch main has been updated by vishwin: URL: https://cgit.FreeBSD.org/ports/commit/?id=5b0b801228eba3d1dfc39b9b595b3a089e118dc1 commit 5b0b801228eba3d1dfc39b9b595b3a089e118dc1 Author: Benjamin Jacobs <freebsd@dev.thsi.be> AuthorDate: 2024-02-04 18:13:23 +0000 Commit: Charlie Li <vishwin@FreeBSD.org> CommitDate: 2024-02-04 19:30:27 +0000 lang/python311: Fix build on armv7 with LLVM 17 Reported by: brd PR: 276249 --- lang/python311/Makefile | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/lang/python311/Makefile b/lang/python311/Makefile index 9b8d5e69df96..6685942472ff 100644 --- a/lang/python311/Makefile +++ b/lang/python311/Makefile @@ -109,6 +109,15 @@ EXTRA_PATCHES+= ${PATCHDIR}/libressl CONFIGURE_ENV+= ac_cv_working_openssl_hashlib=yes .endif +.include <bsd.port.pre.mk> + +# llvm17 with -flto=thin makes Programs/_freeze_module crash on armv7; workaround +# cf. https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=276249 +.if ${ARCH} == armv7 && ${CHOSEN_COMPILER_TYPE} == clang && ${COMPILER_VERSION} >= 170 && \ + ${COMPILER_VERSION} < 180 +CONFIGURE_ARGS:= ${CONFIGURE_ARGS:N${LTO_CONFIGURE_ON}} +.endif + post-patch: # disable the detection of includes and library from e2fsprogs-libuuid, # which introduces hidden dependency and breaks build @@ -150,4 +159,4 @@ post-install: ${INSTALL_DATA} ${WRKSRC}/Tools/gdb/libpython.py \ ${STAGEDIR}${PREFIX}/lib/libpython${PYTHON_VER}${ABIFLAGS}.so.1.0-gdb.py -.include <bsd.port.mk> +.include <bsd.port.post.mk>