wok diff locale-cs/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-cs/receipt	Tue May 12 23:24:55 2009 +0200
     1.2 +++ b/locale-cs/receipt	Sat May 16 02:25:40 2009 +0200
     1.3 @@ -6,11 +6,12 @@
     1.4  SHORT_DESC="Czech locale pack."
     1.5  MAINTAINER="pankso@slitaz.org"
     1.6  DEPENDS="glibc-base"
     1.7 -BUILD_DEPENDS="glibc glibc-locale"
     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="cs"
    1.18  LOCALEDEF="cs_CZ"
    1.19 @@ -27,24 +28,13 @@
    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 \
    1.27 -		$fs/usr/lib/locale \
    1.28 -		$fs/usr/share/slitaz/messages
    1.29 -	cp -a stuff/messages $fs/usr/share/slitaz/messages/$LOCALE
    1.30 +{	
    1.31  	PKG_NAME="$PACKAGE"
    1.32  	PKG_VERS="$VERSION"
    1.33 -	# Get the core packages messages.
    1.34 -	for pkg in $CORE_PKGS
    1.35 -	do
    1.36 -		[ -f $WOK/$pkg/receipt ] && . $WOK/$pkg/receipt
    1.37 -		if [ -d $WOK/$pkg/$PACKAGE-$VERSION/_pkg/usr/share/locale/$LOCALE ]; then
    1.38 -			cp -a $WOK/$pkg/$PACKAGE-$VERSION/_pkg/usr/share/locale/$LOCALE \
    1.39 -				$fs/usr/share/locale
    1.40 -		fi
    1.41 -	done
    1.42 +	mk_locale_dir
    1.43 +	get_slitaz_messages
    1.44 +	get_core_messages
    1.45  	PACKAGE="$PKG_NAME"
    1.46  	VERSION="$PKG_VERS"
    1.47  	localedef -i $LOCALEDEF -c -f $CHARMAP $fs/usr/lib/locale/$LOCALEDEF