2008-09-28 17:19:02 +00:00
|
|
|
#!/bin/sh
|
|
|
|
|
2010-05-10 02:16:43 +00:00
|
|
|
test -d "$1" || { echo "'$1' is not a directory"; exit 1; }
|
|
|
|
test -x "$1/scripts/randomtest" || { echo "No scripts/randomtest in '$1'"; exit 1; }
|
|
|
|
|
|
|
|
export LIBC="uclibc"
|
2010-11-22 22:49:10 +00:00
|
|
|
export CROSS_COMPILER_PREFIX="i686-"
|
2010-05-10 02:16:43 +00:00
|
|
|
export MAKEOPTS="-j9"
|
|
|
|
|
2008-09-28 17:19:02 +00:00
|
|
|
cnt=0
|
|
|
|
fail=0
|
|
|
|
while sleep 1; do
|
2010-05-10 02:16:43 +00:00
|
|
|
echo "Passes: $cnt Failures: $fail"
|
|
|
|
dir="test.$$"
|
|
|
|
while test -e "$dir" -o -e "failed.$dir"; do
|
|
|
|
dir="test.$$.$RANDOM"
|
|
|
|
done
|
|
|
|
echo "Running randconfig test in $dir..."
|
|
|
|
if ! "$1/scripts/randomtest" "$1" "$dir" >/dev/null; then
|
|
|
|
mv -- "$dir" "failed.$dir"
|
|
|
|
echo "Failed build in: failed.$dir"
|
|
|
|
exit 1 # you may comment this out...
|
|
|
|
let fail++
|
|
|
|
else
|
|
|
|
(
|
|
|
|
cd -- "$dir/testsuite" || exit 1
|
|
|
|
echo "Running testsuite in $dir..."
|
|
|
|
SKIP_KNOWN_BUGS=1 SKIP_INTERNET_TESTS=1 ./runtest -v >runtest.log 2>&1
|
|
|
|
)
|
|
|
|
if test $? != 0; then
|
|
|
|
echo "Failed runtest in $dir"
|
|
|
|
exit 1
|
|
|
|
fi
|
|
|
|
tail -n10 -- "$dir/testsuite/runtest.log"
|
|
|
|
rm -rf -- "$dir"
|
|
|
|
fi
|
|
|
|
let cnt++
|
2008-09-28 17:19:02 +00:00
|
|
|
done
|