aboutsummaryrefslogtreecommitdiffstats
path: root/tools/check/check_python
diff options
context:
space:
mode:
authorKeir Fraser <keir.fraser@citrix.com>2008-01-22 09:44:17 +0000
committerKeir Fraser <keir.fraser@citrix.com>2008-01-22 09:44:17 +0000
commitb7d7bde93532745ac21f2a09b7f926533f104861 (patch)
treece340c915fbe6b23694eed63d675db647064290d /tools/check/check_python
parent036e6bd11be95e3e78d2316b0cf0847740b539bc (diff)
downloadxen-b7d7bde93532745ac21f2a09b7f926533f104861.tar.gz
xen-b7d7bde93532745ac21f2a09b7f926533f104861.tar.bz2
xen-b7d7bde93532745ac21f2a09b7f926533f104861.zip
Make tools/check scripts cross-friendly
This patch introduces tools/check/funcs.sh with some cross-friendly abstractions, then modifies the check_* scripts to use them. Signed-off-by: Aron Griffis <aron@hp.com>
Diffstat (limited to 'tools/check/check_python')
-rwxr-xr-xtools/check/check_python11
1 files changed, 2 insertions, 9 deletions
diff --git a/tools/check/check_python b/tools/check/check_python
index 6d665ea4b2..feeb6fc5b0 100755
--- a/tools/check/check_python
+++ b/tools/check/check_python
@@ -1,16 +1,9 @@
#!/bin/sh
# CHECK-BUILD CHECK-INSTALL
-RC=0
+. funcs.sh
python -c '
import sys
sys.exit(sys.version_info[0] < 2 or sys.version_info[1] < 2)
-' || RC=1
-
-if test ${RC} -ne 0; then
- echo
- echo " *** Check for Python version >= 2.2 FAILED"
-fi
-
-exit ${RC}
+' || fail "need python version >= 2.2"