get-scripts annotate speedtouch-firmware @ rev 41

list CATEGORY, VERSION, LICENSE (again)
author Pascal Bellard <pascal.bellard@slitaz.org>
date Sun May 03 11:41:50 2015 +0200 (2015-05-03)
parents 552ec1a3614c
children 2cdf3e534506
rev   line source
pascal@34 1 SHORT_DESC="Firmware for SpeedTouch ADSL Modem."
pascal@34 2 WEB_SITE="http://www.linux-usb.org/SpeedTouch/"
pascal@34 3 # end of get.list data
pascal@9 4 DEPENDS=""
pascal@9 5
pascal@9 6 VERSION="3.012"
pascal@9 7 mkdir -p $PACKAGE-$VERSION/fs/lib/firmware
pascal@9 8 TARBALL="SpeedTouch330_firmware_$(echo $VERSION | sed 's/\.//').zip"
pascal@9 9 #http://speedtouch.hysplace.co.uk/firmware.htm
pascal@29 10 #WGET_URL="http://www.speedtouch.com/download/drivers/USB/$TARBALL"
pascal@9 11 #from http://www.filewatcher.com/m/SpeedTouch330_firmware_3012.zip.769125-0.html
pascal@29 12 WGET_URL="ftp://ftp.netbsd.org/pub/pkgsrc/distfiles/$TARBALL"
pascal@29 13 wget $WGET_URL
pascal@9 14 [ $TARBALL ] || abort_package "Could not download $TARBALL. Exiting."
pascal@29 15 unzip -n $(basename $WGET_URL)
pascal@9 16 wget http://www.linux-usb.org/SpeedTouch/firmware/firmware-extractor.tar.gz
pascal@9 17 tar xzf firmware-extractor.tar.gz
pascal@9 18 cd firmware-extractor/
pascal@9 19 which gcc || tazpkg get-install gcc
pascal@9 20 gcc -o firmware-extractor firmware.c
pascal@9 21 FIRMWARE="ZZZL_$VERSION"
pascal@9 22 [ "$PACKAGE" = "speedtouch-firmware" ] && FIRMWARE="KQD6_$VERSION"
pascal@9 23 cp ../$FIRMWARE mgmt.o
pascal@9 24 ./firmware-extractor mgmt.o
pascal@9 25 install -m 600 speedtch-1.bin speedtch-2.bin \
pascal@9 26 ../$PACKAGE-$VERSION/fs/lib/firmware
pascal@9 27 cd ..
pascal@9 28 set +e