From 074bc6c09aadcc78ea300c578734a69f56decfab Mon Sep 17 00:00:00 2001 From: Thomas Martitz Date: Tue, 24 Feb 2009 20:53:04 +0000 Subject: Rearrange a bit, so that it checks for the build dir after downloading, makes it a bit more obvious that redownloading isn't needed, but only deletion of the build dir. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@20099 a1c6a512-1295-4272-9138-f99709370657 --- tools/rockboxdev.sh | 22 ++++++++++++---------- 1 file changed, 12 insertions(+), 10 deletions(-) diff --git a/tools/rockboxdev.sh b/tools/rockboxdev.sh index e3e9a0cbb4..d322ef1a50 100755 --- a/tools/rockboxdev.sh +++ b/tools/rockboxdev.sh @@ -131,13 +131,6 @@ if test ! -w $prefix; then fi -########################################################################### -# If there's already a build dir, we don't overwrite it -if test -d $builddir; then - echo "You already have a $builddir directory!" - echo "Please remove it and re-run the script" - exit -fi cleardir () { # $1 is the name of the build dir @@ -213,9 +206,6 @@ else pathadd="$bindir" fi -mkdir -p $builddir -cd $builddir - summary="summary-$1" echo "============================ Summary ============================" > $summary @@ -262,6 +252,18 @@ if test -n "$gccpatch"; then fi fi +########################################################################### +# If there's already a build dir, we don't overwrite it +if test -d $builddir; then + echo "You already have a $builddir directory!" + echo "Please remove it and re-run the script" + exit +else + mkdir -p $builddir + cd $builddir +fi + + echo "ROCKBOXDEV: extracting binutils-$binutils in $builddir" tar xjf $dlwhere/binutils-$binutils.tar.bz2 echo "ROCKBOXDEV: extracting gcc-$gccver in $builddir" -- cgit v1.2.3