get-scripts annotate bitcoin @ rev 12

flash-plugin: add menu entry for flash-player-properties
author Pascal Bellard <pascal.bellard@slitaz.org>
date Tue Apr 15 14:22:26 2014 +0000 (2014-04-15)
parents 38581c20c3f1
children 6ca05e6839e1
rev   line source
pascal@0 1 WEB_SITE="http://$PACKAGE.org/"
pascal@0 2 SHORT_DESC="New digital currency for instant payments to anyone, anywhere."
pascal@0 3 MAINTAINER="somebody@$PACKAGE.org"
pascal@0 4 DEPENDS="libQtGui libQtNetwork bzlib"
pascal@7 5 LICENSE="MIT"
pascal@0 6
pascal@0 7 # Download tarball
pascal@7 8 case "$PACKAGE" in
pascal@7 9 bitcoin)
pascal@7 10 WGET_URL=$(wget --no-check-certificate -O - $WEB_SITE/en/download | sed \
pascal@7 11 '/linux.tar/!d;s/.*href="\([^"]*\).*/\1/;s|/download$||') ;;
pascal@7 12 litecoin)
pascal@7 13 WGET_URL=$(wget --no-check-certificate -O - $WEB_SITE | sed \
pascal@7 14 '/linux.tar/!d;;s/.*href="\([^"]*\).*/\1/;q') ;;
pascal@7 15 esac
pascal@0 16 case "$WGET_URL" in
pascal@0 17 ftp*|http*);;
pascal@0 18 *) WGET_URL=$WEB_SITE$WGET_URL;;
pascal@0 19 esac
pascal@0 20 TARBALL="$(basename $WGET_URL)"
pascal@0 21 VERSION="$(echo $TARBALL | sed 's/.*coin-\(.*\)-linux.tar.*/\1/')"
pascal@0 22 wget --no-check-certificate -O $TARBALL "$WGET_URL"
pascal@0 23
pascal@0 24 [ -f $TARBALL ] || abort_package "Could not download $TARBALL from $WGET_URL. Exiting."
pascal@0 25
pascal@0 26 mkdir -p $PACKAGE-$VERSION/fs/usr/bin
pascal@7 27 busybox tar xf $TARBALL
pascal@0 28
pascal@0 29 mv $PACKAGE-$VERSION-linux/bin/32/* $PACKAGE-$VERSION/fs/usr/bin
pascal@0 30 rm -rf $PACKAGE-$VERSION-linux
pascal@0 31
pascal@0 32 # extracted pkg can be removed: Save RAM
pascal@0 33 rm -f $TARBALL
pascal@0 34
pascal@0 35 cd $PACKAGE-$VERSION/fs
pascal@0 36
pascal@0 37 # Create menu
pascal@0 38 mkdir -p usr/share/applications
pascal@0 39 cat > usr/share/applications/$PACKAGE.desktop <<EOT
pascal@0 40 [Desktop Entry]
pascal@0 41 Version=1.0
pascal@0 42 Encoding=UTF-8
pascal@0 43 Name=$PACKAGE
pascal@0 44 Exec=/usr/bin/$PACKAGE-qt
pascal@0 45 Icon=stock_certificate.png
pascal@0 46 Terminal=false
pascal@0 47 Categories=Application
pascal@0 48 Comment=$SHORT_DESC
pascal@0 49 Type=Application
pascal@0 50 Categories=Office;
pascal@0 51 EOT
pascal@0 52 cd ../..
pascal@2 53 set +e