improved script error checking

set syscalls dir for devkitPSP
This commit is contained in:
Dave Murphy
2005-07-08 07:33:31 +00:00
parent f9ed8756f9
commit dc235a0800
4 changed files with 61 additions and 92 deletions

View File

@@ -6,10 +6,10 @@
echo "building pspsdk ..."
cd $PSPSDK_SRCDIR
./configure
$MAKE
./configure || { echo "Error configuring pspsdk"; exit 1; }
$MAKE || { echo "Error building pspsdk"; exit 1; }
echo "installing pspsdk ..."
$MAKE install
$MAKE install || { echo "Error installing pspsdk"; exit 1; }
cd $BUILDSCRIPTDIR

View File

@@ -1,7 +1,4 @@
#!/bin/sh
#---------------------------------------------------------------------------------
# Check Parameters
#---------------------------------------------------------------------------------
prefix=$INSTALLDIR/devkitPSP
@@ -15,14 +12,19 @@ cd $target/binutils
../../$BINUTILS_SRCDIR/configure \
--prefix=$prefix --target=$target --disable-nls --disable-shared --disable-debug \
--disable-threads --with-gcc --with-gnu-as --with-gnu-ld --with-stabs \
2>&1 | tee $BUILDSCRIPTDIR/binutils_configure.log
|| { echo "Error configuring binutils"; exit 1; }
$MAKE 2>&1 | tee binutils_make.log
$MAKE install 2>&1 | tee $BUILDSCRIPTDIR/binutils_install.log
$MAKE || { echo "Error building binutils"; exit 1; }
$MAKE install || { echo "Error installing binutils"; exit 1; }
cd $BUILDSCRIPTDIR
#---------------------------------------------------------------------------------
# remove temp stuff to conserve disc space
#---------------------------------------------------------------------------------
rm -fr $target/binutils
rm -fr $BINUTILS_SRCDIR
#---------------------------------------------------------------------------------
# build and install just the c compiler
@@ -40,10 +42,10 @@ cd $target/gcc
--target=$target \
--with-newlib \
--prefix=$prefix \
2>&1 | tee $BUILDSCRIPTDIR/gcc_configure.log
|| { echo "Error configuring gcc"; exit 1; }
$MAKE all-gcc 2>&1| tee $BUILDSCRIPTDIR/gcc_make.log
$MAKE install-gcc 2>&1 | tee $BUILDSCRIPTDIR/gcc_install.log
$MAKE all-gcc || { echo "Error building gcc"; exit 1; }
$MAKE install-gcc || { echo "Error installing gcc"; exit 1; }
cd $BUILDSCRIPTDIR
@@ -57,20 +59,28 @@ mkdir etc
$BUILDSCRIPTDIR/$NEWLIB_SRCDIR/configure \
--target=$target \
--prefix=$prefix \
| tee $BUILDSCRIPTDIR/newlib_configure.log
|| { echo "Error configuring newlib"; exit 1; }
$MAKE | tee $BUILDSCRIPTDIR/newlib_make.log
$MAKE install | tee $BUILDSCRIPTDIR/newlib_install.log
$MAKE || { echo "Error building newlib"; exit 1; }
$MAKE install || { echo "Error installing newlib"; exit 1; }
cd $BUILDSCRIPTDIR
#---------------------------------------------------------------------------------
# remove temp stuff to conserve disc space
#---------------------------------------------------------------------------------
rm -fr $target/newlib
rm -fr $NEWLIB_SRCDIR
#---------------------------------------------------------------------------------
# build and install the final compiler
#---------------------------------------------------------------------------------
cd $BUILDSCRIPTDIR
cd $target/gcc
$MAKE | tee $BUILDSCRIPTDIR/gcc_final_make.log 2>&1
$MAKE install | tee $BUILDSCRIPTDIR/gcc_final_install.log 2>&1
$MAKE || { echo "Error building g++"; exit 1; }
$MAKE install || { echo "Error installing g++"; exit 1; }
cd $BUILDSCRIPTDIR