Museum

Home

Lab Overview

Retrotechnology Articles

Online Manuals

⇒ environ(5) — DG/UX 5.4.2A

Media Vault

Software Library

Restoration Projects

Artifacts Sought

Related Articles

chrtbl(1M)

colltbl(1M)

montbl(1M)

netconfig(4)

strftime(4)

passwd(4)

profile(4)

exec(2)

addseverity(3C)

catopen(3C)

ctime(3C)

ctype(3C)

fmtmsg(3C)

getdate(3C)

getenv(3C)

gettxt(3C)

localeconv(3C)

mbchar(3C)

mktime(3C)

printf(3C)

strcoll(3C)

strftime(3C)

strtod(3C)

strxfrm(3C)

strftime(4)

time(4)

timezone(4)

cat(1)

date(1)

ed(1)

gencat(1)

fmtmsg(1)

ls(1)

login(1)

mkmsgs(1)

nice(1)

nohup(1)

sh(1)

sort(1)

time(1)

vi(1)

zic(1)

getnetpath(3N)

environ(5)



environ(5)                       DG/UX 5.4.2                      environ(5)


NAME
       environ - user environment

DESCRIPTION
       When a process begins execution, exec routines make available an
       array of strings called the environment [see exec(2)].  By
       convention, these strings have the form variable=value, for example,
       PATH=/sbin:/usr/sbin.  These environmental variables provide a way to
       make information about a program's environment available to programs.
       The following environmental variables can be used by applications and
       are expected to be set in the target run-time environment.


       HOME        The name of the user's login directory, set by login(1)
                   from the password file (see passwd(4)).

       LANG        The string used to specify localization information that
                   allows users to work with different national conventions.
                   The setlocale(3C) function looks for the LANG environment
                   variable when it is called with "" as the locale
                   argument.  LANG is used as the default locale if the
                   corresponding environment variable for a particular
                   category is unset.
                   For example, when setlocale() is invoked as
                        setlocale(LCCTYPE, ""),
                   setlocale() will query the LCCTYPE environment variable
                   first to see if it is set and non-null.  If LCCTYPE is
                   not set or null, then setlocale() will check the LANG
                   environment variable to see if it is set and non-null.
                   If both LANG and LCCTYPE are unset or null, the default
                   C locale will be used to set the LCCTYPE category.
                   Most commands will invoke
                        setlocale(LCALL, "")
                   prior to any other processing.  This allows the command
                   to be used with different national conventions by setting
                   the appropriate environment variables.
                   The system-wide default value for LANG can be changed
                   with the sysadm(1M) command.
                   The following environment variables are supported to
                   correspond with each category of setlocale(3C):

                   LCCOLLATE     This category specifies the collation
                                  sequence being used.  The information
                                  corresponding to this category is stored
                                  in a database created by the colltbl(1M)
                                  command.  This environment variable
                                  affects strcoll(3C), strxfrm(3C) and the
                                  regular expression code (see regexpr(3C)).

                   LCCTYPE       This category specifies character
                                  classification, character conversion, and
                                  widths of multibyte characters.  The
                                  information corresponding to this category
                                  is stored in a database created by the



Licensed material--property of copyright holder(s)                         1




