MKLOCALE(1) | General Commands Manual | MKLOCALE(1) |
mklocale
—
mklocale |
[-d ] [-t
type] < source >
language/LC_CTYPE |
mklocale |
[-d ] [-t
type] -o
language/LC_CTYPE source |
mklocale
utility reads an
LC_CTYPE
source file from standard input and produces
an LC_CTYPE
binary file on standard output suitable
for placement in
/usr/share/locale/<language>/LC_CTYPE.
The format of source is quite simple. It consists of a series of lines which start with a keyword and have associated data following. C style comments are used to place comments in the file.
Following options are available:
-d
-o
-t
Besides the keywords which will be listed below, the following are valid tokens in source:
RUNE
RUNE
may be any of the following:
\a
,
\b
, \f
,
\n
, \r
,
\t
, or \v
.STRING
THRU
...
or -
. Used to
indicate ranges.Key words which should only appear once are:
ENCODING
STRING
which indicates the encoding
mechanism to be used for this locale. The current encodings are:
NONE
UTF2
Universal
character set Transformation Format
adopted from
Plan 9 from Bell Labs
.EUC
EUC
encoding as used by several vendors of UNIX
systems.VARIABLE
EUC
encoding requires variable data.INVALID
RUNE
follows and is used as the invalid
rune for this locale.The following keywords may appear multiple times and have the following format for data:
RUNE1 RUNE2
⟩RUNE1
is mapped to RUNE2
.RUNE1 THRU RUNEn
:
RUNE2
⟩RUNE1
through RUNEn
are mapped to RUNE2
through
RUNE2
+ n-1.MAPLOWER
RUNE2
is the lower
case representation of RUNE1
.MAPUPPER
RUNE2
is the upper
case representation of RUNE1
.TODIGIT
RUNE2
is the integer value represented by
RUNE1
. For example, the ASCII character
‘0’ would map to the decimal value 0. Only values up to 255
are allowed.The following keywords may appear multiple times and have the following format for data:
RUNE
RUNE1
THRU RUNEn
RUNE1
and
RUNEn
have the property defined by the
keyword.ALPHA
CONTROL
DIGIT
GRAPH
LOWER
PUNCT
SPACE
UPPER
XDIGIT
BLANK
PRINT
IDEOGRAM
SPECIAL
PHONOGRAM
SWIDTHn
CHARSET
mklocale
utility first appeared in
4.4BSD.
mklocale
utility is overly simplistic.
We should switch to localedef
and its file
format, which is more standard.
July 15, 2013 | NetBSD 9.4 |