blob: f55fe75cbfd8bb604195381f9a4344e664f0199f (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
|
AM_CPPFLAGS = \
-D__BUILDING_CVC4PARSERLIB \
-I@srcdir@/../../include -I@srcdir@/../.. -I@builddir@/../.. $(ANTLR_INCLUDES)
AM_CXXFLAGS = -Wall -Wno-unknown-pragmas $(FLAG_VISIBILITY_HIDDEN) -Wno-unused-function -Wno-unused-variable
# Compile generated C files using C++ compiler
AM_CFLAGS = $(AM_CXXFLAGS)
CC=$(CXX)
ANTLR_OPTS =
# hide this included makefile from automake
@mk_include@ @srcdir@/../Makefile.antlr_tracing
noinst_LTLIBRARIES = libparsersmt2.la
ANTLR_TOKEN_STUFF = \
generated/Smt2.tokens
ANTLR_LEXER_STUFF = \
generated/Smt2Lexer.h \
generated/Smt2Lexer.c \
$(ANTLR_TOKEN_STUFF)
ANTLR_PARSER_STUFF = \
generated/Smt2Parser.h \
generated/Smt2Parser.c
ANTLR_STUFF = \
$(ANTLR_LEXER_STUFF) \
$(ANTLR_PARSER_STUFF)
libparsersmt2_la_SOURCES = \
Smt2.g \
smt2.h \
smt2.cpp \
smt2_input.h \
smt2_input.cpp \
$(ANTLR_STUFF)
BUILT_SOURCES = \
generated/Smt2.tokens \
generated/Smt2Lexer.h \
generated/Smt2Lexer.c \
generated/Smt2Parser.h \
generated/Smt2Parser.c \
stamp-generated
DISTCLEANFILES = $(ANTLR_STUFF)
distclean-local:
-$(AM_V_at)rmdir generated
-$(AM_V_at)rm -f stamp-generated
stamp-generated:
$(AM_V_at)mkdir -p generated
$(AM_V_at)touch stamp-generated
# antlr doesn't overwrite output files, it just leaves them. So we have to delete them first.
generated/Smt2Lexer.h: Smt2.g stamp-generated
-$(AM_V_at)rm -f $(ANTLR_STUFF)
@if test -z "$(ANTLR)"; then echo "ERROR: antlr parser generator cannot be found, cannot generate the parser" >&2; exit 1; fi
$(AM_V_GEN)$(ANTLR) $(ANTLR_OPTS) -fo "generated" "@srcdir@/Smt2.g"
# These don't actually depend on SmtLexer.h, but if we're doing parallel
# make and the lexer needs to be rebuilt, we have to keep the rules
# from running in parallel (since the token files will be deleted &
# recreated)
generated/Smt2Lexer.c generated/Smt2Parser.h generated/Smt2Parser.c $(ANTLR_TOKEN_STUFF): generated/Smt2Lexer.h
|