When yacc/bison is not available, make build step fails:
$ make
test -f src/conf.c || /bin/bash ./ylwrap src/conf.y y.tab.c src/conf.c y.tab.h src/conf.h y.output src/conf.output -- yacc -d
./ylwrap: line 113: yacc: command not found
make: *** [src/conf.c] Error 1
When lex/flex is not available, make build step fails:
$ make
test -f src/lex.c || /bin/bash ./ylwrap src/lex.l .c src/lex.c -- /bin/bash /home/pilou/bip/missing --run flex
/home/pilou/bip/missing: line 52: flex: command not found
WARNING: `flex' is missing on your system. You should only need it if
you modified a `.l' file. You may need the `Flex' package
in order for those modifications to take effect. You can get
`Flex' from any GNU archive site.
make: *** [src/lex.c] Error 1
Is there a particular reason/problem for preferring a fail during the configure step instead of a fail during the make step ?
According to Autoconf behavior and documentation:
- by default when
bison or byacc is not found, the macro AC_PROG_YACC set variable YACC to "yacc": so yacc is considered as always available
- by default when
lex or flex are is found, the macro AC_PROG_LEX set variable LEX to ":"
Is inclusion in the bip release tarballs of the files src/conf.h, src/conf.c and src/lex.c generated by bison and flex an acceptable solution?