]> git.saurik.com Git - bison.git/blob - src/local.mk
5589c1d5151a8999376a08f59f25f33039317b34
[bison.git] / src / local.mk
1 ## Copyright (C) 2001-2012 Free Software Foundation, Inc.
2
3 ## This program is free software: you can redistribute it and/or modify
4 ## it under the terms of the GNU General Public License as published by
5 ## the Free Software Foundation, either version 3 of the License, or
6 ## (at your option) any later version.
7 ##
8 ## This program is distributed in the hope that it will be useful,
9 ## but WITHOUT ANY WARRANTY; without even the implied warranty of
10 ## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
11 ## GNU General Public License for more details.
12 ##
13 ## You should have received a copy of the GNU General Public License
14 ## along with this program. If not, see <http://www.gnu.org/licenses/>.
15
16 LDADD = lib/libbison.a $(LIBINTL)
17
18 bin_PROGRAMS = src/bison
19
20 src_bison_CFLAGS = $(AM_CFLAGS) $(WERROR_CFLAGS)
21 src_bison_SOURCES = \
22 src/AnnotationList.c \
23 src/AnnotationList.h \
24 src/InadequacyList.c \
25 src/InadequacyList.h \
26 src/LR0.c \
27 src/LR0.h \
28 src/Sbitset.c \
29 src/Sbitset.h \
30 src/assoc.c \
31 src/assoc.h \
32 src/closure.c \
33 src/closure.h \
34 src/complain.c \
35 src/complain.h \
36 src/conflicts.c \
37 src/conflicts.h \
38 src/derives.c \
39 src/derives.h \
40 src/files.c \
41 src/files.h \
42 src/flex-scanner.h \
43 src/getargs.c \
44 src/getargs.h \
45 src/gram.c \
46 src/gram.h \
47 src/graphviz.c \
48 src/graphviz.h \
49 src/lalr.c \
50 src/lalr.h \
51 src/ielr.c \
52 src/ielr.h \
53 src/location.c \
54 src/location.h \
55 src/main.c \
56 src/muscle-tab.c \
57 src/muscle-tab.h \
58 src/named-ref.c \
59 src/named-ref.h \
60 src/nullable.c \
61 src/nullable.h \
62 src/output.c \
63 src/output.h \
64 src/parse-gram.h \
65 src/parse-gram.y \
66 src/print-xml.c \
67 src/print-xml.h \
68 src/print.c \
69 src/print.h \
70 src/print_graph.c \
71 src/print_graph.h \
72 src/reader.c \
73 src/reader.h \
74 src/reduce.c \
75 src/reduce.h \
76 src/relation.c \
77 src/relation.h \
78 src/scan-code-c.c \
79 src/scan-code.h \
80 src/scan-gram-c.c \
81 src/scan-gram.h \
82 src/scan-skel-c.c \
83 src/scan-skel.h \
84 src/state.c \
85 src/state.h \
86 src/symlist.c \
87 src/symlist.h \
88 src/symtab.c \
89 src/symtab.h \
90 src/system.h \
91 src/tables.c \
92 src/tables.h \
93 src/uniqstr.c \
94 src/uniqstr.h
95
96 EXTRA_src_bison_SOURCES = \
97 src/scan-code.l \
98 src/scan-gram.l \
99 src/scan-skel.l
100
101 BUILT_SOURCES += \
102 src/parse-gram.c \
103 src/parse-gram.h \
104 src/scan-code.c \
105 src/scan-gram.c \
106 src/scan-skel.c
107
108
109 ## ------ ##
110 ## yacc. ##
111 ## ------ ##
112
113 bin_SCRIPTS = $(YACC_SCRIPT)
114 EXTRA_SCRIPTS = src/yacc
115 MOSTLYCLEANFILES += src/yacc
116
117 src/yacc:
118 $(AM_V_GEN)rm -f $@ $@.tmp
119 $(AM_V_at)echo '#! /bin/sh' >$@.tmp
120 $(AM_V_at)echo "exec '$(bindir)/bison' -y "'"$$@"' >>$@.tmp
121 $(AM_V_at)chmod a+x $@.tmp
122 $(AM_V_at)mv $@.tmp $@