From owner-freebsd-python@FreeBSD.ORG Thu Mar 12 11:02:03 2009 Return-Path: <owner-freebsd-python@FreeBSD.ORG> Delivered-To: python@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 2ACE9106566B for <python@FreeBSD.org>; Thu, 12 Mar 2009 11:02:03 +0000 (UTC) (envelope-from bms@incunabulum.net) Received: from out1.smtp.messagingengine.com (out1.smtp.messagingengine.com [66.111.4.25]) by mx1.freebsd.org (Postfix) with ESMTP id F3A808FC15 for <python@FreeBSD.org>; Thu, 12 Mar 2009 11:02:02 +0000 (UTC) (envelope-from bms@incunabulum.net) Received: from compute1.internal (compute1.internal [10.202.2.41]) by out1.messagingengine.com (Postfix) with ESMTP id 4E6752EDD87 for <python@FreeBSD.org>; Thu, 12 Mar 2009 06:45:46 -0400 (EDT) Received: from heartbeat1.messagingengine.com ([10.202.2.160]) by compute1.internal (MEProxy); Thu, 12 Mar 2009 06:45:46 -0400 X-Sasl-enc: Q1XlEj2BTfESLoh9oOGYMLGLqTnOiHTCOCc3BxInLQ8g 1236854746 Received: from anglepoise.lon.incunabulum.net (82-35-112-254.cable.ubr07.dals.blueyonder.co.uk [82.35.112.254]) by mail.messagingengine.com (Postfix) with ESMTPSA id DF5D218483 for <python@FreeBSD.org>; Thu, 12 Mar 2009 06:45:45 -0400 (EDT) Message-ID: <49B8E7D8.3010606@incunabulum.net> Date: Thu, 12 Mar 2009 10:45:44 +0000 From: Bruce Simpson <bms@incunabulum.net> User-Agent: Thunderbird 2.0.0.19 (X11/20090125) MIME-Version: 1.0 To: python@FreeBSD.org Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Cc: Subject: Regarding HAVE_BROKEN_POSIX_SEMAPHORES X-BeenThere: freebsd-python@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: FreeBSD-specific Python issues <freebsd-python.freebsd.org> List-Unsubscribe: <http://lists.freebsd.org/mailman/listinfo/freebsd-python>, <mailto:freebsd-python-request@freebsd.org?subject=unsubscribe> List-Archive: <http://lists.freebsd.org/pipermail/freebsd-python> List-Post: <mailto:freebsd-python@freebsd.org> List-Help: <mailto:freebsd-python-request@freebsd.org?subject=help> List-Subscribe: <http://lists.freebsd.org/mailman/listinfo/freebsd-python>, <mailto:freebsd-python-request@freebsd.org?subject=subscribe> X-List-Received-Date: Thu, 12 Mar 2009 11:02:04 -0000 Hi, If any of you can find the time, could you try applying rev 189736 of uipc_sem.c and patching Python to be built *without* defining HAVE_BROKEN_POSIX_SEMAPHORES in ${WRKSRC}/Python/thread_pthread.h ? Please see the PR for a one-liner patch: http://www.freebsd.org/cgi/query-pr.cgi?pr=kern/127545 As you are probably aware, Python will try to emulate semaphores by using condition variables when USE_SEMAPHORES is not defined. I believe this commit fixes the issue. It must have crept in when timed waits were implemented. cheers BMS P.S. Help to debug 'multiprocessing' in Python 2.6 on FreeBSD would be very, very appreciated... I think I've traced it back to problems with the thread library -- specifically, fork()-ing from a thread seems to be broken.