get-scripts rev 11

add flash-plugin
author Pascal Bellard <pascal.bellard@slitaz.org>
date Tue Apr 15 13:43:05 2014 +0000 (2014-04-15)
parents 2532cbc29d1e
children 20bc76d343ad
files flash-plugin geogebra
line diff
     1.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     1.2 +++ b/flash-plugin	Tue Apr 15 13:43:05 2014 +0000
     1.3 @@ -0,0 +1,63 @@
     1.4 +WEB_SITE="http://www.adobe.com/products/flash/"
     1.5 +SHORT_DESC="Adobe Flash Player."
     1.6 +TARBALL="install_flash_player_11_linux.i386.tar.gz"
     1.7 +
     1.8 +WGET_URL=http://fpdownload.macromedia.com/get/flashplayer/current/licensing/linux/$TARBALL
     1.9 +busybox wget -O $TARBALL $WGET_URL
    1.10 +[ -f $TARBALL ] || abort_package "Could not download $TARBALL. Exiting."
    1.11 +tar xzf $TARBALL
    1.12 +VERSION="$(strings libflashplayer.so | sed '/FlashPlayer_/!d;s/.*yer_\(.*\)_Flash.*/\1/;s/_/./g')"
    1.13 +
    1.14 +# Install files
    1.15 +chmod 755 libflashplayer.so
    1.16 +chown root.root libflashplayer.so
    1.17 +dir=$PACKAGE-$VERSION/fs
    1.18 +mkdir -p $dir/usr/share/flash
    1.19 +mv libflashplayer.so $dir/usr/share/flash
    1.20 +mv usr/bin $dir/usr
    1.21 +mv usr/share/icons $dir/usr/share
    1.22 +mv usr/share/pixmaps $dir/usr/share
    1.23 +
    1.24 +# Sanity Check: Reexport firefox libraries if they don't exist
    1.25 +dir=$PACKAGE-$VERSION/fs/usr/lib
    1.26 +mkdir -p $dir
    1.27 +for i in /usr/lib/firefox/*.so ; do
    1.28 +  	[ -f $i ] && [ -z "`ls /usr/lib/$(basename $i)`" ] && ln -s $i $dir	
    1.29 +done
    1.30 +
    1.31 +# Create pseudo package
    1.32 +cat > $PACKAGE-$VERSION/receipt <<EOT
    1.33 +PACKAGE="$PACKAGE"
    1.34 +VERSION="$VERSION"
    1.35 +CATEGORY="non-free"
    1.36 +SHORT_DESC="$SHORT_DESC"
    1.37 +WEB_SITE="$WEB_SITE"
    1.38 +DEPENDS="libfirefox curl atk cairo expat fontconfig freetype glib gtk+ libpng \
    1.39 +nss pango pixman xorg-libICE xorg-libSM xorg-libX11 xorg-libXau xorg-libXcomposite \
    1.40 +xorg-libXcursor xorg-libXdamage xorg-libXdmcp xorg-libXext xorg-libXfixes \
    1.41 +xorg-libXinerama xorg-libXrandr xorg-libXrender xorg-libXt zlib"
    1.42 +
    1.43 +post_install()
    1.44 +{
    1.45 +	echo -n "Processing post install commands..."
    1.46 + 
    1.47 +	[ -d \$1/usr/lib/mozilla/plugins ] || mkdir -p \$1/usr/lib/mozilla/plugins
    1.48 +	ln -s /usr/share/flash/libflashplayer.so \$1/usr/lib/mozilla/plugins
    1.49 +	[ -d \$1/opt/google/chrome/plugins ] || mkdir -p \$1/opt/google/chrome/plugins
    1.50 +	ln -s /usr/share/flash/libflashplayer.so \$1/opt/google/chrome/plugins/libgcflashplayer.so
    1.51 +	[ -d \$1/usr/lib/opera/plugins ] || mkdir -p \$1/usr/lib/opera/plugins
    1.52 +	ln -s /usr/share/flash/libflashplayer.so \$1/usr/lib/opera/plugins/libflashplayer.so
    1.53 +	status
    1.54 +}
    1.55 +
    1.56 +post_remove()
    1.57 +{
    1.58 +	echo -n "Processing post remove commands..."
    1.59 +	rm -f \$1/usr/lib/mozilla/plugins/libflashplayer.so
    1.60 +	rm -f \$1/opt/google/chrome/plugins/libgcflashplayer.so
    1.61 +	rm -f \$1/usr/lib/opera/plugins/libflashplayer.so
    1.62 +	status
    1.63 +}
    1.64 +EOT
    1.65 +
    1.66 +set +e
     2.1 --- a/geogebra	Mon Mar 31 11:07:42 2014 +0000
     2.2 +++ b/geogebra	Tue Apr 15 13:43:05 2014 +0000
     2.3 @@ -18,7 +18,7 @@
     2.4  SHORT_DESC="$(sed '/^Description:/!d;s/.*: //' $PACKAGE/meta/control)"
     2.5  MAINTAINER="$(sed '/^Maintainer:/!d;s/.*: //' $PACKAGE/meta/control)"
     2.6  VERSION="$(sed '/^Version:/!d;s/.*: //' $PACKAGE/meta/control)"
     2.7 -TARBALL=$PACKAGE-$VERSION.deb
     2.8 +TARBALL=${PACKAGE}_$VERSION.deb
     2.9  mv $PACKAGE $PACKAGE-$VERSION
    2.10  
    2.11  set +e