[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]
[minion-cvs] Look for thread-enabled pythons on NetBSD
Update of /home/minion/cvsroot/src/minion
In directory moria.mit.edu:/tmp/cvs-serv7764
Modified Files:
Makefile
Log Message:
Look for thread-enabled pythons on NetBSD
Index: Makefile
===================================================================
RCS file: /home/minion/cvsroot/src/minion/Makefile,v
retrieving revision 1.68
retrieving revision 1.69
diff -u -d -r1.68 -r1.69
--- Makefile 19 Mar 2004 06:18:46 -0000 1.68
+++ Makefile 2 May 2004 18:39:26 -0000 1.69
@@ -12,8 +12,13 @@
# XXXX This fails when PYTHON is set to a version of Python earlier than 1.3
-PYTHON_CANDIDATES = python python2.3 python2.3x python2.2 python2.2x python2.1\
- python2.1x python2.0 python2.0x python2
+PYTHON_CANDIDATES = python \
+ python2p3 python2.3 python2.3x \
+ python2p2 python2.2 python2.2x \
+ python2p1 python2.1 python2.1x \
+ python2.0 python2.0x \
+ python2
+
FINDPYTHON = \
if [ "x`which which`" = "x" ]; then \
echo "Ouch! I couldn't run 'which' on your system."; \
@@ -25,13 +30,19 @@
if [ 'x' = "x$$PYTHON" ]; then \
if [ -x "`which $$n 2>&1`" ]; then \
if [ 'x' != "`$$n -V 2>&1 | grep 'Python [23456789]'`x" ]; then\
- PYTHON=$$n; \
- fi; \
+ if [ '1' != "`$$n -c 'import thread; print 1'`" ]; then \
+ echo "Skipping $$n; no thread support."; \
+ else \
+ PYTHON=$$n; \
+ fi \
+ else \
+ echo "Skipping `which $$n`; Not recent enough."; \
+ fi; \
fi; \
fi; \
done; \
if [ 'x' = "x$$PYTHON" ]; then \
- echo "ERROR: couldn't find Python 2 or later on PATH as any of ";\
+ echo "ERROR: couldn't find Python 2 or later (with threads) on PATH as any of ";\
echo " $(PYTHON_CANDIDATES) in PATH"; \
echo " Please install python in your path, or set the PYTHON"; \
echo ' environment variable'; \