summaryrefslogtreecommitdiff
path: root/util
diff options
context:
space:
mode:
authorZheng Bao <fishbaozi@gmail.com>2013-12-09 14:09:07 +0800
committerPatrick Georgi <patrick@georgi-clan.de>2013-12-09 11:14:24 +0100
commit691b313c2807a5e9d293e9a520f951ea1319bb8f (patch)
tree5b299382d6bd4f18f0184f248828c8a0192bd329 /util
parent19803e7cb04b6b411f3c8e58c69cbf12c7fc07b9 (diff)
crossgcc: Continue to unpack archive if it was incomplete
If the unpacking was interrupt by Ctrl-C, probably part of an archive is unpacked. If we run buildgcc again, the incomplete folder would be and skipped. We can create a file to tell the script the unpacking is done. Change-Id: Id9eb74d119e22b62c70dca9b38a92c3dbdf0f64c Signed-off-by: Zheng Bao <zheng.bao@amd.com> Signed-off-by: Zheng Bao <fishbaozi@gmail.com> Reviewed-on: http://review.coreboot.org/4512 Tested-by: build bot (Jenkins) Reviewed-by: Patrick Georgi <patrick@georgi-clan.de>
Diffstat (limited to 'util')
-rwxr-xr-xutil/crossgcc/buildgcc3
1 files changed, 2 insertions, 1 deletions
diff --git a/util/crossgcc/buildgcc b/util/crossgcc/buildgcc
index 3754837005..c668ad2a36 100755
--- a/util/crossgcc/buildgcc
+++ b/util/crossgcc/buildgcc
@@ -286,7 +286,7 @@ for PACKAGE in GMP MPFR MPC LIBELF GCC BINUTILS $PYTHON_PACKAGE \
archive="`eval echo '$'$archive`"
dir=$PACKAGE"_DIR"
dir="`eval echo '$'${dir}`"
- test -d ${dir} || (
+ test -d ${dir} && test -f ${dir}/.unpack_sucess || (
printf " * `basename $archive`\n"
FLAGS=zxf
suffix=`echo $archive | sed 's,.*\.,,'`
@@ -300,6 +300,7 @@ for PACKAGE in GMP MPFR MPC LIBELF GCC BINUTILS $PYTHON_PACKAGE \
$PATCH -s -N -p0 < `echo $patch` || \
printf "\n${RED}Failed $patch.${NC}\n"
done
+ touch ${dir}/.unpack_success
)
done
printf "Unpacked and patched ... "