HP-UX 11.0 - 11i Internationalization Features White Paper

Locales
Building Locales for HP-UX 11.0 and HP-UX 11i
Chapter 3
46
Building Locales for HP-UX 11.0 and HP-UX 11i
HP-UX 11.0 and HP-UX 11i systems can have up to three different flavors of the same locale:
32-bit
64-bit
HP-UX 10.20 compatibility 32-bit
The following sections present build requirements, briefly describe each flavor, and give the locale building
procedure. The locale zh_CN.utf8 is used as an example.
Requirements
Compiler
Building locales on HP-UX requires a C compiler named “HP C/ANSI C Developer's Bundle for HP-UX”. Run
the swlist command to verify that this compiler installed. Normally, this package is NOT shipped with
HP-UX systems.
Source Files
All needed files are normally shipped with the system to the following paths:
charmaps /usr/lib/nls/loc/charmaps/utf8.cm
method files /usr/lib/nls/loc/locales/univ.utf8.m
locale source /usr/lib/nls/loc/src/zh_CN.utf8.src
Kernel Configuration (needed for UTF8 locales only)
Building Unicode/UTF8 locales requires that the following kernel parameters be increased from 67 MB to
100 MB:
•MAXDSIZ
•MAXTSIZ
•SHMMAX
The Three Locale Flavors
Using the build syntax shown, locales are built in the local directory. After a locale is built, copy it to the path
shown.
32-bit Locales
•Located at /usr/lib/nls/loc/locales.2/zh_CN.utf8
Used by 32-bit HP-UX 11.0 and HP-UX 11i applications
To build, run the following command on a 32-bit machine:
localedef -C '+ESlit' -Q -L -x -Pcnf utf8.cm -m univ.utf8.m -i \
zh_CN.utf8.src zh_CN.utf8 > zh_CN.out 2> zh_CN.err
64-bit Locales
This flavor is found on 64-bit systems only.
•Located at /usr/lib/nls/loc/pa20_64/locales.2/zh_CN.utf8
Used by 64-bit HP-UX 11.0 and HP-UX 11i applications.