View Source

Welcome at Solaris New Locales project.

h1. Adding a new Locale to Solaris - Quick guide for community

_Please feel free to update or modify this document. If you find something wrong or incomplete please add the information or send me an email (the first option is preferred_ :-) _)_

The document describes how to help with a new locale in Solaris. In the document I use pseudo code xx_YY.UTF-8 for the new locale - substitute your language ([ISO 639-1|http://www.loc.gov/standards/iso639-2/englangn.html]) and country ([ISO 3166|http://www.iso.ch/iso/en/prods-services/iso3166ma/02iso-3166-code-lists/list-en1.html]) codes.

# OpenSolaris Project: Nevada Globalization workspace
#* read project description at [http://www.opensolaris.org/os/project/nv-g11n/]
#** section _'Source Code'_ contains information about public workspaces and how to access the source codes.
#** join your language group (section _'How to Contribute'_)
#* build workspace {{ssh://hg.opensolaris.org/hg/nv-g11n/g11n}}\#*\* clone the workspace
{code}
$ hg clone ssh://anon@hg.opensolaris.org/hg/nv-g11n/g11n
{code}
#** check structure of the workspace. Locale definition files are in directory {{../g11n/src/locale_src/}}
#** build the code [http://www.opensolaris.org/os/project/nv-g11n/documents/building/]
# Check the status of data for a new locale in CLDR
#* read the CLDR project description at [http://www.unicode.org/cldr/]
#* locale data can be viewed on-line in Survey Tool [http://www.unicode.org/cldr/survey_tool.html]
#* if you find that the data need to be fixed, submit a CLDR bug or contact [mailto:cldr-interest@sun.com]
#* the following categories are important for Solaris:
Other Items: all
Calendars: Gregorian
# Are you still sure you want to add new locale to Solaris? Yes? Great\! Please send mail to [mailto:i18n-discuss@opensolaris.org] that you working on the locale - installer/xkbd/input packages also need to be updated to complete the integration of the locale package
# Check that there is package for the new locale
#* locales are packed according to the language - all UTF-8 locales of one language are in one package.
#* prototype of the package is in {{../g11n/pkgmaps/prototype.lang-xx}} where '-xx' is the language code.
#* if the package does not exist, create it.
#** we are in the process of opening this process up, meantime please contact [mailto:Jan.Lana@Sun.COM] for help with this.
# update SUNWlang-xx
#* if you do not have write access to g11n workspace, you can send a patch to [mailto:g11n-opensolaris_ws-eng@sun.com]
(Mercurial Queues is great tool for this, see [http://hgbook.red-bean.com/hgbookch12.html])
#* add to {{../g11n/pkgmaps/prototype.lang-xx}}
{code}
d none usr 0755 root sys
d none usr/lib 0755 root bin
d none usr/lib/locale 0755 root bin
d none usr/lib/locale/xx_YY.UTF-8 0755 root bin
d none usr/lib/locale/xx_YY.UTF-8/LC_COLLATE 0755 root bin
d none usr/lib/locale/xx_YY.UTF-8/LC_CTYPE 0755 root bin
s none usr/lib/locale/xx_YY.UTF-8/LC_CTYPE/LCL_DEF=../../common/LC_CTYPE/LCL_DEF_unicode
s none usr/lib/locale/xx_YY.UTF-8/LC_CTYPE/ldterm.dat=../../common/LC_CTYPE/ldterm_unicode.dat
s none usr/lib/locale/xx_YY.UTF-8/LC_CTYPE/wdresolve.so=../../common/LC_CTYPE/wdresolve_unicode.so
d none usr/lib/locale/xx_YY.UTF-8/LC_MESSAGES 0755 root bin
d none usr/lib/locale/xx_YY.UTF-8/LC_MONETARY 0755 root bin
d none usr/lib/locale/xx_YY.UTF-8/LC_NUMERIC 0755 root bin
d none usr/lib/locale/xx_YY.UTF-8/LC_TIME 0755 root bin
f none usr/lib/locale/xx_YY.UTF-8/locale_description 0644 root bin
f none usr/lib/locale/xx_YY.UTF-8/locale_map 0644 root bin
d none usr/lib/locale/xx_YY.UTF-8/LO_LTYPE 0755 root bin
s none usr/lib/locale/xx_YY.UTF-8/LO_LTYPE/xx_YY.UTF-8.layout.so.1=../../common/LO_LTYPE/umle.layout.so.1
s none usr/lib/locale/xx_YY.UTF-8/methods_unicode.so.3=../common/methods_unicode.so.3
f none usr/lib/locale/xx_YY.UTF-8/xx_YY.UTF-8.so.3 0555 root bin
{code}
#* add to {{../g11n/pkgmaps/prototype.lang-xx.i386}}
{code}
d none usr 0755 root sys
d none usr/lib 0755 root bin
d none usr/lib/locale 0755 root bin
d none usr/lib/locale/xx_YY.UTF-8/amd64 0755 root bin
s none usr/lib/locale/xx_YY.UTF-8/amd64/methods_unicode.so.3=../../common/amd64/methods_unicode.so.3
f none usr/lib/locale/xx_YY.UTF-8/amd64/xx_YY.UTF-8.so.3 0555 root bin
{code}
#* add to {{../g11n/pkgmaps/prototype.lang-xx.isparc}}
{code}
d none usr 0755 root sys
d none usr/lib 0755 root bin
d none usr/lib/locale 0755 root bin
d none usr/lib/locale/xx_YY.UTF-8/sparcv9 0755 root bin
s none usr/lib/locale/xx_YY.UTF-8/amd64/methods_unicode.so.3=../../common/sparcv9/methods_unicode.so.3
f none usr/lib/locale/xx_YY.UTF-8/sparcv9/xx_YY.UTF-8.so.3 0555 root bin
{code}
#* create dir {{../g11n/src/lib/locale/xx_YY.UTF-8}} and in the dir
#** create file {{Makefile}}, model it on Makefile of another locale
#** create file {{locale_description}}, refer to [ISO 3166|http://www.iso.ch/iso/en/prods-services/iso3166ma/02iso-3166-code-lists/list-en1.html], example:
{code}
Ukraine (UTF-8)
{code}
#** create file {{locale_map}}
{code}
LC_COLLATE=xx_YY.UTF-8
LC_CTYPE=xx_YY.UTF-8
LC_MESSAGES=C
LC_MONETARY=xx_YY.UTF-8
LC_NUMERIC=xx_YY.UTF-8
LC_TIME=xx_YY.UTF-8
{code}
#* modify {{../g11n/src/lib/locale/Makefile{}}}add new locale to LOCALES
#* create {{../g11n/src/locale_src/base/xx_YY.UTF-8.localedef{}}}FIXME: write guide
#* modify {{../g11n/src/locale_src/base/Makefile{}}}add new locale to {{LOCALES_UTF8}}



h1. Following table lists locales which we are planning to add to Solaris system:

|| Territory || Locale || Bug IDs || Target Build ||
| Ukraine | uk_UA.UTF-8 | 6658916, 6658917 | nv_97 |
| Kazakh | kk_KZ.UTF-8 | 6695356, 6695363 | nv_97 |
| Belarus | be_BY.UTF-8 | | nv_107 |
| US | es_US.UTF-8 | | nv_107 |
| Georgia | ka_GE.UTF-8 | | nv_107 |
| South Africa\\ | af_ZA.UTF-8 | 6866911\\ | nv_123\\ |
| Italian (Swiss)\\ | it_CH.UTF-8 | 6866911\\ | nv_123 |
| Kyrgyzstan\\ | ky_KG.UTF-8 \\ | 6866911\\ | nv_123 |
| Azerbaijan \\ | az_AZ.UTF-8 | 6866911\\ | nv_123\\ |

The individuals who post here are part of the extended Sun Microsystems community and they might not be employed or in any way formally affiliated with Sun Microsystems. The opinions expressed here are their own, are not necessarily reviewed in advance by anyone but the individual authors, and neither Sun nor any other party necessarily agrees with them.

Copyright 1994-2009 Sun Microsystems, Inc.
Powered by Atlassian Confluence
Sun Guidelines on Public Discourse Privacy Policy Terms of Use Trademarks Site Map Employment Investor Relations Contact