3 test -x ash ||
{ echo "No ./ash?!"; exit; }
4 test -x printenv || gcc
-O2 -o printenv printenv.c ||
exit $?
5 test -x recho || gcc
-O2 -o recho recho.c ||
exit $?
6 test -x zecho || gcc
-O2 -o zecho zecho.c ||
exit $?
8 PATH
="$PWD:$PATH" # for ash and recho/zecho/printenv
16 test -d "$1" ||
return 0
18 cd "$1" ||
{ echo "cannot cd $1!"; exit 1; }
20 test -f "$x" ||
continue
22 "$0"|run-minimal|run-gprof
) ;;
24 #*) echo $x ; sh $x ;;
26 sh
"$x" >"../$1-$x.fail" 2>&1 && \
27 { echo "$1/$x: ok"; rm "../$1-$x.fail"; } ||
echo "$1/$x: fail";
31 # Many bash run-XXX scripts just do this,
32 # no point in duplication it all over the place
34 test -x "$x" ||
continue
36 test -f "$name.right" ||
continue
38 "$THIS_SH" "./$x" >"$name.xx" 2>&1
39 diff -u "$name.xx" "$name.right" >"../$1-$x.fail" && rm -f "$name.xx" "../$1-$x.fail"
40 } && echo "$1/$x: ok" ||
echo "$1/$x: fail"
45 # main part of this script
46 # Usage: run-all [directories]
52 for module
in $modules; do
56 while [ $# -ge 1 ]; do