From: Ralf Wildenhues Date: Mon, 11 May 2009 22:15:43 +0000 (+0200) Subject: Document some formatting restrictions for Makefile.am files. X-Git-Tag: v1.11~13 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=27f63d48b2cbf9a8a0af1185821929fade57298f;p=thirdparty%2Fautomake.git Document some formatting restrictions for Makefile.am files. For PR automake/540: * doc/automake.texi (General Operation, Usage of Conditionals): Variable assignments should not be indented by TABs, rule commands should. Conditional keyword statements should not be indented. Report by luoyi.ly@gmail.com. Signed-off-by: Ralf Wildenhues --- diff --git a/ChangeLog b/ChangeLog index 722ac9895..329879c26 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,13 @@ +2009-05-11 Ralf Wildenhues + + For PR automake/540: + Document some formatting restrictions for Makefile.am files. + * doc/automake.texi (General Operation, Usage of Conditionals): + Variable assignments should not be indented by TABs, rule commands + should. Conditional keyword statements should not be indented. + * THANKS: Update. + Report by Luo Yi. + 2009-05-03 Ralf Wildenhues Fix copyright years in *.am files. diff --git a/THANKS b/THANKS index 2017bcb10..bf2be2df0 100644 --- a/THANKS +++ b/THANKS @@ -187,6 +187,7 @@ Laurent Morichetti laurentm@cup.hp.com Leo Davis ldavis@fonix.com Leonardo Boiko leoboiko@conectiva.com.br Loulou Pouchet loulou@lrde.epita.fr +Luo Yi luoyi.ly@gmail.com Maciej Stachowiak mstachow@mit.edu Maciej W. Rozycki macro@ds2.pg.gda.pl Manu Rouat emmanuel.rouat@wanadoo.fr diff --git a/doc/automake.texi b/doc/automake.texi index 09a5dd270..e8779422a 100644 --- a/doc/automake.texi +++ b/doc/automake.texi @@ -1775,6 +1775,11 @@ supported. This operator appends its right hand argument to the variable specified on the left. Automake will translate the operator into an ordinary @samp{=} operator; @samp{+=} will thus work with any make program. +@cindex indentation +Further note that variable assignments should not be indented with +@key{TAB} characters, use spaces if necessary. On the other hand, +rule commands should be indented with a leading @key{TAB} character. + Automake tries to keep comments grouped with any adjoining rules or variable definitions. @@ -9565,7 +9570,9 @@ endif !DEBUG @end example @noindent -Unbalanced conditions are errors. +Unbalanced conditions are errors. The @code{if}, @code{else}, and +@code{endif} statements should not be indented, i.e., start on column +one. The @code{else} branch of the above two examples could be omitted, since assigning the empty string to an otherwise undefined variable