Mailing List Archive


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[tlug] Re: Japanese Word processor for linux



David Oftedal wrote:

> >You may have to add the locale (ja_JP.SJIS) to /etc/locale.gen and run
> >locale-gen to generate it.
> 
> You can do that? I've always done it manually with localedef. (Though 
> what I've generated is a ja_JP.UTF-8, locale, not SJIS.

At least in Debian, yes.
However /usr/sbin/locale-gen is a shellscript, so it may be a Debianism:

#!/bin/sh

set -e

LOCALEGEN=/etc/locale.gen
LOCALES=/usr/share/i18n/locales
if [ -n "$POSIXLY_CORRECT" ]; then
  unset POSIXLY_CORRECT
fi


[ -f $LOCALEGEN -a -s $LOCALEGEN ] || exit 0;

# Remove all old locale dir and locale-archive before generating new
# locale data.
rm -rf /usr/lib/locale/* || true

umask 022

echo "Generating locales..."
while read locale charset; do \
	case $locale in \#*) continue;; esac; \
	[ -n "$locale" -a -n "$charset" ] || continue
	echo -n "  `echo $locale | sed 's/\([^.\@]*\).*/\1/'`"; \
	echo -n ".$charset"; \
	echo -n `echo $locale | sed 's/\([^\@]*\)\(\@example.com*\)*/\2/'`; \
	echo -n '...'; \
        if [ -f $LOCALES/$locale ]; then input=$locale; else \
        input=`echo $locale | sed 's/\([^.]*\)[^@]*\(.*\)/\1\2/'`; fi; \
	localedef -i $input -c -f $charset -A /etc/locale.alias $locale; \
	echo ' done'; \
done < $LOCALEGEN
echo "Generation complete."

-- 
/* Tobias */     int main(int a,char **b)    /* PGP: http://9ac7e0bc.2ya.com */
{char i,j,t,*r=*++b;srand(getpid());for(;*r;){for(;*r&&!isalpha(*r);r++);for(i=
1;isalpha(r[i+1]);i++){j=rand()%i;t=r[i];r[i]=r[++j];r[j]=t;}r+=i+1;}puts(*b);}
np: Omi Minami: Ruri Hoshino at Vocal 02 - Rose Bud []


Home | Main Index | Thread Index

Home Page Mailing List Linux and Japan TLUG Members Links