+2010-06-21 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
+
+ Fix minor testsuite issues, update docs, for Yacc/Lex changes.
+ * doc/automake.texi (Yacc and Lex): Mention AM_YFLAGS, YFLAGS
+ and AM_LFLAGS, LFLAGS in the order in which they now appear in
+ the rules.
+ * NEWS: Update.
+ * tests/lflags.test, tests/lflags2.test, tests/yflags.test,
+ tests/yflags2.test: Prefer `make -e' over `make VAR=VAL', to
+ please maintainer-check. Ensure generated C files contain a
+ declaration, to please compilers.
+
2010-06-21 Stefano Lattarini <stefano.lattarini@gmail.com>
Fix bugs in Automake Yacc/Lex support w.r.t. $(AM_FLAGS) and
* Long standing bugs:
- - Automake variables $(AM_LFLAGS) and $(AM_YFLAGS) took precedence over
- user variables $(FLAGS) and $(YFLAGS) (respectively). This was in
- contrast with both reasonable user's expectations and the Automake
- manual; so the precedence is now the other way round.
-
- On Darwin 9, `pythondir' and `pyexecdir' pointed below `/Library/Python'
even if the `--prefix' argument pointed outside of a system directory.
AM_PATH_PYTHON has been fixed to ignore the value returned from python's
- A per-Makefile.am setting of -Werror does not carry over to the
handling of other Makefile.am files any more.
+
+ - The order of Yacc and Lex flags is fixed to be consistent with other
+ languages: $(AM_YFLAGS) comes before $(YFLAGS), and $(AM_LFLAGS) before
+ $(LFLAGS), so that the user variables override the developer variables.
\f
New in 1.11:
@vindex YFLAGS
@vindex AM_YFLAGS
-When @code{yacc} is invoked, it is passed @code{YFLAGS} and
-@code{AM_YFLAGS}. The former is a user variable and the latter is
+When @code{yacc} is invoked, it is passed @code{AM_YFLAGS} and
+@code{YFLAGS}. The latter is a user variable and the former is
intended for the @file{Makefile.am} author.
@code{AM_YFLAGS} is usually used to pass the @option{-d} option to
@vindex LFLAGS
@vindex AM_LFLAGS
-When @command{lex} is invoked, it is passed @code{LFLAGS} and
-@code{AM_LFLAGS}. The former is a user variable and the latter is
+When @command{lex} is invoked, it is passed @code{AM_LFLAGS} and
+@code{LFLAGS}. The latter is a user variable and the former is
intended for the @file{Makefile.am} author.
When @code{AM_MAINTAINER_MODE} (@pxref{maintainer-mode}) is used, the
cat >fake-lex <<'END'
#!/bin/sh
echo '/*' "$*" '*/' >lex.yy.c
+echo 'extern int dummy;' >> lex.yy.c
END
chmod a+x fake-lex
$AUTOCONF
./configure
-$MAKE LFLAGS=__user_flags__
+env LFLAGS=__user_flags__ $MAKE -e
ls -l
cat >fake-lex <<'END'
#!/bin/sh
echo '/*' "$*" '*/' >lex.yy.c
+echo 'extern int dummy;' >> lex.yy.c
END
chmod a+x fake-lex
$AUTOCONF
./configure
-$MAKE LFLAGS=__user_flags__
+env LFLAGS=__user_flags__ $MAKE -e
ls -l
cat >fake-yacc <<'END'
#!/bin/sh
echo '/*' "$*" '*/' >y.tab.c
+echo 'extern int dummy;' >> y.tab.c
END
chmod a+x fake-yacc
$AUTOCONF
./configure
-$MAKE YFLAGS=__user_flags__
+env YFLAGS=__user_flags__ $MAKE -e
ls -l
cat >fake-yacc <<'END'
#!/bin/sh
echo '/*' "$*" '*/' >y.tab.c
+echo 'extern int dummy;' >> y.tab.c
END
chmod a+x fake-yacc
$AUTOCONF
./configure
-$MAKE YFLAGS=__user_flags__
+env YFLAGS=__user_flags__ $MAKE -e
ls -l