Revision f6f0b7d9
b/configure | ||
---|---|---|
1004 | 1004 |
esac |
1005 | 1005 |
done |
1006 | 1006 |
|
1007 |
if ! has $python; then |
|
1008 |
error_exit "Python not found. Use --python=/path/to/python" |
|
1009 |
fi |
|
1010 |
|
|
1011 |
# Note that if the Python conditional here evaluates True we will exit |
|
1012 |
# with status 1 which is a shell 'false' value. |
|
1013 |
if ! $python -c 'import sys; sys.exit(sys.version_info < (2,4) or sys.version_info >= (3,))'; then |
|
1014 |
error_exit "Cannot use '$python', Python 2.4 or later is required." \ |
|
1015 |
"Note that Python 3 or later is not yet supported." \ |
|
1016 |
"Use --python=/path/to/python to specify a supported Python." |
|
1017 |
fi |
|
1018 |
|
|
1019 |
# The -B switch was added in Python 2.6. |
|
1020 |
# If it is supplied, compiled files are not written. |
|
1021 |
# Use it for Python versions which support it. |
|
1022 |
if $python -B -c 'import sys; sys.exit(0)' 2>/dev/null; then |
|
1023 |
python="$python -B" |
|
1024 |
fi |
|
1025 |
|
|
1007 | 1026 |
case "$cpu" in |
1008 | 1027 |
ppc) |
1009 | 1028 |
CPU_CFLAGS="-m32" |
... | ... | |
1419 | 1438 |
fi |
1420 | 1439 |
fi |
1421 | 1440 |
|
1422 |
if ! has $python; then |
|
1423 |
error_exit "Python not found. Use --python=/path/to/python" |
|
1424 |
fi |
|
1425 |
|
|
1426 |
# Note that if the Python conditional here evaluates True we will exit |
|
1427 |
# with status 1 which is a shell 'false' value. |
|
1428 |
if ! $python -c 'import sys; sys.exit(sys.version_info < (2,4) or sys.version_info >= (3,))'; then |
|
1429 |
error_exit "Cannot use '$python', Python 2.4 or later is required." \ |
|
1430 |
"Note that Python 3 or later is not yet supported." \ |
|
1431 |
"Use --python=/path/to/python to specify a supported Python." |
|
1432 |
fi |
|
1433 |
|
|
1434 |
# The -B switch was added in Python 2.6. |
|
1435 |
# If it is supplied, compiled files are not written. |
|
1436 |
# Use it for Python versions which support it. |
|
1437 |
if $python -B -c 'import sys; sys.exit(0)' 2>/dev/null; then |
|
1438 |
python="$python -B" |
|
1439 |
fi |
|
1440 |
|
|
1441 | 1441 |
if test -z "${target_list+xxx}" ; then |
1442 | 1442 |
target_list="$default_target_list" |
1443 | 1443 |
else |
Also available in: Unified diff