summaryrefslogtreecommitdiffstats
path: root/man7/environ.7
diff options
context:
space:
mode:
Diffstat (limited to 'man7/environ.7')
-rw-r--r--man7/environ.7110
1 files changed, 55 insertions, 55 deletions
diff --git a/man7/environ.7 b/man7/environ.7
index f98359a3f..de81c2a2c 100644
--- a/man7/environ.7
+++ b/man7/environ.7
@@ -25,10 +25,10 @@ The variable
points to an array of pointers to strings called the "environment".
The last pointer in this array has the value NULL.
This array of strings is made available to the process by the
-.BR execve (2)
+.MR execve 2
call when a new program is started.
When a child process is created via
-.BR fork (2),
+.MR fork 2 ,
it inherits a
.I copy
of its parent's environment.
@@ -45,19 +45,19 @@ since this is assumed to terminate the string.
Environment variables may be placed in the shell's environment by the
.I export
command in
-.BR sh (1),
+.MR sh 1 ,
or by the
.I setenv
command if you use
-.BR csh (1).
+.MR csh 1 .
.P
The initial environment of the shell is populated in various ways,
such as definitions from
.I /etc/environment
that are processed by
-.BR pam_env (8)
+.MR pam_env 8
for all users at login time (on systems that employ
-.BR pam (8)).
+.MR pam 8 ).
In addition, various shell initialization scripts, such as the system-wide
.I /etc/profile
script and per-user initializations script may include commands
@@ -80,13 +80,13 @@ Multiple variable definitions, separated by white space, may precede
.P
Arguments may also be placed in the
environment at the point of an
-.BR exec (3).
+.MR exec 3 .
A C program can manipulate its environment using the functions
-.BR getenv (3),
-.BR putenv (3),
-.BR setenv (3),
+.MR getenv 3 ,
+.MR putenv 3 ,
+.MR setenv 3 ,
and
-.BR unsetenv (3).
+.MR unsetenv 3 .
.P
What follows is a list of environment variables typically seen on a
system.
@@ -120,14 +120,14 @@ or more specific environment variables such as
and
.B LC_TIME
(see
-.BR locale (7)
+.MR locale 7
for further details of the
.B LC_*
environment variables).
.TP
.B PATH
The sequence of directory prefixes that
-.BR sh (1)
+.MR sh 1
and many other
programs employ when searching for an executable file that is specified
as a simple filename (i.a., a pathname that contains no slashes).
@@ -154,7 +154,7 @@ used by some shells to find the target
of a change directory command,
.B MANPATH
used by
-.BR man (1)
+.MR man 1
to find manual pages, and so on.
.TP
.B PWD
@@ -181,9 +181,9 @@ If
.B PAGER
is null or is not set,
then applications that launch a pager will default to a program such as
-.BR less (1)
+.MR less 1
or
-.BR more (1).
+.MR more 1 .
.TP
.BR EDITOR / VISUAL
The user's preferred utility to edit text files.
@@ -203,16 +203,16 @@ The variables
.BR LANG ", " LANGUAGE ", " NLSPATH ", " LOCPATH ,
.BR LC_ALL ", " LC_MESSAGES ,
and so on influence locale handling; see
-.BR catopen (3),
-.BR gettext (3),
+.MR catopen 3 ,
+.MR gettext 3 ,
and
-.BR locale (7).
+.MR locale 7 .
.IP \[bu]
.B TMPDIR
influences the path prefix of names created by
-.BR tempnam (3)
+.MR tempnam 3
and other routines, and the temporary directory used by
-.BR sort (1)
+.MR sort 1
and other programs.
.IP \[bu]
.BR LD_LIBRARY_PATH ", " LD_PRELOAD ,
@@ -220,14 +220,14 @@ and other
.B LD_*
variables influence the behavior of the dynamic loader/linker.
See also
-.BR ld.so (8).
+.MR ld.so 8 .
.IP \[bu]
.B POSIXLY_CORRECT
makes certain programs and library routines follow
the prescriptions of POSIX.
.IP \[bu]
The behavior of
-.BR malloc (3)
+.MR malloc 3
is influenced by
.B MALLOC_*
variables.
@@ -236,18 +236,18 @@ The variable
.B HOSTALIASES
gives the name of a file containing aliases
to be used with
-.BR gethostbyname (3).
+.MR gethostbyname 3 .
.IP \[bu]
.BR TZ " and " TZDIR
give timezone information used by
-.BR tzset (3)
+.MR tzset 3
and through that by functions like
-.BR ctime (3),
-.BR localtime (3),
-.BR mktime (3),
-.BR strftime (3).
+.MR ctime 3 ,
+.MR localtime 3 ,
+.MR mktime 3 ,
+.MR strftime 3 .
See also
-.BR tzselect (8).
+.MR tzselect 8 .
.IP \[bu]
.B TERMCAP
gives information on how to address a given terminal
@@ -259,7 +259,7 @@ tell applications about the window size, possibly overriding the actual size.
.BR PRINTER " or " LPDEST
may specify the desired printer to use.
See
-.BR lpr (1).
+.MR lpr 1 .
.SH NOTES
Historically and by standard,
.I environ
@@ -271,10 +271,10 @@ is declared in the header file
if the
.B _GNU_SOURCE
feature test macro is defined (see
-.BR feature_test_macros (7)).
+.MR feature_test_macros 7 ).
.P
The
-.BR prctl (2)
+.MR prctl 2
.B PR_SET_MM_ENV_START
and
.B PR_SET_MM_ENV_END
@@ -288,17 +288,17 @@ and
.B USER
variables are set when the user is changed via a
session management interface, typically by a program such as
-.BR login (1)
+.MR login 1
from a user database (such as
-.BR passwd (5)).
+.MR passwd 5 ).
(Switching to the root user using
-.BR su (1)
+.MR su 1
may result in a mixed environment where
.B LOGNAME
and
.B USER
are retained from old user; see the
-.BR su (1)
+.MR su 1
manual page.)
.SH BUGS
Clearly there is a security risk here.
@@ -334,21 +334,21 @@ and
Such usage is considered mistaken, and to be avoided in new
programs.
.SH SEE ALSO
-.BR bash (1),
-.BR csh (1),
-.BR env (1),
-.BR login (1),
-.BR printenv (1),
-.BR sh (1),
-.BR su (1),
-.BR tcsh (1),
-.BR execve (2),
-.BR clearenv (3),
-.BR exec (3),
-.BR getenv (3),
-.BR putenv (3),
-.BR setenv (3),
-.BR unsetenv (3),
-.BR locale (7),
-.BR ld.so (8),
-.BR pam_env (8)
+.MR bash 1 ,
+.MR csh 1 ,
+.MR env 1 ,
+.MR login 1 ,
+.MR printenv 1 ,
+.MR sh 1 ,
+.MR su 1 ,
+.MR tcsh 1 ,
+.MR execve 2 ,
+.MR clearenv 3 ,
+.MR exec 3 ,
+.MR getenv 3 ,
+.MR putenv 3 ,
+.MR setenv 3 ,
+.MR unsetenv 3 ,
+.MR locale 7 ,
+.MR ld.so 8 ,
+.MR pam_env 8