wok-6.x diff locale-ru/receipt @ rev 3087

Add slitaz-i18n (provide script and conf to build languages pack) + clean up
author Christophe Lincoln <pankso@slitaz.org>
date Sat May 16 02:25:40 2009 +0200 (2009-05-16)
parents f3f6bcae6367
children b584b0d0bbb4
line diff
     1.1 --- a/locale-ru/receipt	Tue May 12 23:24:55 2009 +0200
     1.2 +++ b/locale-ru/receipt	Sat May 16 02:25:40 2009 +0200
     1.3 @@ -6,11 +6,12 @@
     1.4  SHORT_DESC="Russian locale pack."
     1.5  MAINTAINER="pankso@slitaz.org"
     1.6  DEPENDS="glibc-base"
     1.7 -BUILD_DEPENDS="glibc glibc-locale xorg-libX11"
     1.8 +BUILD_DEPENDS="glibc glibc-locale slitaz-i18n"
     1.9  WEB_SITE="http://www.slitaz.org/"
    1.10  
    1.11 -CORE_PKGS="asunder alsaplayer epdfview galculator geany gpicview gparted \
    1.12 -glib gtk+ grsync leafpad lxpanel lxtask obconf openbox pcmanfm xpad"
    1.13 +# Source slitaz-i18n files from the wok.
    1.14 +. $WOK/slitaz-i18n/stuff/locale-pack.functions
    1.15 +. $WOK/slitaz-i18n/stuff/locale-pack.conf
    1.16  
    1.17  LOCALE="ru"
    1.18  LOCALEDEF="ru_RU"
    1.19 @@ -27,24 +28,16 @@
    1.20  }
    1.21  
    1.22  # Rules to gen a SliTaz package suitable for Tazpkg.
    1.23 -# Genereted locale files are in /usr/lib/locale.
    1.24  genpkg_rules()
    1.25 -{
    1.26 -	mkdir -p $fs/usr/share/locale/$LOCALE $fs/usr/lib/locale
    1.27 +{	
    1.28  	PKG_NAME="$PACKAGE"
    1.29  	PKG_VERS="$VERSION"
    1.30 -	# Get the core packages messages.
    1.31 -	for pkg in $CORE_PKGS
    1.32 -	do
    1.33 -		[ -f $WOK/$pkg/receipt ] && . $WOK/$pkg/receipt
    1.34 -		if [ -d $WOK/$pkg/$PACKAGE-$VERSION/_pkg/usr/share/locale/$LOCALE ]; then
    1.35 -			cp -a $WOK/$pkg/$PACKAGE-$VERSION/_pkg/usr/share/locale/$LOCALE \
    1.36 -				$fs/usr/share/locale
    1.37 -		fi
    1.38 -	done
    1.39 +	mk_locale_dir
    1.40 +	get_slitaz_messages
    1.41 +	get_core_messages
    1.42  	PACKAGE="$PKG_NAME"
    1.43  	VERSION="$PKG_VERS"
    1.44 -	localedef -i $LOCALEDEF -c -f $CHARMAP $fs/usr/lib/locale/$LOCALEDEF.UTF-8
    1.45 +	localedef -i $LOCALEDEF -c -f $CHARMAP $fs/usr/lib/locale/$LOCALEDEF
    1.46  }
    1.47  
    1.48  # Back to C if it's the last used locale.