diff options
author | sandra <sandra> | 1991-08-09 17:12:22 +0000 |
---|---|---|
committer | sandra <sandra> | 1991-08-09 17:12:22 +0000 |
commit | c3ffbb18b740146cd24ab3cee7d5ad1f02b604f1 (patch) | |
tree | 024d68cea6fccbe8022ea2ce75e1d3982c1ac8ee /manual/=process.texinfo | |
parent | 684c71922001b419e5f54cc3d4d1be2b743206b0 (diff) | |
download | glibc-c3ffbb18b740146cd24ab3cee7d5ad1f02b604f1.tar.gz glibc-c3ffbb18b740146cd24ab3cee7d5ad1f02b604f1.tar.xz glibc-c3ffbb18b740146cd24ab3cee7d5ad1f02b604f1.zip |
Move system configuration parameter stuff to new chapter.
Diffstat (limited to 'manual/=process.texinfo')
-rw-r--r-- | manual/=process.texinfo | 307 |
1 files changed, 9 insertions, 298 deletions
diff --git a/manual/=process.texinfo b/manual/=process.texinfo index a65f1e05a9..7fe7f0b947 100644 --- a/manual/=process.texinfo +++ b/manual/=process.texinfo @@ -15,6 +15,8 @@ This chapter describes how you can create and terminate processes and control their attributes. @menu +* Program Argument Parsing:: Parsing the command-line arguments to + a program * Environment Variables:: How to access parameters inherited from a parent process. * Program Termination:: How to cause a process to terminate and @@ -23,11 +25,16 @@ control their attributes. * User/Group IDs of a Process:: Controlling what privileges your program has. * Process Information:: Miscellaneous functions for inquiring about the execution environment of a process. -* System Parameters:: Constants and functions that describe - various process-related limits. @end menu +@node Program Argument Parsing +@section Program Argument Parsing + +@strong{Incomplete:} Put the description of the POSIX.2 @code{getopt} +function here. + + @node Environment Variables @section Environment Variables @@ -1681,299 +1688,3 @@ returned by @code{ctermid}. See also the @code{isatty} and @code{ttyname} functions, in @ref{Terminal Identification}. - -@node System Parameters -@section System Parameters - -The POSIX.1 standard specifies a number of symbolic constants that -represent the values for certain system limits, such as the maximum -number of simultaneous processes per user. However, some of these -limits might not really be constant in a given implementation. In a -typical Unix environment, for example, the values are determined from a -configuration file used in building the operating system kernel, and can -be changed without invalidating already-compiled programs by rebooting -the machine with a different kernel. Other parameters might depend on -the amount of memory available. - -In order to deal with the problem of variable limits, for most of these -parameters there is one symbolic constant that defines the most -restrictive limit permissible by the POSIX standard. If the actual -limit placed by a particular implementation for that parameter is a -constant, then it defines another symbolic constant to represent it. -Otherwise, the actual limit can be requested at runtime by calling the -@code{sysconf} function. - -Definitions for the following macros appear in the header file -@file{<limits.h>}. The values of the macros are all integer constants. - -@strong{Incomplete:} What does the GNU system do for the -implementation-defined macros? - -@comment limits.h -@comment POSIX.1 -@defvr Macro _POSIX_ARG_MAX -The value of this macro is the most restrictive limit permitted by POSIX -for the maximum combined length of the @var{argv} and @var{environ} -arguments that can be passed to the @code{exec} functions. The value of -this constant is @code{4096}. -@end defvr - -@comment limits.h -@comment POSIX.1 -@defvr Macro ARG_MAX -This is the actual implementation limit corresponding to -@code{_POSIX_ARG_MAX}, but is defined only if the limit for the -particular implementation is a constant. -@end defvr - -@comment limits.h -@comment POSIX.1 -@defvr Macro _POSIX_CHILD_MAX -The value of this macro is the most restrictive limit permitted by POSIX -for the maximum number of simultaneous processes per real user ID. Its -value is @code{6}. -@end defvr - -@comment limits.h -@comment POSIX.1 -@defvr Macro CHILD_MAX -This is the actual implementation limit corresponding to -@code{_POSIX_CHILD_MAX}, but is defined only if the limit for the -particular implementation is a constant. -@end defvr - -@comment limits.h -@comment POSIX.1 -@defvr Macro _POSIX_OPEN_MAX -The value of this macro is the most restrictive limit permitted by POSIX -for the maximum number of files that a single process can have open -simultaneously. The value of this constant is @code{16}. -@end defvr - -@comment limits.h -@comment POSIX.1 -@defvr Macro OPEN_MAX -This is the actual implementation limit corresponding to -@code{_POSIX_OPEN_MAX}, but is defined only if the limit for the -particular implementation is a constant. -@end defvr - -@comment limits.h -@comment POSIX.1 -@defvr Macro _POSIX_STREAM_MAX -The value of this macro is the most restrictive limit permitted by POSIX -for the maximum number of streams that a single process can have open -simultaneously. The value of this constant is @code{8}. -@end defvr - -@comment limits.h -@comment POSIX.1 -@defvr Macro STREAM_MAX -This is the actual implementation limit corresponding to -@code{_POSIX_STREAM_MAX}, but is defined only if the limit for the -particular implementation is a constant. -@end defvr - -@comment limits.h -@comment POSIX.1 -@defvr Macro _POSIX_TZNAME_MAX -The value of this macro is the most restrictive limit permitted by POSIX -for the maximum length of a time zone name. The value of this constant -is @code{3}. -@end defvr - -@comment limits.h -@comment POSIX.1 -@defvr Macro TZNAME_MAX -This is the actual implementation limit corresponding to -@code{_POSIX_TZNAME_MAX}, but is defined only if the limit for the -particular implementation is a constant. -@end defvr - -@comment limits.h -@comment POSIX.1 -@defvr Macro _POSIX_NGROUPS_MAX -The value of this macro is the most restrictive limit permitted by POSIX -for the maximum number of supplementary group IDs per process. The -value of the constant is @code{0}. -@end defvr - -@comment limits.h -@comment POSIX.1 -@defvr Macro NGROUPS_MAX -This corresponds to @code{_POSIX_NGROUPS_MAX}, but represents the -minimum value guaranteed by the implementation. This macro is defined -even if the limit for the particular implementation is not a constant. -(The actual maximum might be larger, and can be accessed with the -@code{sysconf} function.) -@end defvr - -@comment limits.h -@comment POSIX.1 -@defvr Macro _POSIX_SSIZE_MAX -The value of this macro is the most restrictive limit permitted by POSIX -for the maximum value that can be stored in an object of type @code{ssize_t}. -(Effectively, this is the limit on the number of bytes that can be read -or written in a single operation. The value of this constant is -@code{32767}. -@end defvr - -@comment limits.h -@comment POSIX.1 -@defvr Macro SSIZE_MAX -This is the actual implementation limit corresponding to -@code{_POSIX_SSIZE_MAX}. This macro is always defined and its value is -a constant within a given implementation. -@end defvr - -Definitions for these additional macros that describe system parameters -appear in the header file @file{<unistd.h>}. - -@comment unistd.h -@comment POSIX.1 -@defvr Macro _POSIX_JOB_CONTROL -If this symbol is defined, it indicates that the system supports job -control. Otherwise, the implementation behaves as if all processes -within a session belong to a single process group. @xref{Job Control}. -@end defvr - -@comment unistd.h -@comment POSIX.1 -@defvr Macro _POSIX_SAVED_IDS -If this symbol is defined, it indicates that the system remembers the -effective user and group IDs of an executable file with the set-user-ID -or set-group-ID bits set, and that explicitly changing the effective -user or group IDs back to these values is permitted. If this option is -not defined, then if a nonprivileged process changes its effective user -or group ID to the real user or group ID of the process, it can't change -it back again. @xref{User/Group IDs of a Process}. -@end defvr - -@comment unistd.h -@comment POSIX.1 -@defvr Macro _POSIX_VERSION -This constant represents the version of the POSIX standard to which -the implementation conforms. For an implementation conforming to the -1990 POSIX.1 standard, the value is the integer @code{199009L}. -@end defvr - -You can request the actual runtime values of these parameters using the -@code{sysconf} function. This function and the macros for use as its -@var{parameter} argument are declared in the header file -@file{<unistd.h>}. - -@comment unistd.h -@comment POSIX.1 -@deftypefun long sysconf (int @var{parameter}) -This function is used to inquire about runtime system parameters. -The @var{parameter} argument can be one of the following: - -@table @code -@item _SC_ARG_MAX -Return the value corresponding to @code{ARG_MAX}. - -@item _SC_CHILD_MAX -Return the value corresponding to @code{CHILD_MAX}. - -@item _SC_OPEN_MAX -Return the value corresponding to @code{OPEN_MAX}. - -@item _SC_STREAM_MAX -Return the value corresponding to @code{STREAM_MAX}. - -@item _SC_TZNAME_MAX -Return the value corresponding to @code{TZNAME_MAX}. - -@item _SC_NGROUPS_MAX -Return the value corresponding to @code{NGROUPS_MAX}. - -@item _SC_JOB_CONTROL -Return the value corresponding to @code{_POSIX_JOB_CONTROL}. - -@item _SC_SAVED_IDS -Return the value corresponding to @code{_POSIX_SAVED_IDS}. - -@item _SC_VERSION -Return the value corresponding to @code{_POSIX_VERSION}. - -@item _SC_CLK_TCK -Return the value corresponding to @code{CLOCKS_PER_SEC}. -@end table - -The normal return value from @code{sysconf} is the value you requested. -A value of @code{-1} is returned both if the implementation does not -impose a limit, and in case of an error. - -The following @code{errno} error conditions are defined for this function: -@table @code -@item EINVAL -The value of the @var{parameter} is invalid. -@end table -@end deftypefun - -These symbolic constants are defined for use as the @var{parameter} -argument to @code{sysconf}. The values are all integer constants. - -@comment unistd.h -@comment POSIX.1 -@defvr Macro _SC_ARG_MAX -Inquire about the parameter corresponding to @code{ARG_MAX}. -@end defvr - -@comment unistd.h -@comment POSIX.1 -@defvr Macro _SC_CHILD_MAX -Inquire about the parameter corresponding to @code{CHILD_MAX}. -@end defvr - -@comment unistd.h -@comment POSIX.1 -@defvr Macro _SC_OPEN_MAX -Inquire about the parameter corresponding to @code{OPEN_MAX}. -@end defvr - -@comment unistd.h -@comment POSIX.1 -@defvr Macro _SC_STREAM_MAX -Inquire about the parameter corresponding to @code{STREAM_MAX}. -@end defvr - -@comment unistd.h -@comment POSIX.1 -@defvr Macro _SC_TZNAME_MAX -Inquire about the parameter corresponding to @code{TZNAME_MAX}. -@end defvr - -@comment unistd.h -@comment POSIX.1 -@defvr Macro _SC_NGROUPS_MAX -Inquire about the parameter corresponding to @code{NGROUPS_MAX}. -@end defvr - -@comment unistd.h -@comment POSIX.1 -@defvr Macro _SC_JOB_CONTROL -Inquire about the parameter corresponding to @code{_POSIX_JOB_CONTROL}. -@end defvr - -@comment unistd.h -@comment POSIX.1 -@defvr Macro _SC_SAVED_IDS -Inquire about the parameter corresponding to @code{_POSIX_SAVED_IDS}. -@end defvr - -@comment unistd.h -@comment POSIX.1 -@defvr Macro _SC_VERSION -Inquire about the parameter corresponding to @code{_POSIX_VERSION}. -@end defvr - -@comment unistd.h -@comment POSIX.1 -@defvr Macro _SC_CLK_TCK -Inquire about the parameter corresponding to @code{CLOCKS_PER_SEC}; -@pxref{Basic Elapsed CPU Time Inquiry}. -@end defvr - -@strong{Incomplete:} There are also a bunch of symbols for POSIX.2 -features listed in @file{<unistd.h>}. |