1 '\" t -*- coding: UTF-8 -*-
2 .\" Copyright (C) 1994 Jochen Hein (Hein@Student.TU-Clausthal.de)
3 .\" Copyright (C) 2008 Petr Baudis (pasky@suse.cz)
4 .\" Copyright (C) 2014 Michael Kerrisk <mtk@manpages@gmail.com>
6 .\" %%%LICENSE_START(GPLv2+_SW_3_PARA)
7 .\" This program is free software; you can redistribute it and/or modify
8 .\" it under the terms of the GNU General Public License as published by
9 .\" the Free Software Foundation; either version 2 of the License, or
10 .\" (at your option) any later version.
12 .\" This program is distributed in the hope that it will be useful,
13 .\" but WITHOUT ANY WARRANTY; without even the implied warranty of
14 .\" MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15 .\" GNU General Public License for more details.
17 .\" You should have received a copy of the GNU General Public
18 .\" License along with this manual; if not, see
19 .\" <http://www.gnu.org/licenses/>.
22 .\" 2008-06-17 Petr Baudis <pasky@suse.cz>
23 .\" LC_TIME: Describe first_weekday and first_workday
25 .TH LOCALE 5 2015-01-22 "Linux" "Linux User Manual"
27 locale \- describes a locale definition file
31 definition file contains all the information that the
33 command needs to convert it into the binary locale database.
35 The definition files consist of sections which each describe a
36 locale category in detail.
38 The locale definition file starts with a header that may consist
39 of the following keywords:
42 is followed by a character that should be used as the
43 escape-character for the rest of the file to mark characters that
44 should be interpreted in a special way.
45 It defaults to the backslash (\\).
48 is followed by a character that will be used as the
49 comment-character for the rest of the file.
50 It defaults to the number sign (#).
52 The locale definition has one part for each locale category.
53 Each part can be copied from another existing locale or
54 can be defined from scratch.
55 If the category should be copied,
56 the only valid keyword in the definition is
58 followed by the name of the locale in double quotes which should be
61 When defining a category from scratch, all field descriptors and strings
62 should be defined as Unicode code points in angle brackets, unless
63 otherwise stated below.
64 For example, "€" is to be presented as "<U20AC>", "%a" as
65 "<U0025><U0061>", and "Monday" as
66 "<U0053><U0075><U006E><U0064><U0061><U0079>".
67 Values defined as Unicode code points must be in double quotes, plain
68 number values are not quoted (but
72 follow special formatting, see the system-provided locale files for
74 .SS Locale category sections
75 The following category sections are defined by POSIX:
89 In addition, since version 2.2,
90 the GNU C library supports the following nonstandard categories:
106 for a more detailed description of each category.
109 The definition starts with the string
113 The following keywords are allowed:
114 .\" Thanks to the kind folk who wrote localedata/locales/uk_UA
117 followed by a string containing field descriptors that define
118 the format used for postal addresses in the locale.
119 The following field descriptors are recognized:
120 .\" From localedata/locales/uk_UA:
124 .\" BUG: %l escape sequence from ISO/IEC 14652:2002 is not supported
126 .\" Person's name, possibly constructed with the
131 .\" https://sourceware.org/bugzilla/show_bug.cgi?id=16983
134 Care of person, or organization.
146 Street or block (e.g., Japanese) name.
149 House number or designation.
152 Insert an end-of-line if the previous descriptor's value was not an empty
153 string; otherwise ignore.
156 Insert a space if the previous descriptor's value was not an empty string;
160 Room number, door designation.
166 Country designation, from the <country_post> keyword.
169 .\" BUG: %l escape sequence from ISO/IEC 14652:2002 is not
170 .\" supported by glibc
171 .\" Local township within town or city.
173 .\" https://sourceware.org/bugzilla/show_bug.cgi?id=16983
176 Zip number, postal code.
182 State, province, or prefecture.
185 Country, as taken from data record.
187 Each field descriptor may have an \(aqR\(aq after
188 the \(aq%\(aq to specify that the
189 information is taken from a Romanized version string of the
195 followed by the country name in the language of the current document
196 (e.g., "Deutschland" for the
201 followed by the abbreviation of the country (see CERT_MAILCODES).
204 followed by the two-letter abbreviation of the country (ISO 3166).
207 followed by the three-letter abbreviation of the country (ISO 3166).
210 followed by the numeric country code as plain numbers (ISO 3166).
213 followed by the code for the country car number.
216 followed by the ISBN code as plain numbers (for books).
219 followed by the language name in the language of the current document.
222 followed by the two-letter abbreviation of the language (ISO 639).
225 followed by the three-letter abbreviation of the language (ISO 639-2/T).
228 followed by the three-letter abbreviation of the language for library
230 Applications should in general prefer
237 definition ends with the string
238 .IR "END LC_ADDRESS" .
240 The definition starts with the string
244 The following keywords are allowed:
245 .\" FIXME The following LC_CTYPE keywords are not documented:
246 .\" translit_start + translit_end
251 .\" map (to_inpunct, to_outpunct)
254 followed by a list of uppercase letters.
259 are included automatically.
260 Characters also specified as
269 followed by a list of lowercase letters.
274 are included automatically.
275 Characters also specified as
284 followed by a list of letters.
285 All character specified as either
289 are automatically included.
290 Characters also specified as
299 followed by the characters classified as numeric digits.
306 They are included by default in this class.
309 followed by a list of characters defined as white-space
311 Characters also specified as
324 .BR <carriage-return> ,
328 are automatically included.
331 followed by a list of control characters.
332 Characters also specified as
345 followed by a list of punctuation characters.
356 character are not allowed.
359 followed by a list of printable characters, not including the
362 The characters defined as
370 are automatically included.
371 Characters also specified as
376 followed by a list of printable characters, including the
379 The characters defined as
388 character are automatically included.
389 Characters also specified as
394 followed by a list of characters classified as hexadecimal
396 The decimal digits must be included followed by one or
397 more set of six characters in ascending order.
399 characters are included by default:
411 followed by a list of characters classified as
417 are automatically included.
420 followed by a list of mappings from lowercase to uppercase
422 Each mapping is a pair of a lowercase and an uppercase letter
425 and enclosed in parentheses.
426 The members of the list are separated
430 followed by a list of mappings from uppercase to lowercase
432 If the keyword tolower is not present, the reverse of the
433 toupper list is used.
437 definition ends with the string
440 Due to limitations of glibc not all POSIX-options are implemented.
442 The definition starts with the string
446 The following keywords are allowed:
447 .\" FIXME The following LC_COLLATE keywords are not documented:
449 .\" symbol-equivalence
452 followed by the definition of a collating-element symbol
453 representing a multicharacter collating element.
456 followed by the definition of a collating symbol
457 that can be used in collation order statements.
459 The order-definition starts with a line:
462 followed by a list of keywords chosen from
467 The order definition consists of lines that describe the order
468 and is terminated with the keyword
470 .\" FIXME The following LC_COLLATE keywords are not documented:
473 .\" reorder-sections-after
474 .\" reorder-sections-end
478 definition ends with the string
479 .IR "END LC_COLLATE" .
480 .SS LC_IDENTIFICATION
481 The definition starts with the string
485 The values in this category are defined as plain strings.
487 The following keywords are allowed:
490 followed by the title of the locale document
491 (e.g., "Maori language locale for New Zealand").
494 followed by the name of the organization that maintains this document.
497 followed by the address of the organization that maintains this document.
500 followed by the name of the contact person at
501 the organization that maintains this document.
504 followed by the email address of the person or
505 organization that maintains this document.
508 followed by the telephone number (in international format)
509 of the organization that maintains this document.
512 followed by the fax number (in international format)
513 of the organization that maintains this document.
516 followed by the name of the language to which this document applies.
519 followed by the name of the country/geographic extent
520 to which this document applies.
523 followed by a description of the audience for which this document is intended.
526 followed by a description of any special application
527 for which this document is intended.
530 .\" as far as I can tell... (mtk)
531 followed by the short name for this document.
534 followed by the revision number of this document.
537 followed by the revision date of this document.
539 In addition, for each of the categories defined by the document,
540 there should be a line starting with the keyword
544 a string that identifies this locale category definition,
554 definition ends with the string
555 .IR "END LC_IDENTIFICATION" .
557 The definition starts with the string
561 The following keywords are allowed:
564 followed by a regular expression that describes possible
568 followed by a regular expression that describes possible
572 followed by the output string corresponding to "yes".
575 followed by the output string corresponding to "no".
579 definition ends with the string
580 .IR "END LC_MESSAGES" .
582 The definition starts with the string
586 The following keywords are allowed:
589 followed by number identifying the standard used for measurement.
590 The following values are recognized:
597 US customary measurements.
602 definition ends with the string
603 .IR "END LC_MEASUREMENT" .
605 The definition starts with the string
610 .IR int_curr_symbol ,
611 .IR currency_symbol ,
612 .IR mon_decimal_point ,
613 .IR mon_thousands_sep ,
617 are defined as Unicode code points, the others as plain numbers.
619 The following keywords are allowed:
622 followed by the international currency symbol.
624 4-character string containing the international currency symbol as
625 defined by the ISO 4217 standard (three characters) followed by a
629 followed by the local currency symbol.
632 followed by the string that will be used as the decimal delimiter
633 when formatting monetary quantities.
636 followed by the string that will be used as a group separator
637 when formatting monetary quantities.
640 followed by a sequence of integers separated by semicolons that
641 describe the formatting of monetary quantities.
647 followed by a string that is used to indicate a positive sign for
651 followed by a string that is used to indicate a negative sign for
655 followed by the number of fractional digits that should be used when
657 .IR int_curr_symbol .
660 followed by the number of fractional digits that should be used when
662 .IR currency_symbol .
665 followed by an integer that indicates the placement of
667 for a nonnegative formatted monetary quantity:
671 the symbol succeeds the value.
674 the symbol precedes the value.
678 followed by an integer that indicates the placement of
680 for a negative formatted monetary quantity.
681 The same values are recognized as for
685 followed by an integer that indicates the placement of
686 .I int_currency_symbol
687 for a nonnegative internationally formatted monetary quantity.
688 The same values are recognized as for
692 followed by an integer that indicates the placement of
693 .I int_currency_symbol
694 for a negative internationally formatted monetary quantity.
695 The same values are recognized as for
699 followed by an integer that indicates the separation of
700 .IR currency_symbol ,
701 the sign string, and the value for a nonnegative formatted monetary quantity.
702 The following values are recognized:
706 No space separates the currency symbol and the value.
709 If the currency symbol and the sign string are adjacent,
710 a space separates them from the value;
711 otherwise a space separates the currency symbol and the value.
714 If the currency symbol and the sign string are adjacent,
715 a space separates them from the value;
716 otherwise a space separates the sign string and the value.
720 followed by an integer that indicates the separation of
721 .IR currency_symbol ,
722 the sign string, and the value for a negative formatted monetary quantity.
723 The same values are recognized as for
726 .I int_p_sep_by_space
727 followed by an integer that indicates the separation of
728 .IR int_currency_symbol ,
730 and the value for a nonnegative internationally formatted monetary quantity.
731 The same values are recognized as for
734 .I int_n_sep_by_space
735 followed by an integer that indicates the separation of
736 .IR int_currency_symbol ,
738 and the value for a negative internationally formatted monetary quantity.
739 The same values are recognized as for
743 followed by an integer that indicates where the
745 should be placed for a nonnegative monetary quantity:
749 Parentheses enclose the quantity and the
752 .IR int_curr_symbol .
755 The sign string precedes the quantity and the
758 .IR int_curr_symbol .
761 The sign string succeeds the quantity and the
764 .IR int_curr_symbol .
767 The sign string precedes the
770 .IR int_curr_symbol .
773 The sign string succeeds the
776 .IR int_curr_symbol .
780 followed by an integer that indicates where the
782 should be placed for a negative monetary quantity.
783 The same values are recognized as for
787 followed by an integer that indicates where the
789 should be placed for a nonnegative
790 internationally formatted monetary quantity.
791 The same values are recognized as for
795 followed by an integer that indicates where the
797 should be placed for a negative
798 internationally formatted monetary quantity.
799 The same values are recognized as for
804 definition ends with the string
805 .IR "END LC_MONETARY" .
807 The definition starts with the string
811 Various keywords are allowed, but only
814 Other keywords are needed only if there is common convention to
815 use the corresponding salutation in this locale.
816 The allowed keywords are as follows:
819 followed by a string containing field descriptors that define
820 the format used for names in the locale.
821 The following field descriptors are recognized:
822 .\" From localedata/locales/uk_UA:
829 Family names in uppercase.
838 First given name with Latin letters.
844 Additional given name(s).
847 Initials for additional given name(s).
853 Salutation, such as "Doctor".
856 Abbreviated salutation, such as "Mr." or "Dr.".
859 Salutation, using the FDCC-sets conventions.
860 .\" 1 for the name_gen
861 .\" In glibc 2.19, %d1 is used in only:
862 .\" /home/mtk/ARCHIVE/GLIBC/glibc-2.19/localedata/locales/bem_ZM
863 .\" /home/mtk/ARCHIVE/GLIBC/glibc-2.19/localedata/locales/zh_HK
864 .\" In glibc 2.19, %d[2-5] appear to be not used at all
871 If the preceding field descriptor resulted in an empty string,
872 then the empty string, otherwise a space character.
876 followed by the general salutation for any gender.
879 followed by the salutation for men.
882 followed by the salutation for married women.
885 followed by the salutation for unmarried women.
888 followed by the salutation valid for all women.
892 definition ends with the string
895 The definition starts with the string
899 The following keywords are allowed:
902 followed by the string that will be used as the decimal delimiter
903 when formatting numeric quantities.
906 followed by the string that will be used as a group separator
907 when formatting numeric quantities.
910 followed by a sequence of integers as plain numbers separated by
911 semicolons that describe the formatting of numeric quantities.
913 Each integer specifies the number of digits in a group.
914 The first integer defines the size of the group immediately
915 to the left of the decimal delimiter.
916 Subsequent integers define succeeding groups to the
917 left of the previous group.
918 If the last integer is not \-1, then the size of the previous group
919 (if any) is repeatedly used for the remainder of the digits.
920 If the last integer is \-1, then no further grouping is performed.
924 definition ends with the string
925 .IR "END LC_NUMERIC" .
927 The definition starts with the string
931 Values in this category are defined as plain numbers.
933 The following keywords are allowed:
936 followed by the height, in millimeters, of the standard paper format.
939 followed by the width, in millimeters, of the standard paper format.
943 definition ends with the string
946 The definition starts with the string
950 The following keywords are allowed:
953 followed by a string that contains field descriptors that identify
954 the format used to dial international numbers.
955 The following field descriptors are recognized:
956 .\" From localedata/locales/uk_UA
960 Area code without nationwide prefix (the prefix is often "00").
963 Area code including nationwide prefix.
966 Local number (within area code).
969 Extension (to local number).
975 Alternate carrier service code used for dialing abroad.
978 If the preceding field descriptor resulted in an empty string,
979 then the empty string, otherwise a space character.
983 followed by a string that contains field descriptors that identify
984 the format used to dial domestic numbers.
985 The recognized field descriptors are the same as for
989 followed by the prefix used to call international phone numbers.
992 followed by the prefix used from other countries to dial this country.
996 definition ends with the string
997 .IR "END LC_TELEPHONE" .
999 The definition starts with the string
1001 in the first column.
1003 The following keywords are allowed:
1004 .\" FIXME The following LC_TIME keywords are not documented:
1012 followed by a list of abbreviated names of the days of the week.
1013 The list starts with the first day of the week
1016 (Sunday by default).
1020 followed by a list of names of the days of the week.
1021 The list starts with the first day of the week
1024 (Sunday by default).
1028 followed by a list of abbreviated month names.
1031 followed by a list of month names.
1034 followed by the appropriate representation of the
1039 This should be left empty for locales not using AM/PM convention.
1042 followed by the appropriate date and time format.
1045 followed by the appropriate date format.
1048 followed by the appropriate time format.
1051 followed by the appropriate time format when using 12h clock format.
1052 This should be left empty for locales not using AM/PM convention.
1055 followed by a list of three values as plain numbers:
1056 The number of days in a week (by default 7),
1057 a date of beginning of the week (by default corresponds to Sunday),
1058 and the minimal length of the first week in year (by default 4).
1059 Regarding the start of the week,
1061 shall be used for Sunday and
1063 shall be used for Monday.
1066 .IR first_weekday " (since glibc 2.2)"
1067 followed by the number of the first day from the
1069 list to be shown in calendar applications.
1070 The default value of
1072 (plain number) corresponds to either Sunday or Monday depending
1073 on the value of the second
1078 .IR first_workday " (since glibc 2.2)"
1079 followed by the number of the first working day from the
1082 The default value is
1088 .\" from localedata/locales/uk_UA
1089 followed by a plain number value that indicates the direction for the
1090 display of calendar dates, as follows:
1094 Left-right from top.
1100 Right-left from top.
1104 followed by the appropriate date representation for
1109 definition ends with the string
1113 .I /usr/lib/locale/locale-archive
1114 Usual default locale archive location.
1116 .I /usr/share/i18n/locales
1117 Usual default path for locale definition files.
1119 POSIX.2, ISO/IEC TR 14652.
1121 The collective GNU C library community wisdom regarding
1129 https://sourceware.org/glibc/wiki/Locales
1132 The value of the second
1134 list item specifies the base of the
1141 specifies the offset of the first day-of-week in the
1147 For compatibility reasons, all glibc locales should set the value of the
1152 (Sunday) and base the
1156 lists appropriately, and set
1164 depending on whether the week and work week actually starts on Sunday or
1165 Monday for the locale.
1167 This manual page isn't complete.
1169 .\" Jochen Hein (Hein@Student.TU-Clausthal.de)
1183 This page is part of release 3.79 of the Linux
1186 A description of the project,
1187 information about reporting bugs,
1188 and the latest version of this page,
1190 \%http://www.kernel.org/doc/man\-pages/.