Permalink
Switch branches/tags
Nothing to show
Find file
Fetching contributors…
Cannot retrieve contributors at this time
executable file 76 lines (68 sloc) 1.49 KB
#!/bin/bash
BASEDIR=`pwd`
LOGFILEHOST=$BASEDIR/tools.log
LOGFILE=$BASEDIR/software.log
echo "================================================================================"
echo "Building Milkymist demo firmware"
echo ""
echo "Log file (host): $LOGFILEHOST"
echo "Log file (target): $LOGFILE"
echo "================================================================================"
echo ""
BASEDIR=`pwd`
echo -n "Building host utilities..."
cd $BASEDIR/tools
echo >> $LOGFILEHOST
date >> $LOGFILEHOST
make >> $LOGFILEHOST 2>&1
if [ "$?" != 0 ] ; then
echo "FAILED"
exit 1
else
echo "OK"
fi
echo "Building embedded software:"
echo -n " Base library..."
echo >> $LOGFILE
date >> $LOGFILE
cd $BASEDIR/software/libbase && make >> $LOGFILE 2>&1
if [ "$?" != 0 ] ; then
echo "FAILED"
exit 1
else
echo "OK"
fi
echo -n " Math library..."
cd $BASEDIR/software/libmath && make >> $LOGFILE 2>&1
if [ "$?" != 0 ] ; then
echo "FAILED"
exit 1
else
echo "OK"
fi
echo -n " HAL..."
cd $BASEDIR/software/libhal && make >> $LOGFILE 2>&1
if [ "$?" != 0 ] ; then
echo "FAILED"
exit 1
else
echo "OK"
fi
echo -n " FPVM library..."
cd $BASEDIR/software/libfpvm && make >> $LOGFILE 2>&1
if [ "$?" != 0 ] ; then
echo "FAILED"
exit 1
else
echo "OK"
fi
echo -n " Demonstration firmware..."
cd $BASEDIR/software/demo && make >> $LOGFILE 2>&1
if [ "$?" != 0 ] ; then
echo "FAILED"
exit 1
else
echo "OK"
fi
cd $BASEDIR
echo "Build complete!"