diff options
author | Guy Harris <guy@alum.mit.edu> | 2015-09-26 21:59:39 -0700 |
---|---|---|
committer | Guy Harris <guy@alum.mit.edu> | 2015-09-26 21:59:39 -0700 |
commit | 757c5c29783b3de1a0c75c521362e592bf7dc5c9 (patch) | |
tree | a3c8a09d6fb512041214daabf3324083bb0c2ce1 /scanner.l | |
parent | b56a5baa48d760e9c4b4f8a46e9036ce703ac435 (diff) | |
download | libpcap-757c5c29783b3de1a0c75c521362e592bf7dc5c9.tar.gz |
Redo the way we handle .l and .y files.
Use AC_PROG_LEX and AC_PROG_YACC to find {f}lex and yacc/bison/byacc.
Once we've found them, make sure {f}lex can handle -P, --header-file,
--nounput, and -o, and can parse our scanner.l, and make sure
yacc/bison/byacc can handle -p and -o. If that fails, fail, suggesting
that the user get versions that can (such as Flex and Bison/Berkeley
YACC). If that doesn't fail, use those options; don't use runlex.sh.
Diffstat (limited to 'scanner.l')
-rw-r--r-- | scanner.l | 9 |
1 files changed, 7 insertions, 2 deletions
@@ -1,10 +1,15 @@ -%top{ +%top { /* Must come first for _LARGE_FILE_API on AIX. */ #ifdef HAVE_CONFIG_H #include "config.h" #endif } +/* + * We don't read from the terminal. + */ +%option never-interactive + %{ /* * Copyright (c) 1988, 1989, 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1997 @@ -87,7 +92,7 @@ #endif /*INET6*/ #include <pcap/namedb.h> -#include "tokdefs.h" +#include "grammar.h" #ifdef HAVE_OS_PROTO_H #include "os-proto.h" |