summaryrefslogtreecommitdiff
path: root/make.texinfo
diff options
context:
space:
mode:
Diffstat (limited to 'make.texinfo')
-rw-r--r--make.texinfo92
1 files changed, 70 insertions, 22 deletions
diff --git a/make.texinfo b/make.texinfo
index 175493a..6b16027 100644
--- a/make.texinfo
+++ b/make.texinfo
@@ -8,10 +8,10 @@
@c FSF publishers: format makebook.texi instead of using this file directly.
@set RCSID $Id$
-@set EDITION 0.54
-@set VERSION 3.78.1
-@set UPDATED 09 September 1999
-@set UPDATE-MONTH September 1999
+@set EDITION 0.55
+@set VERSION 3.79
+@set UPDATED 04 April 2000
+@set UPDATE-MONTH April 2000
@comment The ISBN number might need to change on next publication.
@set ISBN 1-882114-80-9 @c CHANGE THIS BEFORE PRINTING AGAIN! --psmith 16jul98
@@ -37,7 +37,7 @@ and issues the commands to recompile them.
This is Edition @value{EDITION}, last updated @value{UPDATED},
of @cite{The GNU Make Manual}, for @code{make}, Version @value{VERSION}.
-Copyright (C) 1988, '89, '90, '91, '92, '93, '94, '95, '96, '97, '98, '99
+Copyright (C) 1988, '89, '90, '91, '92, '93, '94, '95, '96, '97, '98, '99, 2000
Free Software Foundation, Inc.
Permission is granted to make and distribute verbatim copies of
@@ -73,7 +73,7 @@ by the Free Software Foundation.
@author Richard M. Stallman and Roland McGrath
@page
@vskip 0pt plus 1filll
-Copyright @copyright{} 1988, '89, '90, '91, '92, '93, '94, '95, '96, '97, '98
+Copyright @copyright{} 1988, '89, '90, '91, '92, '93, '94, '95, '96, '97, '98, '99, 2000
Free Software Foundation, Inc.
@sp 2
Published by the Free Software Foundation @*
@@ -134,7 +134,7 @@ This manual describes @code{make} and contains the following chapters:@refill
* Missing:: What GNU @code{make} lacks from other @code{make}s.
* Makefile Conventions:: Conventions for makefiles in GNU programs.
* Quick Reference:: A quick reference for experienced users.
-* Make Errors:: A list of common errors generated by @code{make}.
+* Error Messages:: A list of common errors generated by @code{make}.
* Complex Makefile:: A real example of a straightforward,
but nontrivial, makefile.
* Concept Index:: Index of Concepts
@@ -2479,7 +2479,7 @@ Sub-@code{make}}.
If @code{.NOTPARALLEL} is mentioned as a target, then this invocation of
@code{make} will be run serially, even if the @samp{-j} option is
given. Any recursively invoked @code{make} command will still be run in
-parallel if its makefile doesn't contain this target. Any prerequisites
+parallel (unless its makefile contains this target). Any prerequisites
on this target are ignored.
@end table
@@ -5854,8 +5854,7 @@ ending with word @var{e} (inclusive). The legitimate values of @var{s}
and @var{e} start from 1. If @var{s} is bigger than the number of words
in @var{text}, the value is empty. If @var{e} is bigger than the number
of words in @var{text}, words up to the end of @var{text} are returned.
-If @var{s} is greater than @var{e}, @code{make} swaps them for you. For
-example,
+If @var{s} is greater than @var{e}, nothing is returned. For example,
@example
$(wordlist 2, 3, foo bar baz)
@@ -6060,6 +6059,12 @@ If @var{variable} is the name of a builtin function, the builtin function
is always invoked (even if a @code{make} variable by that name also
exists).
+The @code{call} function expands the @var{param} arguments before
+assigning them to temporary variables. This means that @var{variable}
+values containing references to builtin functions that have special
+expansion rules, like @code{foreach} or @code{if}, may not work as you
+expect.
+
Some examples may make this clearer.
This macro simply reverses its arguments:
@@ -6067,12 +6072,11 @@ This macro simply reverses its arguments:
@smallexample
reverse = $(2) $(1)
-foo = a b
-bar = $(call reverse,$(foo))
+foo = $(call reverse,a,b)
@end smallexample
@noindent
-Here @var{bar} will contain @samp{b a}.
+Here @var{foo} will contain @samp{b a}.
This one is slightly more interesting: it defines a macro to search for
the first instance of a program in @code{PATH}:
@@ -6803,8 +6807,6 @@ This is typically used with recursive invocations of @code{make}
@item -d
@cindex @code{-d}
-@itemx --debug
-@cindex @code{--debug}
@c Extra blank line here makes the table look better.
Print debugging information in addition to normal processing. The
@@ -6812,7 +6814,46 @@ debugging information says which files are being considered for
remaking, which file-times are being compared and with what results,
which files actually need to be remade, which implicit rules are
considered and which are applied---everything interesting about how
-@code{make} decides what to do.
+@code{make} decides what to do. The @code{-d} option is equivalent to
+@samp{--debug=a} (see below).
+
+@item --debug[=@var{options}]
+@cindex @code{--debug}
+@c Extra blank line here makes the table look better.
+
+Print debugging information in addition to normal processing. Various
+levels and types of output can be chosen. With no arguments, print the
+``basic'' level of debugging. Possible arguments are below; only the
+first character is considered, and values must be comma- or
+space-separated.
+
+@table @code
+@item a@var{ll}
+All types of debugging output is enabled. This is equivalent to using
+@samp{-d}.
+
+@item b@var{asic}
+Basic debugging prints each target that was found to be out-of-date, and
+whether the build was successful or not.
+
+@item v@var{erbose}
+A level above @samp{basic}; includes messages about which makefiles were
+parsed, prerequisites that did not need to be rebuilt, etc. This option
+also enables @samp{basic} messages.
+
+@item i@var{mplicit}
+Prints messages describing the implicit rule searches for each target.
+This option also enables @samp{basic} messages.
+
+@item j@var{obs}
+Prints messages giving details on the invocation of specific subcommands.
+
+@item m@var{akefile}
+By default, the above messages are not enabled while trying to remake
+the makefiles. This option enables messages while rebuilding makefiles,
+too. Note that the @samp{all} option does enable this option. This
+option also enables @samp{basic} messages.
+@end table
@item -e
@cindex @code{-e}
@@ -6857,7 +6898,7 @@ searched in the order specified.
@item -j [@var{jobs}]
@cindex @code{-j}
-@itemx --jobs=[@var{jobs}]
+@itemx --jobs[=@var{jobs}]
@cindex @code{--jobs}
Specifies the number of jobs (commands) to run simultaneously. With no
argument, @code{make} runs as many jobs simultaneously as possible. If
@@ -6920,7 +6961,9 @@ reading the makefiles; then execute as usual or as otherwise specified.
This also prints the version information given by the @samp{-v} switch
(see below). To print the data base without trying to remake any files,
use @w{@samp{make -qp}}. To print the data base of predefined rules and
-variables, use @w{@samp{make -p -f /dev/null}}.
+variables, use @w{@samp{make -p -f /dev/null}}. The data base output
+contains filename and linenumber information for command and variable
+definitions, so it can be a useful debugging tool in complex environments.
@item -q
@cindex @code{-q}
@@ -9107,7 +9150,7 @@ special treatment.
@comment included by standards.texi.
@include make-stds.texi
-@node Quick Reference, Make Errors, Makefile Conventions, Top
+@node Quick Reference, Error Messages, Makefile Conventions, Top
@appendix Quick Reference
This appendix summarizes the directives, text manipulation functions,
@@ -9402,6 +9445,11 @@ The flags given to @code{make}. You can set this in the environment or
a makefile to set flags.@*
@xref{Options/Recursion, ,Communicating Options to a Sub-@code{make}}.
+It is @emph{never} appropriate to use @code{MAKEFLAGS} directly on a
+command line: its contents may not be quoted correctly for use in the
+shell. Always allow recursive @code{make}'s to obtain these values
+through the environment from its parent.
+
@item MAKECMDGOALS
The targets given to @code{make} on the command line. Setting this
@@ -9425,11 +9473,11 @@ order.@*
@xref{Libraries/Search, ,Directory Search for Link Libraries}.
@end table
-@node Make Errors, Complex Makefile, Quick Reference, Top
+@node Error Messages, Complex Makefile, Quick Reference, Top
@comment node-name, next, previous, up
@appendix Errors Generated by Make
-Here is a list of the most common errors you might see generated by
+Here is a list of the more common errors you might see generated by
@code{make}, and some information about what they mean and how to fix
them.
@@ -9575,7 +9623,7 @@ sequential manner.
@end table
-@node Complex Makefile, Concept Index, Make Errors, Top
+@node Complex Makefile, Concept Index, Error Messages, Top
@appendix Complex Makefile Example
Here is the makefile for the GNU @code{tar} program. This is a