changeset 1558:651690fe6be3

fix run-tests' PYTHONPATH Specify the installation directory for python modules so we can set PYTHONPATH without guessing.
author Robin Farine <robin.farine@terminus.org>
date Sun, 27 Nov 2005 16:37:18 +0100
parents f7d9823e65df
children 6efad1cc07de
files tests/run-tests
diffstat 1 files changed, 4 insertions(+), 10 deletions(-) [+]
line wrap: on
line diff
--- a/tests/run-tests	Wed Nov 23 18:36:44 2005 +0100
+++ b/tests/run-tests	Sun Nov 27 16:37:18 2005 +0100
@@ -40,16 +40,11 @@
 }
 
 TESTDIR="$PWD"
-
-if [ -d /usr/lib64 ]; then
-    lib=lib64
-else
-    lib=lib
-fi
-
 INST="$HGTMP/install"
+PYTHONDIR="$INST/lib/python"
 cd ..
-if ${PYTHON-python} setup.py install --home="$INST" > tests/install.err 2>&1
+if ${PYTHON-python} setup.py install --home="$INST" \
+  --install-lib="$PYTHONDIR" > tests/install.err 2>&1
 then
     rm tests/install.err
 else
@@ -59,8 +54,7 @@
 cd "$TESTDIR"
 
 PATH="$INST/bin:$PATH"; export PATH
-PYTHONPATH="$INST/$lib/python"; export PYTHONPATH
-
+PYTHONPATH="$PYTHONDIR"; export PYTHONPATH
 
 run_one() {
     rm -f "$1.err"