2010-03-07 05:52:19 +03:00
#!/bin/bash
2010-04-19 07:42:53 +04:00
set -e
set -x
2010-03-07 05:52:19 +03:00
d = $( dirname $0 )
cd $d /..
PREFIX = $HOME /testprefix
2010-03-28 08:39:16 +04:00
if [ $# -gt 0 ] ; then
tests = " $* "
else
tests = "lib/replace lib/talloc lib/tevent lib/tdb source4/lib/ldb"
fi
echo " testing in dirs $tests "
for d in $tests ; do
2010-03-07 05:52:19 +03:00
echo " `date`: testing $d "
2010-04-19 07:42:53 +04:00
pushd $d
2010-03-07 05:52:19 +03:00
rm -rf bin
type waf
2010-04-19 07:42:53 +04:00
waf dist
waf configure -C --enable-developer --prefix= $PREFIX
time waf build
time waf build
waf install
waf distcheck
2010-03-28 08:39:16 +04:00
case $d in
"source4/lib/ldb" )
2010-04-19 07:42:53 +04:00
ldd bin/ldbadd
2010-03-28 08:39:16 +04:00
; ;
"lib/replace" )
2010-04-19 07:42:53 +04:00
ldd bin/replace_testsuite
2010-03-28 08:39:16 +04:00
; ;
"lib/talloc" )
2010-04-19 07:42:53 +04:00
ldd bin/talloc_testsuite
2010-03-28 08:39:16 +04:00
; ;
"lib/tdb" )
2010-04-19 07:42:53 +04:00
ldd bin/tdbtool
2010-03-28 08:39:16 +04:00
; ;
esac
2010-03-07 05:52:19 +03:00
popd
done
2010-04-19 07:42:53 +04:00
echo "testing python portability"
pushd lib/talloc
2010-05-04 13:58:28 +04:00
versions = "python2.4 python2.5 python2.6 python3.0 python3.1"
2010-04-19 07:42:53 +04:00
for p in $versions ; do
echo " Testing $p "
$p ../../buildtools/bin/waf configure -C --enable-developer --prefix= $PREFIX
$p ../../buildtools/bin/waf build install
done
popd
echo "testing cross compiling"
pushd lib/talloc
2010-04-21 09:36:26 +04:00
CC = arm-linux-gnueabi-gcc ./configure -C --prefix= $PREFIX --cross-compile --cross-execute= 'runarm'
2010-04-19 07:42:53 +04:00
make && make install
popd