Only in bison-hacked/config: Makefile Only in bison-hacked/: config.h Only in bison-hacked/: config.log Only in bison-hacked/: config.status diff -aur bison-2.0/data/lalr1.cc bison-hacked/data/lalr1.cc --- bison-2.0/data/lalr1.cc 2004-12-25 21:35:20.000000000 -0800 +++ bison-hacked/data/lalr1.cc 2005-09-06 17:41:22.000000000 -0700 @@ -139,8 +139,8 @@ ]/* Line __line__ of lalr1.cc. */ b4_syncline([@oline@], [@ofile@])[ -#include "stack.hh" -#include "location.hh" +#include @lalr_stack_name_no_path@ +#include @lalr_location_name_no_path@ /* Enabling traces. */ #ifndef YYDEBUG @@ -413,7 +413,7 @@ #define yylex b4_prefix[]lex]) m4_if(b4_defines_flag, 0, [], [ -#include @output_header_name@])[ +#include @output_header_name_no_path@])[ /* A pseudo ostream that takes yydebug_ into account. */ # define YYCDEBUG \ @@ -1048,7 +1048,7 @@ ]b4_epilogue dnl -@output stack.hh +@output @lalr_stack_name@ b4_copyright([stack handling for Bison C++ parsers], [2002, 2003, 2004])[ #ifndef BISON_STACK_HH @@ -1147,7 +1147,7 @@ #endif // not BISON_STACK_HH] dnl -@output position.hh +@output @lalr_position_name@ b4_copyright([Position class for Bison C++ parsers], [2002, 2003, 2004])[ /** @@ -1260,7 +1260,7 @@ } #endif // not BISON_POSITION_HH] -@output location.hh +@output @lalr_location_name@ b4_copyright([Location class for Bison C++ parsers], [2002, 2003, 2004])[ /** @@ -1273,7 +1273,7 @@ # include # include -# include "position.hh" +# include @lalr_position_name_no_path@ namespace yy { Only in bison-hacked/data: Makefile Only in bison-hacked/doc: Makefile Only in bison-hacked/lib: abitset.o Only in bison-hacked/lib: alloca.h Only in bison-hacked/lib: argmatch.o Only in bison-hacked/lib: basename.o Only in bison-hacked/lib: bitset.o Only in bison-hacked/lib: bitset_stats.o Only in bison-hacked/lib: bitsetv.o Only in bison-hacked/lib: bitsetv-print.o Only in bison-hacked/lib: .deps Only in bison-hacked/lib: dirname.o Only in bison-hacked/lib: ebitset.o Only in bison-hacked/lib: exitfail.o Only in bison-hacked/lib: get-errno.o Only in bison-hacked/lib: hard-locale.o Only in bison-hacked/lib: hash.o Only in bison-hacked/lib: lbitset.o Only in bison-hacked/lib: libbison.a Only in bison-hacked/lib: liby.a Only in bison-hacked/lib: main.o Only in bison-hacked/lib: Makefile Only in bison-hacked/lib: mbswidth.o Only in bison-hacked/lib: quotearg.o Only in bison-hacked/lib: quote.o Only in bison-hacked/lib: stripslash.o Only in bison-hacked/lib: subpipe.o Only in bison-hacked/lib: timevar.o Only in bison-hacked/lib: vbitset.o Only in bison-hacked/lib: xalloc-die.o Only in bison-hacked/lib: xmalloc.o Only in bison-hacked/lib: xstrndup.o Only in bison-hacked/lib: yyerror.o Only in bison-hacked/: Makefile Only in bison-hacked/po: Makefile Only in bison-hacked/po: Makefile.in Only in bison-hacked/po: POTFILES Only in bison-hacked/src: assoc.o Only in bison-hacked/src: bison Only in bison-hacked/src: closure.o Only in bison-hacked/src: complain.o Only in bison-hacked/src: conflicts.o Only in bison-hacked/src: .deps Only in bison-hacked/src: derives.o diff -aur bison-2.0/src/files.c bison-hacked/src/files.c --- bison-2.0/src/files.c 2004-04-28 13:00:56.000000000 -0700 +++ bison-hacked/src/files.c 2005-09-06 17:46:59.000000000 -0700 @@ -54,6 +54,9 @@ char *spec_verbose_file = NULL; /* for --verbose. */ char *spec_graph_file = NULL; /* for -g. */ char *spec_defines_file = NULL; /* for --defines. */ +char *spec_defines_file_no_path = NULL, + *lalr_stack_file = NULL, *lalr_position_file = NULL, *lalr_location_file = NULL, + *lalr_stack_file_no_path = NULL, *lalr_location_file_no_path = NULL, *lalr_position_file_no_path = NULL; char *parser_file_name = NULL; uniqstr grammar_file = NULL; @@ -295,7 +298,7 @@ void compute_output_file_names (void) { - char const *name[4]; + char const *name[16]; int i; int j; int names = 0; @@ -314,8 +317,22 @@ if (defines_flag) { if (! spec_defines_file) - spec_defines_file = concat2 (full_base_name, header_extension); + spec_defines_file = concat2 (full_base_name, header_extension); name[names++] = spec_defines_file; + + spec_defines_file_no_path = concat2(base_name(short_base_name), ".hpp"); + + lalr_stack_file = concat2(full_base_name, "_stack.hh"); + lalr_stack_file_no_path = base_name(lalr_stack_file); + name[names++] = lalr_stack_file; + + lalr_position_file = concat2(full_base_name, "_position.hh"); + lalr_position_file_no_path = base_name(lalr_position_file); + name[names++] = lalr_position_file; + + lalr_location_file = concat2(full_base_name, "_location.hh"); + lalr_location_file_no_path = base_name(lalr_location_file); + name[names++] = lalr_location_file; } if (graph_flag) @@ -336,3 +353,4 @@ if (strcmp (name[i], name[j]) == 0) warn (_("conflicting outputs to file %s"), quote (name[i])); } + diff -aur bison-2.0/src/files.h bison-hacked/src/files.h --- bison-2.0/src/files.h 2002-12-10 22:29:17.000000000 -0800 +++ bison-hacked/src/files.h 2005-09-06 17:47:14.000000000 -0700 @@ -43,6 +43,9 @@ /* File name specified with --defines. */ extern char *spec_defines_file; +extern char *spec_defines_file_no_path, + *lalr_stack_file, *lalr_position_file, *lalr_location_file, + *lalr_stack_file_no_path, *lalr_location_file_no_path, *lalr_position_file_no_path; /* Read grammar specifications. */ extern FILE *finput; Only in bison-hacked/src: files.o Only in bison-hacked/src: getargs.o Only in bison-hacked/src: gram.o Only in bison-hacked/src: lalr.o Only in bison-hacked/src: location.o Only in bison-hacked/src: LR0.o Only in bison-hacked/src: main.o Only in bison-hacked/src: Makefile Only in bison-hacked/src: muscle_tab.o Only in bison-hacked/src: nullable.o Only in bison-hacked/src: output.o Only in bison-hacked/src: parse-gram.o Only in bison-hacked/src: print_graph.o Only in bison-hacked/src: print.o Only in bison-hacked/src: reader.o Only in bison-hacked/src: reduce.o Only in bison-hacked/src: relation.o Only in bison-hacked/src: scan-gram.o diff -aur bison-2.0/src/scan-skel.l bison-hacked/src/scan-skel.l --- bison-2.0/src/scan-skel.l 2004-12-10 21:03:55.000000000 -0800 +++ bison-hacked/src/scan-skel.l 2005-09-06 17:49:12.000000000 -0700 @@ -49,14 +49,20 @@ char const *filename = yytext + sizeof "@output " - 1; yytext[yyleng - 1] = '\0'; - if (*filename == '@') + if (*filename == '@') { - if (strcmp (filename, "@output_header_name@") == 0) - filename = spec_defines_file; - else if (strcmp (filename, "@output_parser_name@") == 0) - filename = parser_file_name; - else - fatal ("invalid token in skeleton: %s", yytext); + if (strcmp (filename, "@output_header_name@") == 0) + filename = spec_defines_file; + else if (strcmp (filename, "@output_parser_name@") == 0) + filename = parser_file_name; + else if (strcmp(filename, "@lalr_stack_name@") == 0) + filename = lalr_stack_file; + else if (strcmp(filename, "@lalr_position_name@") == 0) + filename = lalr_position_file; + else if (strcmp(filename, "@lalr_location_name@") == 0) + filename = lalr_location_file; + else + fatal ("invalid token in skeleton: %s", yytext); } free (outname); @@ -74,6 +80,10 @@ "@ofile@" QPUTS (outname); "@output_parser_name@" QPUTS (parser_file_name); "@output_header_name@" QPUTS (spec_defines_file); +"@output_header_name_no_path@" QPUTS (spec_defines_file_no_path); +"@lalr_stack_name_no_path@" QPUTS (lalr_stack_file_no_path); +"@lalr_location_name_no_path@" QPUTS (lalr_location_file_no_path); +"@lalr_position_name_no_path@" QPUTS (lalr_position_file_no_path); /* This pattern must not match more than the previous @ patterns. */ @[^{}@\n]* fatal ("invalid @ in skeleton: %s", yytext); Only in bison-hacked/src: scan-skel.o Only in bison-hacked/src: state.o Only in bison-hacked/src: symlist.o Only in bison-hacked/src: symtab.o Only in bison-hacked/src: tables.o Only in bison-hacked/src: uniqstr.o Only in bison-hacked/src: vcg.o Only in bison-hacked/src: yacc Only in bison-hacked/: stamp-h1 Only in bison-hacked/tests: atconfig Only in bison-hacked/tests: atlocal Only in bison-hacked/tests: bison Only in bison-hacked/tests: Makefile