environ(5)                       DG/UX 5.4.2                      environ(5)


                                  chrtbl(1M) command.  The default C locale
                                  corresponds to the 7-bit ASCII character
                                  set.  This environment variable is used by
                                  ctype(3C), mbchar(3C), and many commands;
                                  for example: cat(1), ed(1), ls(1), and
                                  vi(1).

                   LCMESSAGES    This category specifies the language of
                                  the AT&T-style message database being
                                  used.  For example, an application may
                                  have one message database with French
                                  messages, and another database with German
                                  messages.  Message databases are created
                                  by the mkmsgs(1M) command.  This
                                  environment variable is used by exstr(1),
                                  gettxt(1), gettxt(3C), and srchtxt(1).
                                  The X/Open-style message facility does not
                                  use this variable.

                   LCMONETARY    This category specifies the monetary
                                  symbols and delimiters used for a
                                  particular locale.  The information
                                  corresponding to this category is stored
                                  in a database created by the montbl(1M)
                                  command.  This environment variable is
                                  used by localeconv(3C).

                   LCNUMERIC     This category specifies the decimal and
                                  thousands delimiters.  The information
                                  corresponding to this category is stored
                                  in a database created by the chrtbl(1M)
                                  command.  The default C locale corresponds
                                  to "." as the decimal delimiter and no
                                  thousands delimiter.  This environment
                                  variable is used by localeconv(3C),
                                  printf(3C), and strtod(3C).

                   LCTIME        This category specifies date and time
                                  formats.  The information corresponding to
                                  this category is stored in a database
                                  specified in strftime(4).  The default C
                                  locale corresponds to U.S. date and time
                                  formats.  This environment variable is
                                  used by many commands and functions; for
                                  example: at(1), calendar(1), date(1),
                                  strftime(3C), and getdate(3C).

       MSGVERB     Controls which standard format message components fmtmsg
                   selects when messages are displayed to stderr [see
                   fmtmsg(1) and fmtmsg(3C)].

       SEVLEVEL   Define severity levels and associate and print strings
                   with them in standard format error messages [see
                   addseverity(3C), fmtmsg(1), and fmtmsg(3C)].



Licensed material--property of copyright holder(s)                         2




environ(5)                       DG/UX 5.4.2                      environ(5)


       NETPATH     A colon-separated list of network identifiers.  A network
                   identifier is a character string used by the Network
                   Selection component of the system to provide application-
                   specific default network search paths.  A network
                   identifier must consist of non-NULL characters and must
                   have a length of at least 1.  No maximum length is
                   specified.  Network identifiers are normally chosen by
                   the system administrator.  A network identifier is also
                   the first field in any /etc/netconfig file entry.
                   NETPATH thus provides a link into the /etc/netconfig file
                   and the information about a network contained in that
                   network's entry.  /etc/netconfig is maintained by the
                   system administrator.  The library routines described in
                   getnetpath(3N) access the NETPATH environment variable.

       NLSPATH     Contains a sequence of templates which the X/Open-style
                   message facility uses when attempting to locate message
                   catalogs (see catopen(3C)).  The AT&T-style message
                   facility does not use this variable.  Each template
                   consists of an optional prefix, one or more substitution
                   fields, a filename and an optional suffix.
                   For example:
                        NLSPATH="/usr/lib/nls/msg/%N.cat"
                   defines that catopen() should look for all message
                   catalogs in the directory /usr/lib/nls/msg, where the
                   catalog name should be constructed from the name
                   parameter passed to catopen(), %N, with the suffix .cat.

                   Substitution fields consist of a % symbol, followed by a
                   single-letter keyword.  The following keywords are
                   currently defined:
                            +--------------------------------------+
                            |%N   The value of the name parameter  |
                            |     passed to catopen().             |
                            |%L   The value of LANG.               |
                            |%l   The language element from LANG.  |
                            |%t   The territory element from LANG. |
                            |%c   The codeset element from LANG.   |
                            |%%   A single % character.            |
                   An empty +
s
-
t
-
r
-
i
π-
g
--
i
-
s
--
s
-
u
-
b
-
s
-
t
-
i
-
t
-
u
-
t
-
e
-
d
--
i
-
f
--
t
ℏ-
e
--
s
-
p
-
e
-
c
-
i
-
f
-
i
-
e
-
d
-+
v
alue is not currently defined. The separators ``'' and ``.'' are not included in %t and %c substitutions. Templates defined in NLSPATH are separated by colons (:). A leading colon or two adjacent colons (::) is equivalent to specifying %N. For example: NLSPATH=":%N.cat:/usr/lib/nls/msg/%L/%N.cat" indicates to catopen() that it should look for the requested message catalog in name, name.cat and /usr/lib/nls/msg/$LANG/name.cat. The system-wide default value for NLSPATH can be changed with the sysadm(1M) command. Licensed material--property of copyright holder(s) 3


