summaryrefslogtreecommitdiffstats
path: root/dimension/Makefile.am
diff options
context:
space:
mode:
authorTavian Barnes <tavianator@gmail.com>2010-02-01 21:27:12 -0500
committerTavian Barnes <tavianator@gmail.com>2010-02-01 21:27:12 -0500
commit40752ebfb3ec8355b4f17681f8aab0ca7f6992f4 (patch)
treed5c1a693cc5468e2d1688fc5ee49e1ea6e7e06e1 /dimension/Makefile.am
parent58634f3410db1ff16f6e21d9d0e1fcfaa17b2453 (diff)
downloaddimension-40752ebfb3ec8355b4f17681f8aab0ca7f6992f4.tar.xz
Implement #declare, #local, and #undef in middle tier.
Oh God this is ugly...
Diffstat (limited to 'dimension/Makefile.am')
-rw-r--r--dimension/Makefile.am33
1 files changed, 25 insertions, 8 deletions
diff --git a/dimension/Makefile.am b/dimension/Makefile.am
index 1ee125c..6335ce7 100644
--- a/dimension/Makefile.am
+++ b/dimension/Makefile.am
@@ -22,25 +22,42 @@ INCLUDES = -I$(top_srcdir)/libdimension
bin_PROGRAMS = dimension
AM_YFLAGS = -d
-BUILT_SOURCES = grammar.h
-EXTRA_DIST = grammar.prologue \
+BUILT_SOURCES = directives.h grammar.h
+EXTRA_DIST = common.prologue \
+ common.declarations \
+ common.terminals \
+ common.nonterminals \
+ common.rules \
+ directives.prologue \
+ directives.declarations \
+ directives.nonterminals \
+ directives.rules \
+ grammar.prologue \
grammar.declarations \
- grammar.terminals \
grammar.nonterminals \
grammar.rules \
grammar.epilogue
-grammar.y: grammar.prologue grammar.declarations grammar.terminals grammar.nonterminals grammar.rules grammar.epilogue
+grammar.y: grammar.prologue grammar.declarations grammar.nonterminals grammar.rules grammar.epilogue common.prologue common.declarations common.terminals common.nonterminals common.rules
echo "%{" >$@
- cat grammar.prologue >>$@
+ cat {common,grammar}.prologue >>$@
echo "%}" >>$@
- cat grammar.{declarations,terminals,nonterminals} >>$@
+ cat common.terminals {grammar,common}.{declarations,nonterminals} >>$@
echo "%%" >>$@
- cat grammar.rules >>$@
+ cat grammar.rules common.rules >>$@
echo "%%" >>$@
cat grammar.epilogue >>$@
-dimension_SOURCES = grammar.y \
+directives.y: directives.prologue directives.declarations directives.nonterminals directives.rules common.prologue common.declarations common.terminals common.nonterminals common.rules
+ echo "%{" >$@
+ cat {common,directives}.prologue >>$@
+ echo "%}" >>$@
+ cat common.terminals {directives,common}.{declarations,nonterminals} >>$@
+ echo "%%" >>$@
+ cat directives.rules common.rules >>$@
+
+dimension_SOURCES = directives.y \
+ grammar.y \
lexer.l \
main.c \
parse.c \