wok-current annotate locale-de/receipt @ rev 1363

Add libQtXml
author Allan Pinto <allan316@gmail.com>
date Thu Sep 11 15:38:59 2008 +0000 (2008-09-11)
parents a15028ca0a13
children 37105c976ab8
rev   line source
pankso@724 1 # SliTaz package receipt
pankso@724 2
pankso@724 3 PACKAGE="locale-de"
pankso@724 4 VERSION="1.0"
pankso@724 5 CATEGORY="system-tools"
pankso@724 6 SHORT_DESC="German locale pack."
pankso@724 7 MAINTAINER="pankso@slitaz.org"
pankso@724 8 DEPENDS="glibc-base"
pankso@724 9 BUILD_DEPENDS="glibc glibc-locale"
pankso@724 10 WEB_SITE="http://www.slitaz.org/"
pankso@724 11
pankso@724 12 CORE_PKGS="asunder epdfview gpicview gparted glib gtk+ leafpad pcmanfm xpad"
pankso@724 13
pankso@724 14 LOCALE="de"
pankso@724 15 LOCALEDEF="de_DE"
pankso@724 16 CHARMAP="ISO-8859-1"
pankso@724 17
pankso@724 18 GLIBC_FILES=$WOK/glibc/glibc-2.7/_pkg
pankso@724 19 PKG_NAME="$PACKAGE"
pankso@724 20 PKG_VERS="$VERSION"
pankso@724 21
pankso@724 22 # Rules to gen a SliTaz package suitable for Tazpkg.
pankso@724 23 # Install files in /usr/lib/locale.
pankso@724 24 #
pankso@724 25 genpkg_rules()
pankso@724 26 {
pankso@724 27 mkdir -p $fs/usr/share/locale/$LOCALE
pankso@724 28
pankso@724 29 # Get the core apps messages.
pankso@724 30 for pkg in $CORE_PKGS
pankso@724 31 do
pankso@724 32 . $WOK/$pkg/receipt
pankso@724 33 if [ -d $WOK/$pkg/$PACKAGE-$VERSION/_pkg/usr/share/locale/$LOCALE ]; then
pankso@724 34 cp -a $WOK/$pkg/$PACKAGE-$VERSION/_pkg/usr/share/locale/$LOCALE \
pankso@724 35 $fs/usr/share/locale
pankso@724 36 fi
pankso@724 37 done
pankso@724 38
pankso@724 39 # Glibc locale.
pankso@724 40 #cp -a $GLIBC_FILES/usr/share/locale/$LOCALE $fs/usr/share/locale
pankso@724 41
pankso@724 42 PACKAGE="$PKG_NAME"
pankso@724 43 VERSION="$PKG_VERS"
pankso@724 44
pankso@724 45 # Gen locale files.
pankso@724 46 mkdir -p $fs/usr/lib/locale
pankso@724 47 localedef -i $LOCALEDEF -c -f $CHARMAP $fs/usr/lib/locale/$LOCALEDEF
pankso@724 48 }
pankso@724 49
pankso@724 50 # Post install to configure default locale.
pankso@724 51 post_install()
pankso@724 52 {
pankso@724 53 local root
pankso@724 54 root=$1
pankso@724 55 # locale.conf
pankso@951 56 if [ -s $root/etc/locale.conf ]; then
pankso@724 57 echo "LANG=\"$LOCALEDEF\"" > $root/etc/locale.conf
pankso@724 58 echo "LC_ALL=\"$LOCALEDEF\"" >> $root/etc/locale.conf
pankso@724 59 fi
pankso@724 60 }
pankso@724 61
pankso@724 62 # Back to C if it's the last used locale.
pankso@724 63 post_remove()
pankso@724 64 {
pankso@724 65 if grep -q $LOCALEDEF /etc/locale.conf; then
pankso@724 66 echo "LANG=C" > /etc/locale.conf
pankso@724 67 echo "LC_ALL=C" >> /etc/locale.conf
pankso@724 68 fi
pankso@724 69 }