environ(5)                       DG/UX 5.4.2                      environ(5)


       PATH        The sequence of directory prefixes that sh(1), time(1),
                   nice(1), nohup(1), etc., apply in searching for a file
                   known by an incomplete path name.  The prefixes are
                   separated by colons (:).  login(1) sets PATH=/usr/bin.
                   (For more detail, see sh(1).)

       TERM        The kind of terminal for which output is to be prepared.
                   This information is used by commands, such as vi(1),
                   which may exploit special capabilities of that terminal.

       CFTIME      Historically, the default format string to be used by the
                   date(1) command and the ascftime() and cftime() routines
                   (see strftime(3C)).  If CFTIME is not set or is null, the
                   default format string specified in the
                   /lib/cftime/LANGUAGE file (if it exists) is used in its
                   place (see cftime(4)).  The use of CFTIME has generally
                   been subsumed by LANG and LCTIME.

       CHRCLASS    Historically, a value that corresponds to a file in
                   /lib/chrclass containing character classification and
                   conversion information.  This information was used by
                   commands (such as cat(1), ed(1), and sort(1)) to classify
                   characters as alphabetic, printable, upper case, and so
                   on, and to convert characters to upper or lower case.
                   The use of CHRCLASS has generally been subsumed by LANGF1
                   and LCCTYPE.  For more detail, see ctype(3C).

       LANGUAGE    Historically, a language for which a printable file by
                   that name exists in /lib/cftime.  This information was
                   used by commands (such as date(1), ls(1), and sort(1)) to
                   print date and time information in the language
                   specified.  The use of LANGUAGE has generally been
                   subsumed by LANG and LCTIME.

       TZ          Time zone information.  The contents of the environment
                   variable named TZ are used by the functions ctime(3C),
                   localtime() (see ctime(3C)), strftime(3C) ascftime() (see
                   strftime(3C)), cftime() (see strftime(3C)), and
                   mktime(3C) to override the default timezone.  The value
                   of TZ has one of the two forms (spaces inserted for
                   clarity):
                   :characters
                   or:
                   std offset dst offset, rule

                   If TZ is of the first format (i.e., if the first
                   character is a colon), the string following the colon is
                   the name of the timezone that will be loaded in from the
                   /usr/lib/locale/TZ directory.  For example, if TZ was set
                   to :US/Eastern, it would load the
                   /usr/lib/local/TZ/US/Eastern timezone definition file.
                   The timezones under this directory are produced with the
                   zic(1) command.




Licensed material--property of copyright holder(s)                         4




environ(5)                       DG/UX 5.4.2                      environ(5)


                   The expanded format (for all TZs whose value does not
                   have a colon as the first character) is as follows:

                   stdoffset[dst[offset],[start[/time],end[/time]]]

                   Where:

                   std and dst
                          Three or more bytes that are the designation for
                          the standard (std) and daylight savings time (dst)
                          timezones.  Only std is required, if dst is
                          missing, then daylight savings time does not apply
                          in this locale.  Upper- and lower-case letters are
                          allowed.  Any characters except a leading colon
                          (:), digits, a comma (,), a minus (-), a plus (+),
                          or an ASCII NUL are allowed.

                   offset Indicates the value one must add to the local time
                          to arrive at Coordinated Universal Time.  The
                          offset has the form:
                          hh[:mm[:ss]]

                          The minutes (mm) and seconds (ss) are optional.
                          The hour (hh) is required and may be a single
                          digit.  The offset following std is required.  If
                          no offset follows dst , daylight savings time is
                          assumed to be one hour ahead of standard time.
                          One or more digits may be used; the value is
                          always interpreted as a decimal number.  The hour
                          must be between 0 and 24, and the minutes (and
                          seconds) if present between 0 and 59.  Out of
                          range values may cause unpredictable behavior.  If
                          preceded by a ``-'', the timezone is east of the
                          Prime Meridian; otherwise it is west (which may be
                          indicated by an optional preceding ``+'' sign).

                   rule   Indicates when to change to and back from summer
                          time.  The rule has the form:
                          start/time,end/time

                          Which indicates when to change to and back from
                          daylight savings time, where start/time describes
                          when the change from standard time to daylight
                          savings time occurs, and end/time describes when
                          the change back happens.  Each time field
                          describes when, in current local time, the change
                          is made.

                          The formats of start and end are one of the
                          following:

                          Jn     The Julian day n (1 < n < 365).  Leap days
                                 are not counted.  That is, in all years,
                                 February 28 is day 59 and March 1 is day



