Skip to content

Commit 0ca003b

Browse files
author
Eric Jennings
committed
Merge pull request #6 from linagee/master
Update install-avr-gcc.sh attempt 2
2 parents a8060af + c293837 commit 0ca003b

File tree

1 file changed

+7
-3
lines changed

1 file changed

+7
-3
lines changed

install-avr-gcc.sh

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@ NONGNU_MIRROR="http://savannah.nongnu.org/download"
5656
BINUTILS=binutils-2.23.2
5757
BINUTILS_PACKAGE=${BINUTILS}.tar.gz
5858
BINUTILS_DOWNLOAD=${GNU_MIRROR}/binutils/${BINUTILS_PACKAGE}
59-
BINUTILS_CHECKSUM="ed58f50d8920c3f1d9cb110d5c972c27"
59+
BINUTILS_CHECKSUM="cda9dcc08c86ff2fd3f27e4adb250f6f"
6060
BINUTILS_INSTALL=n
6161

6262
GMP=gmp-5.0.5
@@ -89,7 +89,7 @@ GDB_DOWNLOAD=${GNU_MIRROR}/gdb/${GDB_PACKAGE}
8989
GDB_CHECKSUM="24a6779a9fe0260667710de1b082ef61"
9090
GDB_INSTALL=n
9191

92-
AVRLIBC=avr-libc-trunk
92+
AVRLIBC=avr-libc-1.8.0
9393
AVRLIBC_PACKAGE=${AVRLIBC}.tar.bz2
9494
AVRLIBC_DOWNLOAD=${NONGNU_MIRROR}/avr-libc/${AVRLIBC_PACKAGE}
9595
AVRLIBC_CHECKSUM="54c71798f24c96bab206be098062344f"
@@ -260,7 +260,11 @@ download_and_check() {
260260
fi
261261

262262
echo "Verifying md5 of ${ARCHIVES}/${1}... "
263-
MD5=`md5 -r ${ARCHIVES}/$1 | awk '{print $1}'`
263+
if builtin command -v md5 > /dev/null ; then
264+
MD5=`md5 -r ${ARCHIVES}/$1 | awk '{print $1}'`
265+
else
266+
MD5=`md5sum ${ARCHIVES}/$1 | awk '{print $1}'`
267+
fi
264268
if [ "$MD5" != "$3" ]
265269
then
266270
echo "Error: ${1} corrupted!" >&2

0 commit comments

Comments
 (0)