]> git.ipfire.org Git - thirdparty/valgrind.git/commitdiff
Support .tar.gz archives next to .tar.bz2 archives.
authorBart Van Assche <bvanassche@acm.org>
Fri, 4 Jul 2008 14:47:27 +0000 (14:47 +0000)
committerBart Van Assche <bvanassche@acm.org>
Fri, 4 Jul 2008 14:47:27 +0000 (14:47 +0000)
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@8359

exp-drd/scripts/download-and-build-gcc

index 4f3a48ab7d4e316142871a306952b54be1f1b23a..edefd9462794d58426ac092ec50cd2e79368a428 100755 (executable)
@@ -34,7 +34,13 @@ mkdir -p ${BUILD}     || exit $?
 cd       ${BUILD}     || exit $?
 
 if [ ! -e $DOWNLOADS/$TAR ]; then
-  ( cd $DOWNLOADS && wget -q $FSF_MIRROR/gcc/gcc-${GCC_VERSION}/$TAR )
+(
+  if cd $DOWNLOADS; then
+    wget -q $FSF_MIRROR/gcc/gcc-${GCC_VERSION}/$TAR \
+    || { wget -q -O- $FSF_MIRROR/gcc/gcc-${GCC_VERSION}/${TAR%bz2}gz \
+         | gzip -cd | bzip2 -9 >${TAR}; }
+  fi
+)
 fi
 
 if [ ! -e $SRC ]; then