From: Eric Blake Date: Thu, 21 Aug 2008 15:32:21 +0000 (-0600) Subject: Document another make bug. X-Git-Tag: v2.63~22 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=75388b165e68c977011d5047e6f20ab05de501f3;p=thirdparty%2Fautoconf.git Document another make bug. * doc/autoconf.texi (The Make Macro SHELL): Mention bug in BSD make, GNU make <= 3.80. Signed-off-by: Eric Blake --- diff --git a/ChangeLog b/ChangeLog index 9b396f91f..772a4e3de 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,5 +1,9 @@ 2008-08-21 Eric Blake + Document another make bug. + * doc/autoconf.texi (The Make Macro SHELL): Mention bug in BSD + make, GNU make <= 3.80. + Tweak wording about SHELL in Makefile. * doc/autoconf.texi (The Make Macro SHELL): Stronger wording on the importance of proper SHELL settings. diff --git a/doc/autoconf.texi b/doc/autoconf.texi index 5e5c1ae6b..907bb83a9 100644 --- a/doc/autoconf.texi +++ b/doc/autoconf.texi @@ -16368,6 +16368,23 @@ $ @kbd{env SHELL=/bin/tcsh FOO=bar gmake -e} # GNU make bar @end example +Conversely, @command{make} is not supposed to export any changes to the +macro @code{SHELL} to child processes. Again, many implementations +break this rule: + +@example +$ @kbd{cat Makefile} +all: + @@echo $(SHELL) + @@printenv SHELL +$ @kbd{env SHELL=sh make -e SHELL=/bin/ksh} # BSD Make, GNU make 3.80 +/bin/ksh +/bin/ksh +$ @kbd{env SHELL=sh gmake -e SHELL=/bin/ksh} # GNU make 3.81 +/bin/ksh +sh +@end example + @node Comments in Make Rules @section Comments in Make Rules @cindex Comments in @file{Makefile} rules