+2009-05-21 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
+
+ Document VPATH = $(variable) issue in VPATH chapter.
+ * doc/autoconf.texi (Variables listed in VPATH): New node.
+ (Top, VPATH and Make): Adjust menus.
+ (Build Directories): Refer to it.
+ Prompted by report from Bruno Haible.
+
2009-05-19 Eric Blake <ebb9@byu.net>
Update uses of all-permissive license.
@code{VPATH} and Make
+* Variables listed in VPATH:: @code{VPATH} must be literal on ancient hosts
* VPATH and Double-colon:: Problems with @samp{::} on ancient hosts
* $< in Explicit Rules:: @code{$<} does not work in ordinary rules
* Automatic Rule Rewriting:: @code{VPATH} goes wild on Solaris
VPATH = @@srcdir@@
@end example
-Do not set @code{VPATH} to the value of another variable, for example
-@samp{VPATH = $(srcdir)}, because some versions of @command{make} do not do
-variable substitutions on the value of @code{VPATH}.
+Do not set @code{VPATH} to the value of another variable (@pxref{Variables
+listed in VPATH}.
@command{configure} substitutes the correct value for @code{srcdir} when
it produces @file{Makefile}.
implementations.
@menu
+* Variables listed in VPATH:: @code{VPATH} must be literal on ancient hosts
* VPATH and Double-colon:: Problems with @samp{::} on ancient hosts
* $< in Explicit Rules:: @code{$<} does not work in ordinary rules
* Automatic Rule Rewriting:: @code{VPATH} goes wild on Solaris
* Make Target Lookup:: More details about @code{VPATH} lookup
@end menu
+@node Variables listed in VPATH
+@subsection Variables listed in @code{VPATH}
+@cindex @code{VPATH} and variables
+@cindex variables and @code{VPATH}
+
+Do not set @code{VPATH} to the value of another variable, for example
+@samp{VPATH = $(srcdir)}, because some ancient versions of
+@command{make} do not do variable substitutions on the value of
+@code{VPATH}. For example, use this
+
+@example
+srcdir = @@srcdir@@
+VPATH = @@srcdir@@
+@end example
+
+@noindent
+rather than @samp{VPATH = $(srcdir)}. Note that with @acronym{GNU}
+Automake, there is no need to set this yourself.
+
@node VPATH and Double-colon
@subsection @code{VPATH} and Double-colon Rules
@cindex @code{VPATH} and double-colon rules