wok-current annotate firefox-langpack-fr/receipt @ rev 8358

Up: mercurial to 1.7.5.
author Christopher Rogers <slaxemulator@gmail.com>
date Thu Feb 03 15:58:22 2011 +0000 (2011-02-03)
parents b78f62881ef0
children 0360c9c8daaa
rev   line source
lufeng369@7487 1 # SliTaz package receipt.
lufeng369@7487 2
lufeng369@7487 3 PACKAGE="firefox-langpack-fr"
slaxemulator@7580 4 VERSION="3.6.13"
lufeng369@7487 5 CATEGORY="network"
lufeng369@7487 6 SHORT_DESC="France Language Package for firefox"
lufeng369@7487 7 MAINTAINER="lufeng369@gmail.com"
lufeng369@7487 8 DEPENDS="firefox"
lufeng369@7487 9 WEB_SITE="http://www.mozilla.com"
slaxemulator@7527 10 SOURCE="firefox"
slaxemulator@7527 11 LANG=`echo $PACKAGE | cut -d'-' -f3 | tr '_' '-'`
slaxemulator@7581 12 LANG_DIR="langpack-$LANG@firefox.mozilla.org"
slaxemulator@7527 13 TARBALL="$LANG.xpi"
slaxemulator@7493 14 URL="http://releases.mozilla.org/pub/mozilla.org/firefox/releases/$VERSION/linux-i686/xpi/$TARBALL"
slaxemulator@7493 15
lufeng369@7487 16 # Rules to gen a SliTaz package suitable for Tazpkg.
slaxemulator@7527 17 compile_rules()
slaxemulator@7527 18 {
slaxemulator@7527 19 cd $WOK/$PACKAGE
slaxemulator@7527 20 mkdir -p $LANG_DIR
slaxemulator@7527 21
slaxemulator@7527 22 # Get xpi
slaxemulator@7527 23 if [ -f $SOURCES_REPOSITORY/$PACKAGE-$VERSION.xpi ]; then
slaxemulator@7527 24 echo "Using current langpack ($PACKAGE-$VERSION.xpi)"
slaxemulator@7527 25 else
slaxemulator@7527 26 echo "Downloading langpack ($PACKAGE-$VERSION.xpi)"
slaxemulator@7527 27 wget -O $SOURCES_REPOSITORY/$PACKAGE-$VERSION.xpi $URL
slaxemulator@7527 28 fi
slaxemulator@7527 29 # Uncompress
slaxemulator@7527 30 echo -n "Uncompressing langpack ($PACKAGE-$VERSION.xpi)"
slaxemulator@7527 31 mkdir -p $LANG_DIR && unzip $SOURCES_REPOSITORY/$PACKAGE-$VERSION.xpi -d $LANG_DIR
slaxemulator@7527 32 status
slaxemulator@7527 33
slaxemulator@7527 34 }
slaxemulator@7527 35
slaxemulator@7527 36 # Rules to gen a SliTaz package suitable for Tazpkg.
lufeng369@7487 37 genpkg_rules()
lufeng369@7487 38 {
slaxemulator@7527 39 EXTDIR="$fs/usr/lib/$SOURCE-$VERSION/extensions"
slaxemulator@7527 40 mkdir -p $EXTDIR
slaxemulator@7527 41 cp -a $LANG_DIR $EXTDIR
lufeng369@7487 42 }
slaxemulator@7493 43
lufeng369@7487 44 post_install()
lufeng369@7487 45 {
slaxemulator@7527 46 echo ""
slaxemulator@7527 47 echo "Use the code below to change locale of firefox in shell:"
slaxemulator@7527 48 echo "sed -i '/pref/s/en-US/$LANG/' /etc/firefox/pref/firefox-l10n.js"
slaxemulator@7527 49 echo ""
lufeng369@7487 50 }
slaxemulator@7493 51