Licensed material--property of copyright holder(s)                         5




environ(5)                       DG/UX 5.4.2                      environ(5)


                                 60.  It is impossible to refer to the
                                 occasional February 29.

                          n      The zero-based Julian day (0 < n < 365).
                                 Leap days are counted, and it is possible
                                 to refer to February 29.

                          Mm.n.d The dth day, (0 < d < 6) of week n of month
                                 m of the year (1 < n < 5, 1 < m < 12),
                                 where week 5 means ``the last d-day in
                                 month m'' which may occur in either the
                                 fourth or the fifth week).  Week 1 is the
                                 first week in which the dth day occurs.
                                 Day zero is Sunday.

                          The time has the same format as offset except that
                          no leading sign (``-'' or ``+'') is allowed.  The
                          default, if time is not given is 02:00:00.

       Further names may be placed in the environment by the export command
       and name=value arguments in sh(1), or by exec(2).  It is unwise to
       conflict with certain shell variables that are frequently exported by
       .profile files: MAIL, PS1, PS2, IFS (see profile(4)).

       Whenever ascftime(), cftime(), ctime(), localtime(), mktime(), or
       strftime() is called, the time zone names contained in the external
       variable tzname() shall be set as if the tzset() function had been
       called.

       Applications are explicitly allowed to change TZ and have the changed
       TZ apply to themselves.

       The system-wide default value for TZ can be changed with the
       sysadm(1M) command.

       NOTE:  There is an unfortunate potential for confusion with time
              zones identified by an offset from GMT.  The TZ value GMT+5,
              according to the rules presented here, is equivalent to EST5
              -- 5 hours West of GTM.  There is also a timezone definition
              file that can be used by setting TZ to :GMT+5, but this file
              defines the time zone 5 hours East of GMT.  Existing practice
              requires that both these notations be supported.

SEE ALSO
       chrtbl(1M), colltbl(1M), montbl(1M), netconfig(4), strftime(4),
       passwd(4), profile(4).
       exec(2), addseverity(3C), catopen(3C), ctime(3C), ctype(3C),
       fmtmsg(3C), getdate(3C), getenv(3C), gettxt(3C), localeconv(3C),
       mbchar(3C), mktime(3C), printf(3C), strcoll(3C), strftime(3C),
       strtod(3C), strxfrm(3C), strftime(4), time(4), timezone(4).
       cat(1), date(1), ed(1), gencat(1), fmtmsg(1),  ls(1), login(1),
       mkmsgs(1), nice(1), nohup(1), sh(1), sort(1), time(1), vi(1), zic(1).
       getnetpath(3N), in the Programmer's Guide: Networking Interfaces.




Licensed material--property of copyright holder(s)                         6




environ(5)                       DG/UX 5.4.2                      environ(5)


COPYRIGHTS
       Portions of this text are reprinted from IEEE Std 1003.1-1988,
       Portable Operating System Interface for Computer Environment,
       copyright © 1988 by the Institute of Electrical and Electronics
       Engineers, Inc., with the permission of the IEEE Standards
       Department.  To purchase IEEE Standards, call 800/678-IEEE.

       In the event of a discrepancy between the electronic and the original
       printed version, the original version takes precedence.
















































Licensed material--property of copyright holder(s)                         7


Typewritten Software • bear@typewritten.org • Edmonds, WA 98026