Update locale builder tool
[mono.git] / tools / locale-builder / README
1 * purpose
2
3         This tool is to generate globalization information from Unicode CLDR, with some changes
4         to fill the gap between .NET(Windows)-ism and the global standard.
5
6 * input resources
7
8         There is only an external resource: unicode CLDR. It can be downloaded from
9         http://www.unicode.org/Public/cldr/
10
11         CLDR specificatin can be found at http://www.unicode.org/reports/tr35/
12
13         All content has to me extracted into CLDR folder. The latest version used is 21.
14
15         There is an extra mono resource included in this directory lcids.xml for LCIDs.
16
17 * generated file
18
19         culture-info-table.h contains the following sections:
20
21         - datetime_format_entries
22           See DateTimeFormatEntry.AppendTableRow() in DateTimeFormatEntry.cs.
23         - number_format_entries
24           See NumberFormatEntry.AppendTableRow() in NumberFormatEntry.cs.
25         - culture_entries
26           See CultureInfoEntry.AppendTableRow() in CultureInfoEntry.cs.
27         - culture_name_entries
28           See Driver.Run() in Driver.cs.
29         - region_entries
30           See RegionInfoEntry.AppendTableRow() in RegionInfoEntry.cs.
31         - region_name_entries
32           See Driver.Run() in Driver.cs.
33         - locale_strings
34           See Driver.Run() in Driver.cs.
35
36         In each entry, strings are extracted to locale_strings table, and in each structure they are
37         represented as an index to the string.
38
39 * updating the data
40
41         Update Makefile.am to get the latest CLDR data. However, CLDR is not complete and
42         it's missing data for many rarely used cultures. In such cases we provide empty value
43         but when someone has the knowleadge what the values should be it's recommended to
44         use online CLDR tool to fill the data gap.
45
46         To create the files used by the runtime after an update, run:
47                 make culture-table
48                 make install-culture-table
49
50         At the start of Makefile.am there are additional instructions for specific builds.
51