Installation guide

command is the same as the ULTRIX gencat command. The mkcatdefs
command is the same on both systems.
6.10.1.4 Routines for Accessing a Message Catalog (catopen, catgets, and
catclose)
You use the DIGITAL UNIX catopen, catgets, and catclose library
routines to open, read messages from, and close message catalogs. These
routines are the same as the ULTRIX routines of the same names.
By default, these routines search the /usr/lib/nls/msg/
%L
/
%N
path for
a message catalog. In the preceding pathname,
%L
represents the locale
name specified by the LANG environment variable, and
%N
represents the
name of the message catalog passed to the catopen function. Typically, the
name of the message catalog is messages.cat.
The DIGITAL UNIX catopen routine differs from the ULTRIX catopen
routine in two ways. First, the DIGITAL UNIX catopen routine does not
search the current directory for message catalogs. The ULTRIX catopen
routine searches the current directory for message catalogs it does not find
in either the /usr/lib/nls/msg/
%L
/
%N
directory or the directories
specified by the NLSPATH environment variable. Second, the DIGITAL
UNIX catopen routine ignores the NLSPATH environment variable when it
attempts to find a message catalog for the root user. The routine searches
only the /usr/lib/nls/msg/
%L
/
%N
directory. This difference affects
applications that use the setuid system call to become the root user.
6.10.2 Program Localization
Writing an international application involves more than isolating and
translating program messages. The application must also reflect the
culture of the user by displaying dates and times, monetary values,
numbers, alphabetic lists, and so on in the style that the user expects. On
DIGITAL UNIX systems (as on ULTRIX systems), the application behavior
in these areas is controlled by the program’s locale.
6.10.2.1 Announcement Mechanism
You control which locale an application runs in by defining environment
variables. The environment variables announce to the system what local
data the application should use.
The DIGITAL UNIX system provides the same environment variables as
the ULTRIX system, with the addition of LC_ALL and LC_MESSAGES. The
following list describes these environment variables:
Overview of the DIGITAL UNIX Programming Environment 6–21