aboutsummaryrefslogtreecommitdiff
path: root/src/preproc.c
diff options
context:
space:
mode:
authorSergey Poznyakoff <gray@gnu.org.ua>2011-05-07 17:24:18 +0300
committerSergey Poznyakoff <gray@gnu.org.ua>2011-05-07 18:55:38 +0300
commit4b0e477181f51c12f62236ec91f4bb714125393d (patch)
tree9ddb2c5c16549ce5bf6056e45aef3646402accbc /src/preproc.c
parentcede19f7c5a151c1aeb7c93d1793183bca8e8289 (diff)
downloadgrecs-4b0e477181f51c12f62236ec91f4bb714125393d.tar.gz
grecs-4b0e477181f51c12f62236ec91f4bb714125393d.tar.bz2
Support standalone compilation.
* AUTHORS, COPYING, NEWS, README: New files. * .gitignore: Update. * am/.gitignore: New file. * build-aux/.gitignore: New file. * build-aux/ylwrap: Remove. * Makefile.am: Define ACLOCAL_AMFLAGS [GRECS_CHANGELOG]: Build ChangeLog. * am/grecs.m4: Define GRECS_CHANGELOG and GRECS_SRCDIR. Fixup first argument, if it is [.]. * configure.ac: New file. * src/Make-inst.am (include_HEADERS): Add wordsplit.h. Install libgrecs.m4. * Make-shared.am (noinst_HEADERS): Add wordsplit.h. * src/Make-static.am: Likewise. * src/Make.am (GRECS_SRC): Remove wordsplit.h (noinst_HEADERS): Add yygrecs.h (YLWRAP): Remove. * src/libgrecs.m4: New file. * src/yygrecs.h: New file. * src/grecs-gram.y: Include yygrecs.h. * src/grecs-lex.l: Likewise. * src/preproc.c (yy_grecs_flex_debug): Rename to grecs_yy_flex_debug.
Diffstat (limited to 'src/preproc.c')
-rw-r--r--src/preproc.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/preproc.c b/src/preproc.c
index 28f473f..cff8224 100644
--- a/src/preproc.c
+++ b/src/preproc.c
@@ -45,13 +45,13 @@ struct buffer_ctx {
size_t namelen; /* Length of the file name */
size_t xlines; /* Number of #line directives output so far */
struct input_file_ident id;
FILE *infile;
};
-extern int yy_grecs_flex_debug;
+extern int grecs_yy_flex_debug;
static struct buffer_ctx *context_stack;
static char *linebufbase = NULL;
static size_t linebufsize = 0;
#define INFILE context_stack->infile
#define LOCUS context_stack->locus
@@ -429,13 +429,13 @@ push_source(const char *name, int once)
ctx->id.i_node = st.st_ino;
ctx->id.device = st.st_dev;
ctx->infile = fp;
ctx->prev = context_stack;
context_stack = ctx;
- if (yy_grecs_flex_debug)
+ if (grecs_yy_flex_debug)
fprintf (stderr, "Processing file `%s'\n", name);
pp_line_stmt();
return 0;
}
@@ -453,20 +453,20 @@ pop_source()
/* Restore previous context */
ctx = context_stack->prev;
grecs_free(context_stack);
context_stack = ctx;
if (!context_stack) {
- if (yy_grecs_flex_debug)
+ if (grecs_yy_flex_debug)
fprintf (stderr, "End of input\n");
return 1;
}
LOCUS.line++;
- if (yy_grecs_flex_debug)
+ if (grecs_yy_flex_debug)
fprintf (stderr, "Resuming file `%s' at line %lu\n",
LOCUS.file, (unsigned long) LOCUS.line);
pp_line_stmt();
return 0;

Return to:

Send suggestions and report system problems to the System administrator.