blob: 63ba298891f0f705f5dad304d3c3b67fc86e49a8 [file] [log] [blame]
#!/bin/sh
# build everything in the projects directory
PROJECTS=`echo project/*.mk | xargs -n1 basename | sed 's/\.mk//'`
FAILED=""
case `uname` in
Linux)
N=`cat /proc/cpuinfo | grep processor | wc -l`
PARALLEL=-j`expr $N + $N`
;;
*)
PARALLEL=-j4
;;
esac
for p in $PROJECTS; do
PROJECT=$p nice make $PARALLEL || FAILED="$FAILED $p"
done
if [ "$FAILED" != "" ]; then
echo
echo some projects have failed to build:
echo $FAILED
fi