ports/161591: [patch] audio/xmms2: workaround deadlock in waf (showing up on pointyhat too)
Guido Falsi
mad at madpilot.net
Fri Oct 14 17:20:08 UTC 2011
>Number: 161591
>Category: ports
>Synopsis: [patch] audio/xmms2: workaround deadlock in waf (showing up on pointyhat too)
>Confidential: no
>Severity: non-critical
>Priority: low
>Responsible: freebsd-ports-bugs
>State: open
>Quarter:
>Keywords:
>Date-Required:
>Class: change-request
>Submitter-Id: current-users
>Arrival-Date: Fri Oct 14 17:20:07 UTC 2011
>Closed-Date:
>Last-Modified:
>Originator: Guido Falsi
>Release: FreeBSD 8.2-STABLE amd64
>Organization:
none
>Environment:
System: FreeBSD megatron.madpilot.net 8.2-STABLE FreeBSD 8.2-STABLE #2: Sun Aug 7 19:54:54 CEST 2011 root at megatron.madpilot.net:/usr/obj/usr/src/sys/MEGATRON amd64
>Description:
This port was disabled on pointyhat due to runaway processes. I
tracked this down to a deadlock condition in some python multithreaded
code.
I "fixed" this by adding a small sleep (0.02 seconds, should not
slow down the build noticeabily). I'm aware this is not a proper
fix for a deadlock, and just makes it less probable. I'm not
experienced with multitheaded programming and have very superficial
knowledge of python, so could not find a better fix.
Please note that while this makes the deadlock condition not show
up on my machines I can't be sure it fixes the problem on pointyhat
until tested. I hope it does though.
added file:
files/patch-wafadmin-Task.py
>How-To-Repeat:
Trying to make the audio/xmms2 port on any 9.0-BETA machine. I only
tested this on SMP machines, maybe on single core machines this is
not going to show up.
>Fix:
diff -ruN xmms2.old/Makefile xmms2/Makefile
--- xmms2.old/Makefile 2011-10-14 17:10:46.792667942 +0200
+++ xmms2/Makefile 2011-10-14 17:11:06.081664680 +0200
@@ -63,10 +63,6 @@
.include <bsd.port.pre.mk>
-.if defined(PACKAGE_BUILDING)
-BROKEN= fails to build on pointyhat: runaway process
-.endif
-
.if defined(XMMS2_SLAVE)
EXCLUDE+= --without-xmms2d
diff -ruN xmms2.old/files/patch-wafadmin-Task.py xmms2/files/patch-wafadmin-Task.py
--- xmms2.old/files/patch-wafadmin-Task.py 1970-01-01 01:00:00.000000000 +0100
+++ xmms2/files/patch-wafadmin-Task.py 2011-10-14 17:11:05.857663308 +0200
@@ -0,0 +1,18 @@
+--- wafadmin/Task.py.orig 2010-02-19 18:43:54.000000000 +0100
++++ wafadmin/Task.py 2011-10-14 14:36:57.000663231 +0200
+@@ -47,6 +47,7 @@
+ import Build, Runner, Utils, Node, Logs, Options
+ from Logs import debug, warn, error
+ from Constants import *
++import time
+
+ algotype = NORMAL
+ #algotype = JOBCONTROL
+@@ -406,6 +407,7 @@
+ def call_run(self):
+ if self.can_retrieve_cache():
+ return 0
++ time.sleep(0.02)
+ return self.run()
+
+ def run(self):
>Release-Note:
>Audit-Trail:
>Unformatted:
More information about the freebsd-ports-bugs
mailing list