Subversion Repositories HelenOS-historic

Compare Revisions

Ignore whitespace Rev 454 → Rev 455

/SPARTAN/trunk/build.ia32
1,17 → 1,34
#! /bin/sh
 
COMPILER=""
function syntax {
echo "Syntax:"
echo " build.<arch> [-compiler <compiler>] [-cpu <cpu>]"
echo
echo "<arch> ... amd64, *ia32, ia64, mips32, ppc32, sparc64"
echo "<compiler> ... native, *cross"
echo "<cpu> ... for ia32: athlon-xp, athlon-mp, pentium3, *pentium4"
echo
}
 
ARCH="`basename "$0" | awk -F. '{ if (NF > 1) print \$NF }'`"
if [ -z "$ARCH" ]; then
syntax
exit 1
fi
 
ARGS=""
while [ "$#" -gt 0 ]; do
case "$1" in
native)
COMPILER="$COMPILER NATIVE_COMPILER=yes"
-compiler)
ARGS="$ARGS COMPILER=$2"
shift
;;
strong)
COMPILER="$COMPILER STRONG_ORDERING=yes"
-cpu)
ARGS="$ARGS CPU=$2"
shift
;;
*)
echo "Supported arguments: native strong"
syntax
exit 1
;;
esac
18,6 → 35,4
shift
done
 
make all ARCH=ia32 $COMPILER
( cd uspace/libc && make all ARCH=ia32 $COMPILER )
( cd uspace && make all ARCH=ia32 $COMPILER )
make all "ARCH=$ARCH" $ARGS