[coreboot-gerrit] Patch set updated for coreboot: 49f739d crossgcc: Re-download the archive if it is incomplete
Zheng Bao (zheng.bao@amd.com)
gerrit at coreboot.org
Mon Dec 9 07:28:01 CET 2013
Zheng Bao (zheng.bao at amd.com) just uploaded a new patch set to gerrit, which you can find at http://review.coreboot.org/4511
-gerrit
commit 49f739d2be72bf0fd34aa13f692c010970c5ee20
Author: Zheng Bao <fishbaozi at gmail.com>
Date: Mon Dec 9 13:55:53 2013 +0800
crossgcc: Re-download the archive if it is incomplete
If the buildgcc is interrupt by Ctrl-C, probably part of
an archive is downloaded. If we run buildgcc again, the
incomplete archive would be considered as cached file
and skipped.
We need to test the archive by option -t or tar. If test
is failed, we need to delete the partially-downloaded file
and download it again.
Discuss: Do we need to use option -c of wget to continue
downloading?
Change-Id: Ibb1aa25a0374f774e1e643fe5e698de7bf7cc418
Signed-off-by: Zheng Bao <zheng.bao at amd.com>
Signed-off-by: Zheng Bao <fishbaozi at gmail.com>
---
util/crossgcc/buildgcc | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/util/crossgcc/buildgcc b/util/crossgcc/buildgcc
index 3754837..ae4e06f 100755
--- a/util/crossgcc/buildgcc
+++ b/util/crossgcc/buildgcc
@@ -266,8 +266,9 @@ for ARCHIVE in $GMP_ARCHIVE $MPFR_ARCHIVE $MPC_ARCHIVE $LIBELF_ARCHIVE \
$IASL_ARCHIVE $PYTHON_ARCHIVE $EXPAT_ARCHIVE; do
FILE=`basename $ARCHIVE`
printf " * $FILE "
- test -f tarballs/$FILE && printf "(cached)" || (
+ test -f tarballs/$FILE && $TAR tf tarballs/$FILE >/dev/null 2>/dev/null && printf "(cached)" || (
printf "(downloading)"
+ rm -f tarballs/$FILE
cd tarballs
wget --no-check-certificate -q $ARCHIVE
)
More information about the coreboot-gerrit
mailing list