Hi Eric. On 06/26/2012 06:27 PM, Akim Demaille wrote: > > Le 26 juin 2012 à 18:18, Eric Blake a écrit : > >> Just from reading this summary, the idea of improving AC_PROG_LEX and >> AC_PROG_YACC to be more useful makes sense, especially if it would make >> automake easier to maintain. What sort of improvements are needed? > > In the present case, I believe the only thing Automake needs > to know is whether -o is supported by lex/yacc. > Yes. And to ensure proper compatibility with C++ and with the use of the '-d' option, we should consider the '-o' support good enough only provided that, when "yacc -d -o foo.C-EXT" is used, the name of the created header is "foo.H-EXT", where H-EXT is C-EXT with all 'c' characters substituted by 'h' ones (so that foo.c -> foo.h, foo.c++ -> foo.h++, foo.cc -> foo.hh, etc). This is what Bison does. Once we know that lex supports '-o', the determination of the value of $LEX_OUTPUT_ROOT will mostly become moot, and could be dispensed with (at least for what concerns Automake). Also, it would be nice if AC_PROG_YACC and AC_PROG_LEX would allow us to change the list of the searched programs (this will allow the Automake configure script to prefer non-bison 'yacc' and non-flex 'lex' programs for use in the testsuite, to ensure better coverage). Finally, while we are at it, we might also think about making default values for $YACC and $LEX configurable (rather than hard-coding them to resp. 'yacc' and ':'). Oh, and setting a couple of (self-explanatory) variables $LEX_IS_FLEX and $YACC_IS_BISON wouldn't hurt (albeit it would not be needed by Automake at this point). Regards, Stefano _______________________________________________ Autoconf mailing list Autoconf@xxxxxxx https://lists.gnu.org/mailman/listinfo/autoconf