build: enable nothreads workaround only with WAF_NOTHREADS=1
authorAndrew Tridgell <tridge@samba.org>
Thu, 1 Apr 2010 06:24:02 +0000 (17:24 +1100)
committerAndrew Tridgell <tridge@samba.org>
Tue, 6 Apr 2010 10:27:21 +0000 (20:27 +1000)
buildtools/wafsamba/nothreads.py
buildtools/wafsamba/wafsamba.py

index d227ce1a973f451c03e9f721d6f175f3ec3874ed..9054a57af5b91fd0bc50c9ab986834f9dee1d915 100644 (file)
@@ -213,8 +213,7 @@ class Parallel(object):
                assert (self.count == 0 or self.stop)
 
 
-# enable nothreads if -j1 is used from the makefile
-if os.environ.get('JOBS') == '1':
-       import Runner
-       Runner.process = process
-       Runner.Parallel = Parallel
+# enable nothreads
+import Runner
+Runner.process = process
+Runner.Parallel = Parallel
index 5a48cb4ba1bf8d7bae2fead0c7e074b5a605e6ea..a7258d3e9efb2ffd2fa1ce8019005dbf1cf89a3f 100644 (file)
@@ -19,7 +19,10 @@ from samba_python import *
 from samba_deps import *
 from samba_bundled import *
 import samba_conftests
-import nothreads
+
+# some systems have broken threading in python
+if os.environ.get('WAF_NOTHREADS') == '1':
+    import nothreads
 
 LIB_PATH="shared"