Fixed build failures with older versions of Bison

Older versions of Bison don't include the yyparse function in the generated
header and use deprecated options.
This commit is contained in:
Markus Makela 2016-02-24 13:57:22 +02:00
parent 13387485f6
commit 7b8200eec0
2 changed files with 7 additions and 2 deletions

View File

@ -85,6 +85,11 @@
#include <ruleparser.yy.h>
#include <lex.yy.h>
/** Older versions of Bison don't include the parsing function in the header */
#ifndef dbfw_yyparse
int dbfw_yyparse(void*);
#endif
MODULE_INFO info =
{
MODULE_API_FILTER,

View File

@ -28,10 +28,10 @@
%}
/** We need a reentrant scanner so no global variables are used */
%define api.pure full
%pure-parser
/** Prefix all functions */
%name-prefix "dbfw_yy"
%name-prefix="dbfw_yy"
/** The pure parser requires one extra parameter */
%parse-param {void* scanner}