don't hardcode python path
authorBjörn Jacke <bj@sernet.de>
Thu, 26 Feb 2009 15:32:57 +0000 (16:32 +0100)
committerMichael Adam <obnox@samba.org>
Thu, 26 Feb 2009 20:28:53 +0000 (21:28 +0100)
Signed-off-by: Michael Adam <obnox@samba.org>
source4/selftest/tests.sh

index 36e3bbe364ce206eb98298c1d6fa4467081733f1..99e530ec3853de79ab6d5bc57f684a5d227060e1 100755 (executable)
@@ -23,6 +23,11 @@ then
        PERL=perl
 fi
 
        PERL=perl
 fi
 
+if [ ! -n "$PYTHON" ]
+then
+       PYTHON=python
+fi
+
 plantest() {
        name=$1
        env=$2
 plantest() {
        name=$1
        env=$2
@@ -394,7 +399,6 @@ then
        plantest "nss.test using winbind" member $VALGRIND $nsstest4 $samba4bindir/shared/libnss_winbind.so
 fi
 
        plantest "nss.test using winbind" member $VALGRIND $nsstest4 $samba4bindir/shared/libnss_winbind.so
 fi
 
-PYTHON=/usr/bin/python
 SUBUNITRUN="$VALGRIND $PYTHON $samba4srcdir/scripting/bin/subunitrun"
 plantest "ldb.python" none PYTHONPATH="$PYTHONPATH:$samba4srcdir/lib/ldb/tests/python/" $SUBUNITRUN api
 plantest "credentials.python" none PYTHONPATH="$PYTHONPATH:$samba4srcdir/auth/credentials/tests" $SUBUNITRUN bindings
 SUBUNITRUN="$VALGRIND $PYTHON $samba4srcdir/scripting/bin/subunitrun"
 plantest "ldb.python" none PYTHONPATH="$PYTHONPATH:$samba4srcdir/lib/ldb/tests/python/" $SUBUNITRUN api
 plantest "credentials.python" none PYTHONPATH="$PYTHONPATH:$samba4srcdir/auth/credentials/tests" $SUBUNITRUN bindings