Use wget when curl is not found

This commit is contained in:
Klaus Reimer 2013-05-01 13:52:17 +02:00
parent 74904be55f
commit 66048cb795

View File

@ -31,7 +31,12 @@ build()
mkdir -p "$DOWNLOADS"
if [ ! -e "$DOWNLOADS/$LIBUSB_ARCHIVE" ]
then
curl -L -o "$DOWNLOADS/$LIBUSB_ARCHIVE" "$LIBUSB_URL"
if type curl >/dev/null 2>&1
then
curl -L -o "$DOWNLOADS/$LIBUSB_ARCHIVE" "$LIBUSB_URL"
else
wget -O "$DOWNLOADS/$LIBUSB_ARCHIVE" "$LIBUSB_URL"
fi
fi
# Unpack and compile libusb