summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDave Beckett <dave@dajobe.org>2014-04-20 15:21:30 -0700
committerDave Beckett <dave@dajobe.org>2014-04-20 15:21:30 -0700
commitb21e8a0e21a5313dce814e63106414ef5829619b (patch)
tree1f6eddf24b34d60d7489e285e188b80b17edcc45
parentfe1cdfed8629fc8746983cd95de00d0fcf18d8b7 (diff)
downloadraptor-b21e8a0e21a5313dce814e63106414ef5829619b.tar.gz
Define FLEX_VERSION_DECIMAL and use to not duplicate column prototypes.
-rw-r--r--configure.ac1
-rw-r--r--src/turtle_lexer.l2
2 files changed, 3 insertions, 0 deletions
diff --git a/configure.ac b/configure.ac
index 09afd347..81db80a0 100644
--- a/configure.ac
+++ b/configure.ac
@@ -122,6 +122,7 @@ if test "$USE_MAINTAINER_MODE" = yes; then
AC_MSG_FAILURE(flex not present)
fi
fi
+AC_DEFINE_UNQUOTED(FLEX_VERSION_DECIMAL, $FLEX_VERSION_DEC, [Flex version as a decimal])
BISON_MIN_VERSION=3.0.0
AC_CHECK_PROGS(BISON, bison3 bison)
diff --git a/src/turtle_lexer.l b/src/turtle_lexer.l
index ad12f1c4..8984a6d8 100644
--- a/src/turtle_lexer.l
+++ b/src/turtle_lexer.l
@@ -126,11 +126,13 @@ const char * turtle_token_print(raptor_world* world, int token, YYSTYPE *lval);
#endif
+#if FLEX_VERSION_DECIMAL < 20536
/* debian flex 2.5.35-10.1 added these column header prototypes in
* re-entrant mode. standard flex omits them
*/
void turtle_lexer_set_column(int column_no, yyscan_t yyscanner);
int turtle_lexer_get_column(yyscan_t yyscanner);
+#endif
static void turtle_lexer_cleanup(yyscan_t yyscanner);