mirror of
https://https.git.savannah.gnu.org/git/bash.git
synced 2026-06-28 16:09:51 +02:00
changes to new pattern substitution replacement; documentation updates
This commit is contained in:
@@ -2279,3 +2279,34 @@ parse.y
|
||||
arithmetic for commands reported by
|
||||
Tom Coleman <thomas.james.coleman@gmail.com>
|
||||
|
||||
10/11
|
||||
-----
|
||||
execute_cmd.c
|
||||
- shell_execve: if execve fails with ENOENT, but executable_file()
|
||||
succeeds, display a slightly more descriptive error message. Prompted
|
||||
by a report from Andrea Monaco <andrea.monaco@autistici.org>
|
||||
|
||||
stringlib.c
|
||||
- strcreplace: allow backslash to escape a backslash, since we allow it
|
||||
to escape a `&'
|
||||
|
||||
10/14
|
||||
-----
|
||||
pcomplib.c
|
||||
- COMPLETE_HASH_BUCKETS: double to 512
|
||||
|
||||
stringlib.c
|
||||
- strcreplace: the last argument is now a flags argument. 1 has its
|
||||
previous meaning (glob); 2 means to allow backslash to escape a
|
||||
backslash (as added on 10/11)
|
||||
|
||||
subst.c
|
||||
- pat_subst: call strcreplace with 2 as the flags value
|
||||
|
||||
10/15
|
||||
-----
|
||||
doc/bashref.texi
|
||||
- updates to Installation section
|
||||
|
||||
doc/{mkposix,mkinst,mkrbash},doc/Makefile.in
|
||||
- changes to allow scripts to be run outside the source directory
|
||||
|
||||
@@ -20,20 +20,28 @@ The simplest way to compile Bash is:
|
||||
3. Optionally, type 'make tests' to run the Bash test suite.
|
||||
|
||||
4. Type 'make install' to install 'bash' and 'bashbug'. This will
|
||||
also install the manual pages and Info file.
|
||||
also install the manual pages and Info file, message translation
|
||||
files, some supplemental documentation, a number of example
|
||||
loadable builtin commands, and a set of header files for developing
|
||||
loadable builtins. You may need additional privileges to install
|
||||
'bash' to your desired destination, so 'sudo make install' might be
|
||||
required. More information about controlling the locations where
|
||||
'bash' and other files are installed is below (*note Installation
|
||||
Names::).
|
||||
|
||||
The 'configure' shell script attempts to guess correct values for
|
||||
various system-dependent variables used during compilation. It uses
|
||||
those values to create a 'Makefile' in each directory of the package
|
||||
(the top directory, the 'builtins', 'doc', and 'support' directories,
|
||||
each directory under 'lib', and several others). It also creates a
|
||||
'config.h' file containing system-dependent definitions. Finally, it
|
||||
creates a shell script named 'config.status' that you can run in the
|
||||
future to recreate the current configuration, a file 'config.cache' that
|
||||
saves the results of its tests to speed up reconfiguring, and a file
|
||||
'config.log' containing compiler output (useful mainly for debugging
|
||||
'configure'). If at some point 'config.cache' contains results you
|
||||
don't want to keep, you may remove or edit it.
|
||||
(the top directory, the 'builtins', 'doc', 'po', and 'support'
|
||||
directories, each directory under 'lib', and several others). It also
|
||||
creates a 'config.h' file containing system-dependent definitions.
|
||||
Finally, it creates a shell script named 'config.status' that you can
|
||||
run in the future to recreate the current configuration, a file
|
||||
'config.cache' that saves the results of its tests to speed up
|
||||
reconfiguring, and a file 'config.log' containing compiler output
|
||||
(useful mainly for debugging 'configure'). If at some point
|
||||
'config.cache' contains results you don't want to keep, you may remove
|
||||
or edit it.
|
||||
|
||||
To find out more about the options and arguments that the 'configure'
|
||||
script understands, type
|
||||
@@ -64,7 +72,7 @@ considered for the next release.
|
||||
The file 'configure.ac' is used to create 'configure' by a program
|
||||
called Autoconf. You only need 'configure.ac' if you want to change it
|
||||
or regenerate 'configure' using a newer version of Autoconf. If you do
|
||||
this, make sure you are using Autoconf version 2.50 or newer.
|
||||
this, make sure you are using Autoconf version 2.69 or newer.
|
||||
|
||||
You can remove the program binaries and object files from the source
|
||||
code directory by typing 'make clean'. To also remove the files that
|
||||
@@ -122,10 +130,13 @@ Installation Names
|
||||
==================
|
||||
|
||||
By default, 'make install' will install into '/usr/local/bin',
|
||||
'/usr/local/man', etc. You can specify an installation prefix other
|
||||
than '/usr/local' by giving 'configure' the option '--prefix=PATH', or
|
||||
by specifying a value for the 'DESTDIR' 'make' variable when running
|
||||
'make install'.
|
||||
'/usr/local/man', etc.; that is, the "installation prefix" defaults to
|
||||
'/usr/local'. You can specify an installation prefix other than
|
||||
'/usr/local' by giving 'configure' the option '--prefix=PATH', or by
|
||||
specifying a value for the 'prefix' 'make' variable when running 'make
|
||||
install' (e.g., 'make install prefix=PATH'). The 'prefix' variable
|
||||
provides a default for 'exec_prefix' and other variables used when
|
||||
installing bash.
|
||||
|
||||
You can specify separate installation prefixes for architecture-specific
|
||||
files and architecture-independent files. If you give 'configure' the
|
||||
@@ -133,6 +144,30 @@ option '--exec-prefix=PATH', 'make install' will use PATH as the prefix
|
||||
for installing programs and libraries. Documentation and other data
|
||||
files will still use the regular prefix.
|
||||
|
||||
If you would like to change the installation locations for a single run,
|
||||
you can specify these variables as arguments to 'make': 'make install
|
||||
exec_prefix=/' will install 'bash' and 'bashbug' into '/bin' instead of
|
||||
the default '/usr/local/bin'.
|
||||
|
||||
If you want to see the files bash will install and where it will install
|
||||
them without changing anything on your system, specify the variable
|
||||
'DESTDIR' as an argument to 'make'. Its value should be the absolute
|
||||
directory path you'd like to use as the root of your sample installation
|
||||
tree. For example,
|
||||
|
||||
mkdir /fs1/bash-install
|
||||
make install DESTDIR=/fs1/bash-install
|
||||
|
||||
will install 'bash' into '/fs1/bash-install/usr/local/bin/bash', the
|
||||
documentation into directories within
|
||||
'/fs1/bash-install/usr/local/share', the example loadable builtins into
|
||||
'/fs1/bash-install/usr/local/lib/bash', and so on. You can use the
|
||||
usual 'exec_prefix' and 'prefix' variables to alter the directory paths
|
||||
beneath the value of 'DESTDIR'.
|
||||
|
||||
The GNU Makefile standards provide a more complete description of these
|
||||
variables and their effects.
|
||||
|
||||
Specifying the System Type
|
||||
==========================
|
||||
|
||||
@@ -235,16 +270,20 @@ the Bash 'configure' recognizes.
|
||||
subdirectories of that directory (include files in PREFIX/'include'
|
||||
and the library in PREFIX/'lib').
|
||||
|
||||
'--with-purify'
|
||||
Define this to use the Purify memory allocation checker from
|
||||
Rational Software.
|
||||
'--with-libintl-prefix[=PREFIX]'
|
||||
Define this to make Bash link with a locally-installed version of
|
||||
the libintl library instead ofthe version in 'lib/intl'.
|
||||
|
||||
'--with-libiconv-prefix[=PREFIX]'
|
||||
Define this to make Bash look for libiconv in PREFIX instead of the
|
||||
standard system locations. There is no version included with Bash.
|
||||
|
||||
'--enable-minimal-config'
|
||||
This produces a shell with minimal features, close to the
|
||||
historical Bourne shell.
|
||||
|
||||
There are several '--enable-' options that alter how Bash is compiled
|
||||
and linked, rather than changing run-time features.
|
||||
There are several '--enable-' options that alter how Bash is compiled,
|
||||
linked, and installed, rather than changing run-time features.
|
||||
|
||||
'--enable-largefile'
|
||||
Enable support for large files
|
||||
@@ -257,6 +296,10 @@ and linked, rather than changing run-time features.
|
||||
This builds a Bash binary that produces profiling information to be
|
||||
processed by 'gprof' each time it is executed.
|
||||
|
||||
'--enable-separate-helpfiles'
|
||||
Use external files for the documentation displayed by the 'help'
|
||||
builtin instead of storing the text internally.
|
||||
|
||||
'--enable-static-link'
|
||||
This causes Bash to be linked statically, if 'gcc' is being used.
|
||||
This could be used to build a version to use as root's shell.
|
||||
@@ -265,14 +308,21 @@ The 'minimal-config' option can be used to disable all of the following
|
||||
options, but it is processed first, so individual options may be enabled
|
||||
using 'enable-FEATURE'.
|
||||
|
||||
All of the following options except for 'disabled-builtins',
|
||||
'direxpand-default', and 'xpg-echo-default' are enabled by default,
|
||||
unless the operating system does not provide the necessary support.
|
||||
All of the following options except for 'alt-array-implementation',
|
||||
'disabled-builtins', 'direxpand-default', 'strict-posix-default', and
|
||||
'xpg-echo-default' are enabled by default, unless the operating system
|
||||
does not provide the necessary support.
|
||||
|
||||
'--enable-alias'
|
||||
Allow alias expansion and include the 'alias' and 'unalias'
|
||||
builtins (*note Aliases::).
|
||||
|
||||
'--enable-alt-array-implementation'
|
||||
This builds bash using an alternate implementation of arrays (*note
|
||||
Arrays::) that provides faster access at the expense of using more
|
||||
memory (sometimes many times more, depending on how sparse an array
|
||||
is).
|
||||
|
||||
'--enable-arith-for-command'
|
||||
Include support for the alternate form of the 'for' command that
|
||||
behaves like the C language 'for' statement (*note Looping
|
||||
@@ -292,7 +342,7 @@ unless the operating system does not provide the necessary support.
|
||||
|
||||
'--enable-casemod-attributes'
|
||||
Include support for case-modifying attributes in the 'declare'
|
||||
builtin and assignment statements. Variables with the UPPERCASE
|
||||
builtin and assignment statements. Variables with the 'uppercase'
|
||||
attribute, for example, will have their values converted to
|
||||
uppercase upon assignment.
|
||||
|
||||
@@ -351,7 +401,7 @@ unless the operating system does not provide the necessary support.
|
||||
described above under *note Pattern Matching::.
|
||||
|
||||
'--enable-extended-glob-default'
|
||||
Set the default value of the EXTGLOB shell option described above
|
||||
Set the default value of the 'extglob' shell option described above
|
||||
under *note The Shopt Builtin:: to be enabled.
|
||||
|
||||
'--enable-function-import'
|
||||
@@ -360,10 +410,10 @@ unless the operating system does not provide the necessary support.
|
||||
enabled by default.
|
||||
|
||||
'--enable-glob-asciirange-default'
|
||||
Set the default value of the GLOBASCIIRANGES shell option described
|
||||
above under *note The Shopt Builtin:: to be enabled. This controls
|
||||
the behavior of character ranges when used in pattern matching
|
||||
bracket expressions.
|
||||
Set the default value of the 'globasciiranges' shell option
|
||||
described above under *note The Shopt Builtin:: to be enabled.
|
||||
This controls the behavior of character ranges when used in pattern
|
||||
matching bracket expressions.
|
||||
|
||||
'--enable-help-builtin'
|
||||
Include the 'help' builtin, which displays help on shell builtins
|
||||
@@ -414,10 +464,6 @@ unless the operating system does not provide the necessary support.
|
||||
Include the 'select' compound command, which allows the generation
|
||||
of simple menus (*note Conditional Constructs::).
|
||||
|
||||
'--enable-separate-helpfiles'
|
||||
Use external files for the documentation displayed by the 'help'
|
||||
builtin instead of storing the text internally.
|
||||
|
||||
'--enable-single-help-strings'
|
||||
Store the text displayed by the 'help' builtin as a single string
|
||||
for each help topic. This aids in translating the text to
|
||||
|
||||
@@ -101,7 +101,11 @@ The following list is what's changed when 'POSIX mode' is in effect:
|
||||
|
||||
25. A non-interactive shell exits with an error status if a variable
|
||||
assignment error occurs in an assignment statement preceding a
|
||||
special builtin, but not with any other simple command.
|
||||
special builtin, but not with any other simple command. For any
|
||||
other simple command, the shell aborts execution of that command,
|
||||
and execution continues at the top level ("the shell shall not
|
||||
perform any further processing of the command in which the error
|
||||
occurred").
|
||||
|
||||
26. A non-interactive shell exits with an error status if the
|
||||
iteration variable in a 'for' statement or the selection variable
|
||||
@@ -185,14 +189,14 @@ The following list is what's changed when 'POSIX mode' is in effect:
|
||||
variable values without quotes, unless they contain shell
|
||||
metacharacters, even if the result contains nonprinting characters.
|
||||
|
||||
48. When the 'cd' builtin is invoked in LOGICAL mode, and the pathname
|
||||
48. When the 'cd' builtin is invoked in logical mode, and the pathname
|
||||
constructed from '$PWD' and the directory name supplied as an
|
||||
argument does not refer to an existing directory, 'cd' will fail
|
||||
instead of falling back to PHYSICAL mode.
|
||||
instead of falling back to physical mode.
|
||||
|
||||
49. When the 'cd' builtin cannot change a directory because the length
|
||||
of the pathname constructed from '$PWD' and the directory name
|
||||
supplied as an argument exceeds PATH_MAX when all symbolic links
|
||||
supplied as an argument exceeds 'PATH_MAX' when all symbolic links
|
||||
are expanded, 'cd' will fail instead of attempting to use only the
|
||||
supplied directory name.
|
||||
|
||||
|
||||
@@ -40,10 +40,10 @@ spawned to execute the script.
|
||||
The restricted shell mode is only one component of a useful restricted
|
||||
environment. It should be accompanied by setting 'PATH' to a value that
|
||||
allows execution of only a few verified commands (commands that allow
|
||||
shell escapes are particularly vulnerable), leaving the user in a
|
||||
non-writable directory other than his home directory after login, not
|
||||
allowing the restricted shell to execute shell scripts, and cleaning the
|
||||
environment of variables that cause some commands to modify their
|
||||
shell escapes are particularly vulnerable), changing the current
|
||||
directory to a non-writable directory other than '$HOME' after login,
|
||||
not allowing the restricted shell to execute shell scripts, and cleaning
|
||||
the environment of variables that cause some commands to modify their
|
||||
behavior (e.g., 'VISUAL' or 'PAGER').
|
||||
|
||||
Modern systems provide more secure ways to implement a restricted
|
||||
|
||||
+6
-6
@@ -327,18 +327,18 @@ faq.mail: FAQ faq.headers.mail faq.version
|
||||
cat faq.headers.mail faq.version FAQ > $@
|
||||
|
||||
inst: bashref.texi
|
||||
$(SHELL) ./mkinstall
|
||||
cmp -s INSTALL ../INSTALL || mv INSTALL ../INSTALL
|
||||
$(SHELL) ${srcdir}/mkinstall -t ${topdir} -s ${srcdir}
|
||||
cmp -s INSTALL ${topdir}/INSTALL || mv INSTALL ${topdir}/INSTALL
|
||||
$(RM) INSTALL
|
||||
|
||||
posix: bashref.texi
|
||||
$(SHELL) ./mkposix
|
||||
cmp -s POSIX ../POSIX || mv POSIX ../POSIX
|
||||
$(SHELL) ${srcdir}/mkposix -t ${topdir} -s ${srcdir}
|
||||
cmp -s POSIX ${topdir}/POSIX || mv POSIX ${topdir}/POSIX
|
||||
$(RM) POSIX
|
||||
|
||||
rbash: bashref.texi
|
||||
$(SHELL) ./mkrbash
|
||||
cmp -s RBASH ../RBASH || mv RBASH ../RBASH
|
||||
$(SHELL) ${srcdir}/mkrbash -t ${topdir} -s ${srcdir}
|
||||
cmp -s RBASH ${topdir}/RBASH || mv RBASH ${topdir}/RBASH
|
||||
$(RM) RBASH
|
||||
|
||||
xdist: everything inst posix rbash
|
||||
|
||||
+2015
-2009
File diff suppressed because it is too large
Load Diff
+215
-169
@@ -2,9 +2,9 @@ This is bashref.info, produced by makeinfo version 6.8 from
|
||||
bashref.texi.
|
||||
|
||||
This text is a brief description of the features that are present in the
|
||||
Bash shell (version 5.1, 1 October 2021).
|
||||
Bash shell (version 5.1, 15 October 2021).
|
||||
|
||||
This is Edition 5.1, last updated 1 October 2021, of 'The GNU Bash
|
||||
This is Edition 5.1, last updated 15 October 2021, of 'The GNU Bash
|
||||
Reference Manual', for 'Bash', Version 5.1.
|
||||
|
||||
Copyright (C) 1988-2021 Free Software Foundation, Inc.
|
||||
@@ -27,10 +27,10 @@ Bash Features
|
||||
*************
|
||||
|
||||
This text is a brief description of the features that are present in the
|
||||
Bash shell (version 5.1, 1 October 2021). The Bash home page is
|
||||
Bash shell (version 5.1, 15 October 2021). The Bash home page is
|
||||
<http://www.gnu.org/software/bash/>.
|
||||
|
||||
This is Edition 5.1, last updated 1 October 2021, of 'The GNU Bash
|
||||
This is Edition 5.1, last updated 15 October 2021, of 'The GNU Bash
|
||||
Reference Manual', for 'Bash', Version 5.1.
|
||||
|
||||
Bash contains features that appear in other popular shells, and some
|
||||
@@ -2078,10 +2078,13 @@ omitted, the operator tests only for existence.
|
||||
|
||||
Any unquoted instances of '&' in STRING are replaced with the
|
||||
matching portion of PATTERN. This is intended to duplicate a
|
||||
common 'sed' idiom. Backslash is used to quote '&' in STRING;
|
||||
users should take care if STRING is double-quoted to avoid unwanted
|
||||
interactions between the backslash and double-quoting. For
|
||||
instance,
|
||||
common 'sed' idiom. Backslash is used to quote '&' in STRING; the
|
||||
backslash is removed in order to permit a literal '&' in the
|
||||
replacement string. Pattern substitution performs the check for
|
||||
'&' after expanding STRING, so users should take care to quote
|
||||
backslashes intended to escape the '&' and inhibit replacement so
|
||||
they survive any quote removal performed by the expansion of
|
||||
STRING. For instance,
|
||||
|
||||
var=abcdef
|
||||
echo ${var/abc/& }
|
||||
@@ -2095,16 +2098,18 @@ omitted, the operator tests only for existence.
|
||||
echo "${var/abc/\& }"
|
||||
echo ${var/abc/"\& "}
|
||||
|
||||
will display two lines of "& def" and a third line of "\& def".
|
||||
This is because '&' is not one of the characters for which
|
||||
backslash is special in double quotes, and the expansion of STRING
|
||||
is performed in a context that doesn't take the enclosing double
|
||||
quotes into account. It should rarely be necessary to enclose only
|
||||
STRING in double quotes.
|
||||
|
||||
Pattern substitution performs the check for '&' before expanding
|
||||
STRING to catch backslashes escaping the '&' before they are
|
||||
removed by the expansion.
|
||||
will display two lines of "abc def" and a third line of "& def".
|
||||
The first two are replaced because the backslash is removed by
|
||||
quote removal performed during the expansion of STRING (the
|
||||
expansion is performed in a context that doesn't take any enclosing
|
||||
double quotes into account, as with other word expansions). In the
|
||||
third case, the double quotes affect the expansion of '\&', and,
|
||||
because '&' is not one of the characters for which backslash is
|
||||
special in double quotes, the backslash survives the expansion,
|
||||
inhibits the replacement, but is removed because it is treated
|
||||
specially. One could use '\\&', unquoted, as the replacement
|
||||
string to achive the same effect. It should rarely be necessary to
|
||||
enclose only STRING in double quotes.
|
||||
|
||||
If the 'nocasematch' shell option (see the description of 'shopt'
|
||||
in *note The Shopt Builtin::) is enabled, the match is performed
|
||||
@@ -10184,20 +10189,28 @@ These are installation instructions for Bash.
|
||||
3. Optionally, type 'make tests' to run the Bash test suite.
|
||||
|
||||
4. Type 'make install' to install 'bash' and 'bashbug'. This will
|
||||
also install the manual pages and Info file.
|
||||
also install the manual pages and Info file, message translation
|
||||
files, some supplemental documentation, a number of example
|
||||
loadable builtin commands, and a set of header files for developing
|
||||
loadable builtins. You may need additional privileges to install
|
||||
'bash' to your desired destination, so 'sudo make install' might be
|
||||
required. More information about controlling the locations where
|
||||
'bash' and other files are installed is below (*note Installation
|
||||
Names::).
|
||||
|
||||
The 'configure' shell script attempts to guess correct values for
|
||||
various system-dependent variables used during compilation. It uses
|
||||
those values to create a 'Makefile' in each directory of the package
|
||||
(the top directory, the 'builtins', 'doc', and 'support' directories,
|
||||
each directory under 'lib', and several others). It also creates a
|
||||
'config.h' file containing system-dependent definitions. Finally, it
|
||||
creates a shell script named 'config.status' that you can run in the
|
||||
future to recreate the current configuration, a file 'config.cache' that
|
||||
saves the results of its tests to speed up reconfiguring, and a file
|
||||
'config.log' containing compiler output (useful mainly for debugging
|
||||
'configure'). If at some point 'config.cache' contains results you
|
||||
don't want to keep, you may remove or edit it.
|
||||
(the top directory, the 'builtins', 'doc', 'po', and 'support'
|
||||
directories, each directory under 'lib', and several others). It also
|
||||
creates a 'config.h' file containing system-dependent definitions.
|
||||
Finally, it creates a shell script named 'config.status' that you can
|
||||
run in the future to recreate the current configuration, a file
|
||||
'config.cache' that saves the results of its tests to speed up
|
||||
reconfiguring, and a file 'config.log' containing compiler output
|
||||
(useful mainly for debugging 'configure'). If at some point
|
||||
'config.cache' contains results you don't want to keep, you may remove
|
||||
or edit it.
|
||||
|
||||
To find out more about the options and arguments that the 'configure'
|
||||
script understands, type
|
||||
@@ -10228,7 +10241,7 @@ considered for the next release.
|
||||
The file 'configure.ac' is used to create 'configure' by a program
|
||||
called Autoconf. You only need 'configure.ac' if you want to change it
|
||||
or regenerate 'configure' using a newer version of Autoconf. If you do
|
||||
this, make sure you are using Autoconf version 2.50 or newer.
|
||||
this, make sure you are using Autoconf version 2.69 or newer.
|
||||
|
||||
You can remove the program binaries and object files from the source
|
||||
code directory by typing 'make clean'. To also remove the files that
|
||||
@@ -10296,10 +10309,13 @@ File: bashref.info, Node: Installation Names, Next: Specifying the System Type
|
||||
=======================
|
||||
|
||||
By default, 'make install' will install into '/usr/local/bin',
|
||||
'/usr/local/man', etc. You can specify an installation prefix other
|
||||
than '/usr/local' by giving 'configure' the option '--prefix=PATH', or
|
||||
by specifying a value for the 'DESTDIR' 'make' variable when running
|
||||
'make install'.
|
||||
'/usr/local/man', etc.; that is, the "installation prefix" defaults to
|
||||
'/usr/local'. You can specify an installation prefix other than
|
||||
'/usr/local' by giving 'configure' the option '--prefix=PATH', or by
|
||||
specifying a value for the 'prefix' 'make' variable when running 'make
|
||||
install' (e.g., 'make install prefix=PATH'). The 'prefix' variable
|
||||
provides a default for 'exec_prefix' and other variables used when
|
||||
installing bash.
|
||||
|
||||
You can specify separate installation prefixes for
|
||||
architecture-specific files and architecture-independent files. If you
|
||||
@@ -10307,6 +10323,30 @@ give 'configure' the option '--exec-prefix=PATH', 'make install' will
|
||||
use PATH as the prefix for installing programs and libraries.
|
||||
Documentation and other data files will still use the regular prefix.
|
||||
|
||||
If you would like to change the installation locations for a single
|
||||
run, you can specify these variables as arguments to 'make': 'make
|
||||
install exec_prefix=/' will install 'bash' and 'bashbug' into '/bin'
|
||||
instead of the default '/usr/local/bin'.
|
||||
|
||||
If you want to see the files bash will install and where it will
|
||||
install them without changing anything on your system, specify the
|
||||
variable 'DESTDIR' as an argument to 'make'. Its value should be the
|
||||
absolute directory path you'd like to use as the root of your sample
|
||||
installation tree. For example,
|
||||
|
||||
mkdir /fs1/bash-install
|
||||
make install DESTDIR=/fs1/bash-install
|
||||
|
||||
will install 'bash' into '/fs1/bash-install/usr/local/bin/bash', the
|
||||
documentation into directories within
|
||||
'/fs1/bash-install/usr/local/share', the example loadable builtins into
|
||||
'/fs1/bash-install/usr/local/lib/bash', and so on. You can use the
|
||||
usual 'exec_prefix' and 'prefix' variables to alter the directory paths
|
||||
beneath the value of 'DESTDIR'.
|
||||
|
||||
The GNU Makefile standards provide a more complete description of
|
||||
these variables and their effects.
|
||||
|
||||
|
||||
File: bashref.info, Node: Specifying the System Type, Next: Sharing Defaults, Prev: Installation Names, Up: Installing Bash
|
||||
|
||||
@@ -10460,15 +10500,21 @@ compiled, linked, and installed, rather than changing run-time features.
|
||||
following options, but it is processed first, so individual options may
|
||||
be enabled using 'enable-FEATURE'.
|
||||
|
||||
All of the following options except for 'disabled-builtins',
|
||||
'direxpand-default', 'strict-posix-default', and 'xpg-echo-default' are
|
||||
enabled by default, unless the operating system does not provide the
|
||||
necessary support.
|
||||
All of the following options except for 'alt-array-implementation',
|
||||
'disabled-builtins', 'direxpand-default', 'strict-posix-default', and
|
||||
'xpg-echo-default' are enabled by default, unless the operating system
|
||||
does not provide the necessary support.
|
||||
|
||||
'--enable-alias'
|
||||
Allow alias expansion and include the 'alias' and 'unalias'
|
||||
builtins (*note Aliases::).
|
||||
|
||||
'--enable-alt-array-implementation'
|
||||
This builds bash using an alternate implementation of arrays (*note
|
||||
Arrays::) that provides faster access at the expense of using more
|
||||
memory (sometimes many times more, depending on how sparse an array
|
||||
is).
|
||||
|
||||
'--enable-arith-for-command'
|
||||
Include support for the alternate form of the 'for' command that
|
||||
behaves like the C language 'for' statement (*note Looping
|
||||
@@ -12292,138 +12338,138 @@ D.5 Concept Index
|
||||
|
||||
|
||||
Tag Table:
|
||||
Node: Top893
|
||||
Node: Introduction2809
|
||||
Node: What is Bash?3025
|
||||
Node: What is a shell?4139
|
||||
Node: Definitions6677
|
||||
Node: Basic Shell Features9628
|
||||
Node: Shell Syntax10847
|
||||
Node: Shell Operation11873
|
||||
Node: Quoting13166
|
||||
Node: Escape Character14470
|
||||
Node: Single Quotes14955
|
||||
Node: Double Quotes15303
|
||||
Node: ANSI-C Quoting16581
|
||||
Node: Locale Translation17891
|
||||
Node: Creating Internationalized Scripts19202
|
||||
Node: Comments23319
|
||||
Node: Shell Commands23937
|
||||
Node: Reserved Words24875
|
||||
Node: Simple Commands25631
|
||||
Node: Pipelines26285
|
||||
Node: Lists29244
|
||||
Node: Compound Commands31039
|
||||
Node: Looping Constructs32051
|
||||
Node: Conditional Constructs34546
|
||||
Node: Command Grouping48890
|
||||
Node: Coprocesses50368
|
||||
Node: GNU Parallel53031
|
||||
Node: Shell Functions53948
|
||||
Node: Shell Parameters61239
|
||||
Node: Positional Parameters65627
|
||||
Node: Special Parameters66529
|
||||
Node: Shell Expansions69743
|
||||
Node: Brace Expansion71870
|
||||
Node: Tilde Expansion74604
|
||||
Node: Shell Parameter Expansion77225
|
||||
Node: Command Substitution94537
|
||||
Node: Arithmetic Expansion95892
|
||||
Node: Process Substitution96860
|
||||
Node: Word Splitting97980
|
||||
Node: Filename Expansion99924
|
||||
Node: Pattern Matching102524
|
||||
Node: Quote Removal107132
|
||||
Node: Redirections107427
|
||||
Node: Executing Commands117087
|
||||
Node: Simple Command Expansion117757
|
||||
Node: Command Search and Execution119867
|
||||
Node: Command Execution Environment122245
|
||||
Node: Environment125280
|
||||
Node: Exit Status126943
|
||||
Node: Signals128727
|
||||
Node: Shell Scripts130694
|
||||
Node: Shell Builtin Commands133721
|
||||
Node: Bourne Shell Builtins135759
|
||||
Node: Bash Builtins157220
|
||||
Node: Modifying Shell Behavior188037
|
||||
Node: The Set Builtin188382
|
||||
Node: The Shopt Builtin198795
|
||||
Node: Special Builtins214224
|
||||
Node: Shell Variables215203
|
||||
Node: Bourne Shell Variables215640
|
||||
Node: Bash Variables217744
|
||||
Node: Bash Features250559
|
||||
Node: Invoking Bash251572
|
||||
Node: Bash Startup Files257585
|
||||
Node: Interactive Shells262688
|
||||
Node: What is an Interactive Shell?263098
|
||||
Node: Is this Shell Interactive?263747
|
||||
Node: Interactive Shell Behavior264562
|
||||
Node: Bash Conditional Expressions268075
|
||||
Node: Shell Arithmetic272717
|
||||
Node: Aliases275661
|
||||
Node: Arrays278274
|
||||
Node: The Directory Stack284283
|
||||
Node: Directory Stack Builtins285067
|
||||
Node: Controlling the Prompt289327
|
||||
Node: The Restricted Shell292292
|
||||
Node: Bash POSIX Mode294889
|
||||
Node: Shell Compatibility Mode306162
|
||||
Node: Job Control312818
|
||||
Node: Job Control Basics313278
|
||||
Node: Job Control Builtins318280
|
||||
Node: Job Control Variables323680
|
||||
Node: Command Line Editing324836
|
||||
Node: Introduction and Notation326507
|
||||
Node: Readline Interaction328130
|
||||
Node: Readline Bare Essentials329321
|
||||
Node: Readline Movement Commands331104
|
||||
Node: Readline Killing Commands332064
|
||||
Node: Readline Arguments333982
|
||||
Node: Searching335026
|
||||
Node: Readline Init File337212
|
||||
Node: Readline Init File Syntax338473
|
||||
Node: Conditional Init Constructs359753
|
||||
Node: Sample Init File363949
|
||||
Node: Bindable Readline Commands367073
|
||||
Node: Commands For Moving368277
|
||||
Node: Commands For History370328
|
||||
Node: Commands For Text375322
|
||||
Node: Commands For Killing378971
|
||||
Node: Numeric Arguments382004
|
||||
Node: Commands For Completion383143
|
||||
Node: Keyboard Macros387334
|
||||
Node: Miscellaneous Commands388021
|
||||
Node: Readline vi Mode393960
|
||||
Node: Programmable Completion394867
|
||||
Node: Programmable Completion Builtins402647
|
||||
Node: A Programmable Completion Example413342
|
||||
Node: Using History Interactively418589
|
||||
Node: Bash History Facilities419273
|
||||
Node: Bash History Builtins422278
|
||||
Node: History Interaction427286
|
||||
Node: Event Designators430906
|
||||
Node: Word Designators432260
|
||||
Node: Modifiers434020
|
||||
Node: Installing Bash435831
|
||||
Node: Basic Installation436968
|
||||
Node: Compilers and Options440226
|
||||
Node: Compiling For Multiple Architectures440967
|
||||
Node: Installation Names442660
|
||||
Node: Specifying the System Type443478
|
||||
Node: Sharing Defaults444194
|
||||
Node: Operation Controls444867
|
||||
Node: Optional Features445825
|
||||
Node: Reporting Bugs456625
|
||||
Node: Major Differences From The Bourne Shell457900
|
||||
Node: GNU Free Documentation License474750
|
||||
Node: Indexes499927
|
||||
Node: Builtin Index500381
|
||||
Node: Reserved Word Index507208
|
||||
Node: Variable Index509656
|
||||
Node: Function Index526148
|
||||
Node: Concept Index539932
|
||||
Node: Top895
|
||||
Node: Introduction2813
|
||||
Node: What is Bash?3029
|
||||
Node: What is a shell?4143
|
||||
Node: Definitions6681
|
||||
Node: Basic Shell Features9632
|
||||
Node: Shell Syntax10851
|
||||
Node: Shell Operation11877
|
||||
Node: Quoting13170
|
||||
Node: Escape Character14474
|
||||
Node: Single Quotes14959
|
||||
Node: Double Quotes15307
|
||||
Node: ANSI-C Quoting16585
|
||||
Node: Locale Translation17895
|
||||
Node: Creating Internationalized Scripts19206
|
||||
Node: Comments23323
|
||||
Node: Shell Commands23941
|
||||
Node: Reserved Words24879
|
||||
Node: Simple Commands25635
|
||||
Node: Pipelines26289
|
||||
Node: Lists29248
|
||||
Node: Compound Commands31043
|
||||
Node: Looping Constructs32055
|
||||
Node: Conditional Constructs34550
|
||||
Node: Command Grouping48894
|
||||
Node: Coprocesses50372
|
||||
Node: GNU Parallel53035
|
||||
Node: Shell Functions53952
|
||||
Node: Shell Parameters61243
|
||||
Node: Positional Parameters65631
|
||||
Node: Special Parameters66533
|
||||
Node: Shell Expansions69747
|
||||
Node: Brace Expansion71874
|
||||
Node: Tilde Expansion74608
|
||||
Node: Shell Parameter Expansion77229
|
||||
Node: Command Substitution95023
|
||||
Node: Arithmetic Expansion96378
|
||||
Node: Process Substitution97346
|
||||
Node: Word Splitting98466
|
||||
Node: Filename Expansion100410
|
||||
Node: Pattern Matching103010
|
||||
Node: Quote Removal107618
|
||||
Node: Redirections107913
|
||||
Node: Executing Commands117573
|
||||
Node: Simple Command Expansion118243
|
||||
Node: Command Search and Execution120353
|
||||
Node: Command Execution Environment122731
|
||||
Node: Environment125766
|
||||
Node: Exit Status127429
|
||||
Node: Signals129213
|
||||
Node: Shell Scripts131180
|
||||
Node: Shell Builtin Commands134207
|
||||
Node: Bourne Shell Builtins136245
|
||||
Node: Bash Builtins157706
|
||||
Node: Modifying Shell Behavior188523
|
||||
Node: The Set Builtin188868
|
||||
Node: The Shopt Builtin199281
|
||||
Node: Special Builtins214710
|
||||
Node: Shell Variables215689
|
||||
Node: Bourne Shell Variables216126
|
||||
Node: Bash Variables218230
|
||||
Node: Bash Features251045
|
||||
Node: Invoking Bash252058
|
||||
Node: Bash Startup Files258071
|
||||
Node: Interactive Shells263174
|
||||
Node: What is an Interactive Shell?263584
|
||||
Node: Is this Shell Interactive?264233
|
||||
Node: Interactive Shell Behavior265048
|
||||
Node: Bash Conditional Expressions268561
|
||||
Node: Shell Arithmetic273203
|
||||
Node: Aliases276147
|
||||
Node: Arrays278760
|
||||
Node: The Directory Stack284769
|
||||
Node: Directory Stack Builtins285553
|
||||
Node: Controlling the Prompt289813
|
||||
Node: The Restricted Shell292778
|
||||
Node: Bash POSIX Mode295375
|
||||
Node: Shell Compatibility Mode306648
|
||||
Node: Job Control313304
|
||||
Node: Job Control Basics313764
|
||||
Node: Job Control Builtins318766
|
||||
Node: Job Control Variables324166
|
||||
Node: Command Line Editing325322
|
||||
Node: Introduction and Notation326993
|
||||
Node: Readline Interaction328616
|
||||
Node: Readline Bare Essentials329807
|
||||
Node: Readline Movement Commands331590
|
||||
Node: Readline Killing Commands332550
|
||||
Node: Readline Arguments334468
|
||||
Node: Searching335512
|
||||
Node: Readline Init File337698
|
||||
Node: Readline Init File Syntax338959
|
||||
Node: Conditional Init Constructs360239
|
||||
Node: Sample Init File364435
|
||||
Node: Bindable Readline Commands367559
|
||||
Node: Commands For Moving368763
|
||||
Node: Commands For History370814
|
||||
Node: Commands For Text375808
|
||||
Node: Commands For Killing379457
|
||||
Node: Numeric Arguments382490
|
||||
Node: Commands For Completion383629
|
||||
Node: Keyboard Macros387820
|
||||
Node: Miscellaneous Commands388507
|
||||
Node: Readline vi Mode394446
|
||||
Node: Programmable Completion395353
|
||||
Node: Programmable Completion Builtins403133
|
||||
Node: A Programmable Completion Example413828
|
||||
Node: Using History Interactively419075
|
||||
Node: Bash History Facilities419759
|
||||
Node: Bash History Builtins422764
|
||||
Node: History Interaction427772
|
||||
Node: Event Designators431392
|
||||
Node: Word Designators432746
|
||||
Node: Modifiers434506
|
||||
Node: Installing Bash436317
|
||||
Node: Basic Installation437454
|
||||
Node: Compilers and Options441176
|
||||
Node: Compiling For Multiple Architectures441917
|
||||
Node: Installation Names443610
|
||||
Node: Specifying the System Type445719
|
||||
Node: Sharing Defaults446435
|
||||
Node: Operation Controls447108
|
||||
Node: Optional Features448066
|
||||
Node: Reporting Bugs459159
|
||||
Node: Major Differences From The Bourne Shell460434
|
||||
Node: GNU Free Documentation License477284
|
||||
Node: Indexes502461
|
||||
Node: Builtin Index502915
|
||||
Node: Reserved Word Index509742
|
||||
Node: Variable Index512190
|
||||
Node: Function Index528682
|
||||
Node: Concept Index542466
|
||||
|
||||
End Tag Table
|
||||
|
||||
|
||||
+57
-12
@@ -8861,7 +8861,14 @@ Optionally, type @samp{make tests} to run the Bash test suite.
|
||||
|
||||
@item
|
||||
Type @samp{make install} to install @code{bash} and @code{bashbug}.
|
||||
This will also install the manual pages and Info file.
|
||||
This will also install the manual pages and Info file, message translation
|
||||
files, some supplemental documentation, a number of example loadable
|
||||
builtin commands, and a set of header files for developing loadable
|
||||
builtins.
|
||||
You may need additional privileges to install @code{bash} to your
|
||||
desired destination, so @samp{sudo make install} might be required.
|
||||
More information about controlling the locations where @code{bash} and
|
||||
other files are installed is below (@pxref{Installation Names}).
|
||||
|
||||
@end enumerate
|
||||
|
||||
@@ -8869,7 +8876,7 @@ The @code{configure} shell script attempts to guess correct
|
||||
values for various system-dependent variables used during
|
||||
compilation. It uses those values to create a @file{Makefile} in
|
||||
each directory of the package (the top directory, the
|
||||
@file{builtins}, @file{doc}, and @file{support} directories,
|
||||
@file{builtins}, @file{doc}, @file{po}, and @file{support} directories,
|
||||
each directory under @file{lib}, and several others). It also creates a
|
||||
@file{config.h} file containing system-dependent definitions.
|
||||
Finally, it creates a shell script named @code{config.status} that you
|
||||
@@ -8914,10 +8921,10 @@ to do them, and mail diffs or instructions to
|
||||
considered for the next release.
|
||||
|
||||
The file @file{configure.ac} is used to create @code{configure}
|
||||
by a program called Autoconf. You only need
|
||||
@file{configure.ac} if you want to change it or regenerate
|
||||
@code{configure} using a newer version of Autoconf. If
|
||||
you do this, make sure you are using Autoconf version 2.50 or
|
||||
by a program called Autoconf.
|
||||
You only need @file{configure.ac} if you want to change it or regenerate
|
||||
@code{configure} using a newer version of Autoconf.
|
||||
If you do this, make sure you are using Autoconf version 2.69 or
|
||||
newer.
|
||||
|
||||
You can remove the program binaries and object files from the
|
||||
@@ -8988,18 +8995,49 @@ directories for other architectures.
|
||||
@section Installation Names
|
||||
|
||||
By default, @samp{make install} will install into
|
||||
@file{/usr/local/bin}, @file{/usr/local/man}, etc. You can
|
||||
specify an installation prefix other than @file{/usr/local} by
|
||||
@file{/usr/local/bin}, @file{/usr/local/man}, etc.;
|
||||
that is, the @dfn{installation prefix} defaults to @file{/usr/local}.
|
||||
You can specify an installation prefix other than @file{/usr/local} by
|
||||
giving @code{configure} the option @option{--prefix=@var{PATH}},
|
||||
or by specifying a value for the @env{DESTDIR} @samp{make}
|
||||
variable when running @samp{make install}.
|
||||
or by specifying a value for the @env{prefix} @samp{make}
|
||||
variable when running @samp{make install}
|
||||
(e.g., @samp{make install prefix=@var{PATH}}).
|
||||
The @env{prefix} variable provides a default for @env{exec_prefix} and
|
||||
other variables used when installing bash.
|
||||
|
||||
You can specify separate installation prefixes for
|
||||
architecture-specific files and architecture-independent files.
|
||||
If you give @code{configure} the option
|
||||
@option{--exec-prefix=@var{PATH}}, @samp{make install} will use
|
||||
@var{PATH} as the prefix for installing programs and libraries.
|
||||
Documentation and other data files will still use the regular prefix.
|
||||
Documentation and other data files will still use the regular prefix.
|
||||
|
||||
If you would like to change the installation locations for a single run,
|
||||
you can specify these variables as arguments to @code{make}:
|
||||
@samp{make install exec_prefix=/} will install @code{bash} and
|
||||
@code{bashbug} into @file{/bin} instead of the default @file{/usr/local/bin}.
|
||||
|
||||
If you want to see the files bash will install and where it will install
|
||||
them without changing anything on your system, specify the variable
|
||||
@env{DESTDIR} as an argument to @code{make}. Its value should be the
|
||||
absolute directory path you'd like to use as the root of your sample
|
||||
installation tree. For example,
|
||||
|
||||
@example
|
||||
mkdir /fs1/bash-install
|
||||
make install DESTDIR=/fs1/bash-install
|
||||
@end example
|
||||
|
||||
@noindent
|
||||
will install @code{bash} into @file{/fs1/bash-install/usr/local/bin/bash},
|
||||
the documentation into directories within
|
||||
@file{/fs1/bash-install/usr/local/share}, the example loadable builtins into
|
||||
@file{/fs1/bash-install/usr/local/lib/bash}, and so on.
|
||||
You can use the usual @env{exec_prefix} and @env{prefix} variables to alter
|
||||
the directory paths beneath the value of @env{DESTDIR}.
|
||||
|
||||
The GNU Makefile standards provide a more complete description of these
|
||||
variables and their effects.
|
||||
|
||||
@node Specifying the System Type
|
||||
@section Specifying the System Type
|
||||
@@ -9157,7 +9195,9 @@ The @samp{minimal-config} option can be used to disable all of
|
||||
the following options, but it is processed first, so individual
|
||||
options may be enabled using @samp{enable-@var{feature}}.
|
||||
|
||||
All of the following options except for @samp{disabled-builtins},
|
||||
All of the following options except for
|
||||
@samp{alt-array-implementation},
|
||||
@samp{disabled-builtins},
|
||||
@samp{direxpand-default},
|
||||
@samp{strict-posix-default},
|
||||
and
|
||||
@@ -9170,6 +9210,11 @@ necessary support.
|
||||
Allow alias expansion and include the @code{alias} and @code{unalias}
|
||||
builtins (@pxref{Aliases}).
|
||||
|
||||
@item --enable-alt-array-implementation
|
||||
This builds bash using an alternate implementation of arrays
|
||||
(@pxref{Arrays}) that provides faster access at the expense of using
|
||||
more memory (sometimes many times more, depending on how sparse an array is).
|
||||
|
||||
@item --enable-arith-for-command
|
||||
Include support for the alternate form of the @code{for} command
|
||||
that behaves like the C language @code{for} statement
|
||||
|
||||
+18
-1
@@ -4,19 +4,36 @@
|
||||
# texinfo manual
|
||||
#
|
||||
|
||||
# defaults for doing this in the source tree
|
||||
SRCDIR=.
|
||||
TOPDIR=..
|
||||
|
||||
NODE="Installing Bash"
|
||||
SUBNODE="Basic Installation"
|
||||
TEXI=bashref.texi
|
||||
TMPINFO=temp.info
|
||||
TMPOUT=INSTALL.tmp
|
||||
|
||||
prog=${0##*/}
|
||||
USAGE="usage: $prog [-s srcdir] [-t topdir] [output-file]"
|
||||
while getopts s:t: opt
|
||||
do
|
||||
case "$opt" in
|
||||
s) SRCDIR=$OPTARG TEXI=${OPTARG}/bashref.texi ;;
|
||||
t) TOPDIR=$OPTARG ;;
|
||||
*) echo "$USAGE" >&2 ; exit 2 ;;
|
||||
esac
|
||||
done
|
||||
shift $(( $OPTIND - 1 ))
|
||||
|
||||
OUT=${1:-INSTALL}
|
||||
|
||||
trap 'rm -f $TMPOUT $TMPINFO $OUT; trap '' 0; exit 1' 1 2 3 6 15
|
||||
trap 'rm -f $TMPOUT $TMPINFO' 0
|
||||
|
||||
# create an info file without paragraph indentation
|
||||
makeinfo --no-split --no-number-sections -I../lib/readline/doc --paragraph-indent 0 -o $TMPINFO $TEXI
|
||||
RLDIR=${TOPDIR}/lib/readline/doc
|
||||
makeinfo --no-split --no-number-sections -I${RLDIR} --paragraph-indent 0 -o $TMPINFO $TEXI
|
||||
|
||||
# write out the text from the `Installing Bash' node to INSTALL.tmp
|
||||
info --file $TMPINFO --node "$NODE" --subnodes --output $TMPOUT
|
||||
|
||||
+18
-1
@@ -4,18 +4,35 @@
|
||||
# of the texinfo manual
|
||||
#
|
||||
|
||||
# defaults for doing this in the source tree
|
||||
SRCDIR=.
|
||||
TOPDIR=..
|
||||
|
||||
NODE="Bash POSIX Mode"
|
||||
TEXI=bashref.texi
|
||||
TMPINFO=temp.info
|
||||
TMPOUT=POSIX.tmp
|
||||
|
||||
prog=${0##*/}
|
||||
USAGE="usage: $prog [-s srcdir] [-t topdir] [output-file]"
|
||||
while getopts s:t: opt
|
||||
do
|
||||
case "$opt" in
|
||||
s) SRCDIR=$OPTARG TEXI=${OPTARG}/bashref.texi ;;
|
||||
t) TOPDIR=$OPTARG ;;
|
||||
*) echo "$USAGE" >&2 ; exit 2 ;;
|
||||
esac
|
||||
done
|
||||
shift $(( $OPTIND - 1 ))
|
||||
|
||||
OUT=${1:-POSIX}
|
||||
|
||||
trap 'rm -f $TMPOUT $TMPINFO $OUT; trap '' 0; exit 1' 1 2 3 6 15
|
||||
trap 'rm -f $TMPOUT $TMPINFO' 0
|
||||
|
||||
# create an info file without paragraph indentation
|
||||
makeinfo --no-split -I../lib/readline/doc --paragraph-indent 0 -o $TMPINFO $TEXI
|
||||
RLDIR=${TOPDIR}/lib/readline/doc
|
||||
makeinfo --no-split -I${RLDIR} --paragraph-indent 0 -o $TMPINFO $TEXI
|
||||
|
||||
# write out the text from the `Bash POSIX Mode' node to $TMPOUT
|
||||
info --file $TMPINFO --node "$NODE" --subnodes --output $TMPOUT
|
||||
|
||||
+18
-1
@@ -4,18 +4,35 @@
|
||||
# of the texinfo manual
|
||||
#
|
||||
|
||||
# defaults for doing this in the source tree
|
||||
SRCDIR=.
|
||||
TOPDIR=..
|
||||
|
||||
NODE="The Restricted Shell"
|
||||
TEXI=bashref.texi
|
||||
TMPINFO=temp.info
|
||||
TMPOUT=RBASH.tmp
|
||||
|
||||
prog=${0##*/}
|
||||
USAGE="usage: $prog [-s srcdir] [-t topdir] [output-file]"
|
||||
while getopts s:t: opt
|
||||
do
|
||||
case "$opt" in
|
||||
s) SRCDIR=$OPTARG TEXI=${OPTARG}/bashref.texi ;;
|
||||
t) TOPDIR=$OPTARG ;;
|
||||
*) echo "$USAGE" >&2 ; exit 2 ;;
|
||||
esac
|
||||
done
|
||||
shift $(( $OPTIND - 1 ))
|
||||
|
||||
OUT=${1:-RBASH}
|
||||
|
||||
trap 'rm -f $TMPOUT $TMPINFO $OUT; trap '' 0; exit 1' 1 2 3 6 15
|
||||
trap 'rm -f $TMPOUT $TMPINFO' 0
|
||||
|
||||
# create an info file without paragraph indentation
|
||||
makeinfo --no-split -I../lib/readline/doc --paragraph-indent 0 -o $TMPINFO $TEXI
|
||||
RLDIR=${TOPDIR}/lib/readline/doc
|
||||
makeinfo --no-split -I${RLDIR} --paragraph-indent 0 -o $TMPINFO $TEXI
|
||||
|
||||
# write out the text from the `The Restricted Shell' node to $TMPOUT
|
||||
info --file $TMPINFO --node "$NODE" --subnodes --output $TMPOUT
|
||||
|
||||
+2
-2
@@ -2,10 +2,10 @@
|
||||
Copyright (C) 1988-2021 Free Software Foundation, Inc.
|
||||
@end ignore
|
||||
|
||||
@set LASTCHANGE Fri Oct 1 15:32:14 EDT 2021
|
||||
@set LASTCHANGE Fri Oct 15 15:24:19 EDT 2021
|
||||
|
||||
@set EDITION 5.1
|
||||
@set VERSION 5.1
|
||||
|
||||
@set UPDATED 1 October 2021
|
||||
@set UPDATED 15 October 2021
|
||||
@set UPDATED-MONTH October 2021
|
||||
|
||||
@@ -5964,6 +5964,11 @@ shell_execve (command, args, env)
|
||||
errno = i;
|
||||
file_error (command);
|
||||
}
|
||||
else if (i == ENOENT)
|
||||
{
|
||||
errno = i;
|
||||
internal_error (_("%s: cannot execute: required file not found"), command);
|
||||
}
|
||||
else
|
||||
{
|
||||
/* The file has the execute bits set, but the kernel refuses to
|
||||
|
||||
+1
-1
@@ -37,7 +37,7 @@
|
||||
#include "shell.h"
|
||||
#include "pcomplete.h"
|
||||
|
||||
#define COMPLETE_HASH_BUCKETS 256 /* must be power of two */
|
||||
#define COMPLETE_HASH_BUCKETS 512 /* must be power of two */
|
||||
|
||||
#define STRDUP(x) ((x) ? savestring (x) : (char *)NULL)
|
||||
|
||||
|
||||
+11
-4
@@ -178,17 +178,22 @@ strsub (string, pat, rep, global)
|
||||
}
|
||||
|
||||
/* Replace all instances of C in STRING with TEXT. TEXT may be empty or
|
||||
NULL. If DO_GLOB is non-zero, we quote the replacement text for
|
||||
globbing. Backslash may be used to quote C. */
|
||||
NULL. If (FLAGS & 1) is non-zero, we quote the replacement text for
|
||||
globbing. Backslash may be used to quote C. If (FLAGS & 2) we allow
|
||||
backslash to escape backslash as well. */
|
||||
char *
|
||||
strcreplace (string, c, text, do_glob)
|
||||
strcreplace (string, c, text, flags)
|
||||
char *string;
|
||||
int c;
|
||||
const char *text;
|
||||
int do_glob;
|
||||
int flags;
|
||||
{
|
||||
char *ret, *p, *r, *t;
|
||||
int len, rlen, ind, tlen;
|
||||
int do_glob, escape_backslash;
|
||||
|
||||
do_glob = flags & 1;
|
||||
escape_backslash = flags & 2;
|
||||
|
||||
len = STRLEN (text);
|
||||
rlen = len + strlen (string) + 2;
|
||||
@@ -225,6 +230,8 @@ strcreplace (string, c, text, do_glob)
|
||||
|
||||
if (*p == '\\' && p[1] == c)
|
||||
p++;
|
||||
else if (escape_backslash && *p == '\\' && p[1] == '\\')
|
||||
p++;
|
||||
|
||||
ind = r - ret;
|
||||
RESIZE_MALLOCED_BUFFER (ret, ind, 2, rlen, rlen);
|
||||
|
||||
@@ -8484,7 +8484,7 @@ pat_subst (string, pat, rep, mflags)
|
||||
for (x = 0; x < mlen; x++)
|
||||
mstr[x] = s[x];
|
||||
mstr[mlen] = '\0';
|
||||
rstr = strcreplace (rep, '&', mstr, 0);
|
||||
rstr = strcreplace (rep, '&', mstr, 2);
|
||||
free (mstr);
|
||||
rslen = strlen (rstr);
|
||||
}
|
||||
|
||||
+22
-22
@@ -1,41 +1,49 @@
|
||||
complete -f -X '!*.+(ps|PS)' gs
|
||||
complete -c nice
|
||||
complete -e printenv
|
||||
complete -c gdb
|
||||
complete -f -X '!*.texi*' texi2html
|
||||
complete -j -P '%' fg
|
||||
complete -g groupmod
|
||||
complete -f -X '!*.dvi' dvips
|
||||
complete -f -X '!*.texi*' texi2dvi
|
||||
complete -v -S '=' typeset
|
||||
complete -f .
|
||||
complete -c nohup
|
||||
complete -a unalias
|
||||
complete -g groupdel
|
||||
complete -A hostname telnet
|
||||
complete -v -S '=' declare
|
||||
complete -v -S '=' export
|
||||
complete -v -S '=' local
|
||||
complete -v -S '=' readonly
|
||||
complete -o bashdefault -o filenames -o nospace -F _comp_cd cd
|
||||
complete -f -X '!*.dvi' xdvi
|
||||
complete -c type
|
||||
complete -f ln
|
||||
complete -f -X '!*.+(gz|tgz)' gunzip
|
||||
complete -f -X '!*.texi*' makeinfo
|
||||
complete -u su
|
||||
complete -j -P '%' jobs
|
||||
complete -o dirnames -o filenames -o nospace -d popd
|
||||
complete -A signal trap
|
||||
complete -o dirnames -o filenames -o nospace -d pushd
|
||||
complete -f -X '!*.pdf' acroread
|
||||
complete -v unset
|
||||
complete -f -X '!*.+(ps|PS)' ghostview
|
||||
complete -j -W '$(ps -x | tail +2 | cut -c1-5)' -P '%' wait
|
||||
complete -A hostname rsh
|
||||
complete -c exec
|
||||
complete -f -X '!*.Z' zmore
|
||||
complete -A signal kill
|
||||
complete -c eval
|
||||
complete -f chown
|
||||
complete -f gzip
|
||||
complete -W '"${GROUPS[@]}"' newgrp
|
||||
complete -A shopt shopt
|
||||
complete -A hostname ftp
|
||||
complete -A hostname rlogin
|
||||
complete -v getopts
|
||||
complete -c nice
|
||||
complete -c gdb
|
||||
complete -j -P '%' fg
|
||||
complete -f -X '!*.dvi' dvips
|
||||
complete -f -X '!*.texi*' texi2dvi
|
||||
complete -f .
|
||||
complete -v -S '=' declare
|
||||
complete -v -S '=' export
|
||||
complete -f -X '!*.dvi' xdvi
|
||||
complete -u su
|
||||
complete -o dirnames -o filenames -o nospace -d popd
|
||||
complete -A signal trap
|
||||
complete -j -W '$(ps -x | tail +2 | cut -c1-5)' -P '%' wait
|
||||
complete -f -X '!*.Z' zmore
|
||||
complete -j -P '%' disown
|
||||
complete -f -X '!*.+(ps|PS)' gs
|
||||
complete -f -X '!*.+(ps|PS)' gv
|
||||
@@ -45,19 +53,11 @@ complete -A stopped -P '%' bg
|
||||
complete -f cat
|
||||
complete -d mkdir
|
||||
complete -A helptopic help
|
||||
complete -c eval
|
||||
complete -f chown
|
||||
complete -v read
|
||||
complete -c -k time
|
||||
complete -f -X '!*.Z' zcat
|
||||
complete -f gzip
|
||||
complete -W '"${GROUPS[@]}"' newgrp
|
||||
complete -f -X '!*.Z' uncompress
|
||||
complete -d rmdir
|
||||
complete -A shopt shopt
|
||||
complete -A hostname ftp
|
||||
complete -f more
|
||||
complete -A hostname rlogin
|
||||
complete -v getopts
|
||||
complete -f -X '!*.+(gz|tgz)' gzcat
|
||||
./complete.tests: line 123: complete: notthere: no completion specification
|
||||
|
||||
@@ -1,5 +1,22 @@
|
||||
# This program is free software: you can redistribute it and/or modify
|
||||
# it under the terms of the GNU General Public License as published by
|
||||
# the Free Software Foundation, either version 3 of the License, or
|
||||
# (at your option) any later version.
|
||||
#
|
||||
# This program is distributed in the hope that it will be useful,
|
||||
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
# GNU General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
#
|
||||
|
||||
echo "warning: the text of a system error message may vary between systems and" >&2
|
||||
echo "warning: produce diff output." >&2
|
||||
echo "warning: UNIX versions number signals differently." >&2
|
||||
echo "warning: If output differing only in line numbers is produced, please" >&2
|
||||
echo "warning: do not consider this a test failure." >&2
|
||||
echo "warning: if the text of the error messages concerning \`notthere' or" >&2
|
||||
echo "warning: \`/tmp/bash-notthere' not being found or \`/' being a directory" >&2
|
||||
echo "warning: produce diff output, please do not consider this a test failure" >&2
|
||||
|
||||
Reference in New Issue
Block a user