python*: Avoid configure test for POSIX semaphores on Linux.

This attempts to build and run a program that uses POSIX semaphores.

This fails in a pbulk sandbox that doesn't contain /dev/shm, resulting
in a broken package where the idea that the platform doesn't support
POSIX semaphores is baked in forever. In newer Python versions,
this means Python doesn't even build properly.

XXX: We might want to avoid it on other platforms too...
This commit is contained in:
nia 2020-12-06 11:11:31 +00:00
parent 596087a7d7
commit 903170f361
5 changed files with 20 additions and 5 deletions

View file

@ -1,4 +1,4 @@
# $NetBSD: Makefile,v 1.90 2020/09/20 11:06:23 mgorny Exp $
# $NetBSD: Makefile,v 1.91 2020/12/06 11:11:31 nia Exp $
.include "dist.mk"
@ -23,6 +23,9 @@ CONFIGURE_ARGS+= --with-system-ffi
CONFIGURE_ARGS+= --with-threads
CONFIGURE_ENV+= MKDIR_P=${MKDIR:Q}
CONFIGURE_ENV+= OPT=${CFLAGS:M*:Q}
# If the build sandbox doesn't have /dev/shm mounted, don't produce
# broken packages.
CONFIGURE_ENV.Linux+= ac_cv_posix_semaphores_enabled=yes
PKGCONFIG_OVERRIDE+= Misc/python.pc.in
LDFLAGS+= -L${WRKSRC}

View file

@ -1,4 +1,4 @@
# $NetBSD: Makefile,v 1.27 2020/09/01 09:26:54 schmonz Exp $
# $NetBSD: Makefile,v 1.28 2020/12/06 11:11:31 nia Exp $
.include "dist.mk"
@ -29,6 +29,9 @@ CONFIGURE_ARGS+= --with-threads
CONFIGURE_ARGS+= --without-ensurepip
CONFIGURE_ENV+= OPT=${CFLAGS:M*:Q}
CONFIGURE_ENV+= ac_cv_path_mkdir=${TOOLS_PATH.mkdir}
# If the build sandbox doesn't have /dev/shm mounted, don't produce
# broken packages.
CONFIGURE_ENV.Linux+= ac_cv_posix_semaphores_enabled=yes
PKGCONFIG_OVERRIDE+= Misc/python.pc.in
PTHREAD_OPTS+= require

View file

@ -1,4 +1,4 @@
# $NetBSD: Makefile,v 1.22 2020/11/17 19:33:26 sjmulder Exp $
# $NetBSD: Makefile,v 1.23 2020/12/06 11:11:31 nia Exp $
.include "dist.mk"
@ -29,6 +29,9 @@ CONFIGURE_ARGS+= --with-system-ffi
CONFIGURE_ARGS+= --without-ensurepip
CONFIGURE_ENV+= OPT=${CFLAGS:M*:Q}
CONFIGURE_ENV+= ac_cv_path_mkdir=${TOOLS_PATH.mkdir}
# If the build sandbox doesn't have /dev/shm mounted, don't produce
# broken packages.
CONFIGURE_ENV.Linux+= ac_cv_posix_semaphores_enabled=yes
PKGCONFIG_OVERRIDE+= Misc/python.pc.in
PTHREAD_OPTS+= require

View file

@ -1,4 +1,4 @@
# $NetBSD: Makefile,v 1.14 2020/11/17 19:33:14 sjmulder Exp $
# $NetBSD: Makefile,v 1.15 2020/12/06 11:11:32 nia Exp $
.include "dist.mk"
@ -30,6 +30,9 @@ CONFIGURE_ARGS+= --with-system-ffi
CONFIGURE_ARGS+= --without-ensurepip
CONFIGURE_ENV+= OPT=${CFLAGS:M*:Q}
CONFIGURE_ENV+= ac_cv_path_mkdir=${TOOLS_PATH.mkdir}
# If the build sandbox doesn't have /dev/shm mounted, don't produce
# broken packages.
CONFIGURE_ENV.Linux+= ac_cv_posix_semaphores_enabled=yes
PKGCONFIG_OVERRIDE+= Misc/python.pc.in Misc/python-embed.pc.in
PTHREAD_OPTS+= require

View file

@ -1,4 +1,4 @@
# $NetBSD: Makefile,v 1.2 2020/11/13 21:22:35 sjmulder Exp $
# $NetBSD: Makefile,v 1.3 2020/12/06 11:11:32 nia Exp $
.include "dist.mk"
@ -30,6 +30,9 @@ CONFIGURE_ARGS+= --with-system-ffi
CONFIGURE_ARGS+= --without-ensurepip
CONFIGURE_ENV+= OPT=${CFLAGS:M*:Q}
CONFIGURE_ENV+= ac_cv_path_mkdir=${TOOLS_PATH.mkdir}
# If the build sandbox doesn't have /dev/shm mounted, don't produce
# broken packages.
CONFIGURE_ENV.Linux+= ac_cv_posix_semaphores_enabled=yes
PKGCONFIG_OVERRIDE+= Misc/python.pc.in Misc/python-embed.pc.in
PTHREAD_OPTS+= require