• Home
  • History
  • Annotate
  • only in /external/icu4c/stubdata/
NameDateSize

..24-Jul-20134 KiB

Android.mk24-Jul-20131.3 KiB

cnv/24-Jul-20134 KiB

icu-data-default.txt24-Jul-201316 KiB

icu_dat_generator.py24-Jul-20139 KiB

icudt50l-all.dat24-Jul-201317 MiB

icudt50l-default.dat24-Jul-201311.1 MiB

Makefile.in24-Jul-20133.9 KiB

Makefile.org24-Jul-20133.9 KiB

NOTICE24-Jul-20135.4 KiB

readme.txt24-Jul-20133.6 KiB

reduced_coll/24-Jul-20134 KiB

regenerate.sh24-Jul-20131.7 KiB

root.mk24-Jul-2013271

stubdata.c24-Jul-20132.3 KiB

stubdata.vcxproj24-Jul-201315.9 KiB

stubdata.vcxproj.filters24-Jul-20131 KiB

readme.txt

1This directory is used for building our Android ICU data file.
2
31. To generate ICU data files:run the icu_dat_generator.py script.
4   The command is:
5     ./icu_dat_generator.py [-v] [-h]
6
72. To add a resource to Android ICU data file: insert an entry to
8   icu-data-default.txt in external/icu4c/stubdata then
9   run icu_dat_generator.py.
10   For example, to add French collation, you need to
11   a. Add an entry, "coll/fr.res", into external/icu4c/stubdata/icu-data-default.txt
12   b. run "./icu_dat_generator.py".
13
143. Add a new resource or modify existing ICU resource definition:
15   Note: This is a rare case. You should talk to ICU team first if it is a bug
16   in ICU resource or a feature enhancement before making such changes.
17   If you would like to add existing ICU resource to Android, please check #2.
18   a. Create or change the text format resource files under external/icu4c/data.
19   b. Make a temporary directory for ICU build.
20      i.e. mkdir external/icu4c/icuBuild
21   c. cd to ICU build directory.
22      i.e. cd external/icu4c/icuBuild
23   d. Run external/icu4c/runConfigureICU with "Linux" option to generate the
24      makefile.
25      i.e. $ANDROID_BUILD_TOP/external/icu4c/runConfigureICU Linux
26   e. make -j2
27   f. The new icudtXXl.dat is under data/out/tmp and the individual resources are
28      under data/out/build/icudtXXl
29      For example, you can find data/out/tmp/icudtXXl.dat and data/out/build/icudtXX48l/*.res.
30   g. Copy the new icudtXXl.dat over $ANDROID_BUILD_TOP/external/icu4c/stubdata/icudtXXl-all.dat.
31      i.e. cp data/out/tmp/icudtXXl.dat $ANDROID_BUILD_TOP/external/icu4c/stubdata/icudtXXl-all.dat.
32   h. Check #1 or #2 to replace or add resource to ICU.
33   i. Clean up ICU build directory.
34   j. Discuss with icu-team how to include the change to public ICU.
35
36Locale Resource Files:
37- icudtXXl-all.dat contains the resources in packed
38  form. It includes everything that comes with
39  a vanilla ICU release. icu_dat_generator.py uses this file to generate
40  custom build dat files.
41
42- cnv/*.cnv are the additional encodings required by Android.
43  These are
44  - gsm-03.38-2000.cnv
45  - iso-8859_16-2001.cnv
46  - docomo-shift_jis-2007.cnv
47  - kddi-jisx-208-2007.cnv
48  - kddi-shift_jis-2007.cnv
49  - softbank-jisx-208-2007.cnv
50  - softbank-shift_jis-2007.cnv
51
52- Text format ICU resource files are under external/icu4c/data directory.
53  Binary resource files are packaged in external/icu4c/stubdata/icudtXXl-all.dat.
54  If you have bug fixes to apply or want to examine individual resource sizes,
55  you can run icupkg utility to extract icudtXXl-all.dat into a temporary directory.
56  For example:
57  cd $ANDROID_BUILD_TOP/external/icu4c/stubdata
58  cp icudtXXl-all.dat icudtXXl.dat
59  mkdir tempDir
60  $ANDROID_BUILD_TOP/prebuilt/linux-x86_64/icu-4.8/icupkg  icudtXXl.dat -x "*" -d tempDir
61
62Run ICU tests:
63ICU tests are not part of Android build. If you change the ICU code or data,
64it is highly recommended to run ICU tests.
65 1. Remove the flag "-R" in external/icu4c/data/Makefile.in.
66    "Reverse collation keys" tables are not included in ICU data on Android. To
67    pass ICU collation tests, you need to delete the flag "-R" in Makefile.in.
68    Search for " -R" under "### collation res" section in external/icu4c/data/Makefile.in,
69    delete all of them.
70 2. Make a temporary directory for ICU build.
71    i.e. mkdir external/icu4c/icuBuild
72 3. cd to ICU build directory.
73    i.e. cd external/icu4c/icuBuild
74 4. Run external/icu4c/runConfigureICU with "Linux" option to generate the makefile.
75    i.e. $ANDROID_BUILD_TOP/external/icu4c/runConfigureICU Linux
76 5. make -j2 check
77 6. Check the result. Ignore the errors from tsconv.
78