README
author jenda
Fri, 29 Jul 2011 14:07:04 +0200
changeset 142 da26b9f833de
parent 59 110e62b60da3
permissions -rw-r--r--
7068147 removing CDDL from copies of source/text files delivered to the binary product


OPENSOLARIS.ORG G11N LOCALE WORKSPACE
=====================================

This file describes the structure and contains the instructions for
downloading and building the G11n Locale workspace for OpenSolaris.


Description of the Workspace
----------------------------

This workspace is a part of G11n Common Workspace (CWS). Along with other parts
it allows to build all OpenSolaris.org G11n packages. See build instructions at:
  http://www.opensolaris.org/os/project/nv-g11n/documents/building/

The workspace allows to compile OpenSolaris locale data objects (locales) based
on the CLDR data (http://cldr.unicode.org/). This workspace does not contain the
upstream sources and tools. The sources are downloaded during the build process,
so internet access is required to build the workspace.


Structure of the Workspace
--------------------------

./Makefile		master makefile

./downloads/		all data downloaded from internet, 
			'make clean' does not clean this directory
			some are built from upstream

./locales/*.spec	locale spec files (see 'Locale Spec File Structure' section)

./misc/			misc files for locale object generation

./misc/mk/		makefiles for the workspace

./misc/patches/		patches of upstream code

./misc/patches/cldr_core/	patches of CLDR locale data, 
			fix known bugs or add solaris specific code

./misc/patches/cldr_tools/	patches of CLDR tools, 
			fix known bugs and add solaris specific code

./misc/templates/prototype/	prototypes templates

./misc/templates/manifest/	manifest templates

./misc/templates/locale_map/	locale_map templates

./tools			tools used for build

(./build)		all build files are created in the dir
			(the dir is created during the build process,
			'make clean' = rm -Rf ./build)


Locale Specification File Structure
-----------------------------------

Locale is described by files locale/*.spec. The files are named:
	locales/xx_YY.eee[@variant].spec

Format of the files is:
	# comments ...
	<key>TAB+<data>

If a key is missing default value is used. The default value is perfect for
most of the locales, so for ordinary locales the file is empty.


Keys:
	pkg_name	pkg name for the locale
			default: 'lang-xx'

	cldr_variant	cldr locale variant, see XXX for description
			default: 'xx_YY'

	locale_desc	locale description (/usr/lib/locales/<loc>/locale_description file)
			default: 'Language, Country (Encoding)'

	prototype	pkg prototype 
			default: 'utf8'

	manifest	ips manifest
			default: 'header,utf8'
	
	locale_map	locale_map (/usr/lib/locale/<loc>/locale_mask file)
			default: 'default'

	


Build Instructions
------------------

The following build instructions are for OpenSolaris 2009.06 (and later).
Building on older versions of Solaris/OpenSolaris is possible, but there
would be difference in installation of the build tools.


Prepare the build environment:

 $ pfexec pkg install SUNWmercurial SUNWgmake SUNWant sunstudio
 $ # 'pfexec svccfg -s application/pkg/server setprop pkg/port=10000' 
 $ # 	or 'export PKG_REPO=http://localhost:80'
 $ # pfexec svccfg -s application/pkg/server setprop pkg/inst_root=/export/home/tester/repository
 $ pfexec svcadm refresh application/pkg/server
 $ pfexec svcadm restart pkg/server

 $ hg clone ssh://[email protected]/hg/nv-g11n/locale g11n-locale
 $ cd g11n-locale


Build the workspace:
 
 $ gmake		(use '-j X', where X=#CPU+1 on multicore machines) 


Test the pkgs:

 $ gmake ips
 $ pfexec pkg install SUNWlang-xx