wok-6.x annotate locale-zh_CN/receipt @ rev 10739
locale-*: Up to 4.0 version string, had core pkgs to french pack (we dont have any po file now!) and add nano, mtpaint, midori to all languages pack
author | Christophe Lincoln <pankso@slitaz.org> |
---|---|
date | Mon May 30 00:54:30 2011 +0200 (2011-05-30) |
parents | 22b72b21a488 |
children | ce3cb07f3afd |
rev | line source |
---|---|
pankso@2778 | 1 # SliTaz package receipt |
pankso@2778 | 2 |
pankso@2778 | 3 PACKAGE="locale-zh_CN" |
pankso@10739 | 4 VERSION="4.0" |
pankso@2778 | 5 CATEGORY="system-tools" |
pankso@2778 | 6 SHORT_DESC="Chinese Simplified locale pack." |
lufeng369@7377 | 7 MAINTAINER="lufeng369@slitaz.org" |
lufeng369@7377 | 8 DEPENDS="glibc-base wqy-microhei" |
lufeng369@7401 | 9 BUILD_DEPENDS="glibc-locale xorg-libX11" |
pankso@2778 | 10 WEB_SITE="http://www.slitaz.org/" |
pankso@2778 | 11 |
pankso@2778 | 12 LOCALE="zh_CN" |
pankso@2778 | 13 LOCALEDEF="zh_CN" |
pankso@2778 | 14 CHARMAP="UTF-8" |
pankso@2778 | 15 |
pankso@2778 | 16 # Rules to gen a SliTaz package suitable for Tazpkg. |
pankso@2778 | 17 # Genereted locale files are in /usr/lib/locale. |
pankso@2778 | 18 genpkg_rules() |
pankso@2778 | 19 { |
pankso@2778 | 20 mkdir -p $fs/usr/share/locale/$LOCALE $fs/usr/lib/locale |
pankso@2778 | 21 localedef -i $LOCALEDEF -c -f $CHARMAP $fs/usr/lib/locale/$LOCALEDEF.UTF-8 |
lufeng369@7377 | 22 |
lufeng369@7377 | 23 GCONV_MODULES=" |
lufeng369@7377 | 24 BIG5.so GBBIG5.so GBGBK.so |
lufeng369@7377 | 25 UTF-32.so GB18030.so EUC-CN.so |
pankso@10739 | 26 GBK.so UTF-7.so libGB.so" |
lufeng369@7377 | 27 mkdir -p $fs/usr/bin |
lufeng369@7377 | 28 mkdir -p $fs/usr/lib/gconv |
lufeng369@7377 | 29 |
lufeng369@7377 | 30 cp /usr/bin/iconv $fs/usr/bin |
lufeng369@7377 | 31 for i in $GCONV_MODULES; do |
lufeng369@7377 | 32 cp /usr/lib/gconv/$i $fs/usr/lib/gconv |
lufeng369@7377 | 33 done |
lufeng369@7401 | 34 |
pankso@10739 | 35 install -D /usr/share/zoneinfo/Asia/Shanghai \ |
pankso@10739 | 36 $fs/usr/share/zoneinfo/Asia/Shanghai -m 644 |
pankso@10739 | 37 install -D /usr/share/zoneinfo/posix/Asia/Shanghai \ |
pankso@10739 | 38 $fs/usr/share/posix/zoneinfo/Asia/Shanghai -m 644 |
pankso@10739 | 39 install -D /usr/share/zoneinfo/right/Asia/Shanghai \ |
pankso@10739 | 40 $fs/usr/share/right/zoneinfo/Asia/Shanghai -m 644 |
pankso@2778 | 41 } |
pankso@10739 | 42 |
lufeng369@7377 | 43 post_install() |
lufeng369@7377 | 44 { |
lufeng369@7377 | 45 echo LANG=zh_CN.UTF-8 > /etc/locale.conf |
lufeng369@7401 | 46 echo Asia/Shanghai > /etc/TZ |
lufeng369@7401 | 47 export TZ=Asia/Shanghai |
lufeng369@7401 | 48 hwclock --hctosys |
lufeng369@7377 | 49 } |
pankso@10739 | 50 |
pankso@2778 | 51 # Back to C if it's the last used locale. |
pankso@2778 | 52 post_remove() |
pankso@2778 | 53 { |
pankso@2778 | 54 if grep -q $LOCALEDEF /etc/locale.conf; then |
pankso@2778 | 55 echo "LANG=C" > /etc/locale.conf |
pankso@2778 | 56 fi |
pankso@2778 | 57 } |