2c0d748800c14b96805cceb456e13a6050400db9
[lttng-tools.git] / src / lib / lttng-ctl / filter / Makefile.am
1 AM_CPPFLAGS = -I$(top_srcdir)/include -I$(top_srcdir)/src \
2 -I$(srcdir) -I$(builddir)
3
4 noinst_PROGRAMS = filter-grammar-test
5 noinst_LTLIBRARIES = libfilter.la
6 noinst_HEADERS = filter-ast.h \
7 filter-symbols.h
8
9 BUILT_SOURCES = filter-parser.h
10
11 libfilter_la_SOURCES = \
12 filter-parser.y filter-lexer.l \
13 filter-visitor-set-parent.c \
14 filter-visitor-xml.c \
15 filter-visitor-generate-ir.c \
16 filter-visitor-ir-check-binary-op-nesting.c \
17 filter-visitor-ir-validate-string.c \
18 filter-visitor-ir-validate-globbing.c \
19 filter-visitor-ir-normalize-glob-patterns.c \
20 filter-visitor-generate-bytecode.c \
21 filter-ast.h \
22 filter-bytecode.h \
23 filter-ir.h \
24 memstream.h
25 libfilter_la_CFLAGS = -include filter-symbols.h
26 libfilter_la_LIBADD = $(top_builddir)/src/common/string-utils/libstring-utils.la
27
28 AM_YFLAGS = -t -d -v
29
30 # start with empty files to clean
31 CLEANFILES =
32
33 if HAVE_BISON
34 # we have bison: we can clean the generated parser files
35 CLEANFILES += filter-parser.c filter-parser.h filter-parser.output
36 else # HAVE_BISON
37 # create target used to stop the build if we want to build the parser,
38 # but we don't have the necessary tool to do so
39 ERR_MSG = "Error: Cannot build target because bison is missing."
40 ERR_MSG += "Make sure bison is installed and run the configure script again."
41
42 filter-parser.c filter-parser.h: filter-parser.y
43 @echo $(ERR_MSG)
44 @false
45
46 all-local: filter-parser.c filter-parser.h
47 endif # HAVE_BISON
48
49 if HAVE_FLEX
50 # we have flex: we can clean the generated lexer files
51 CLEANFILES += filter-lexer.c
52 else # HAVE_FLEX
53 # create target used to stop the build if we want to build the lexer,
54 # but we don't have the necessary tool to do so
55 ERR_MSG = "Error: Cannot build target because flex is missing."
56 ERR_MSG += "Make sure flex is installed and run the configure script again."
57
58 filter-lexer.c: filter-lexer.l
59 @echo $(ERR_MSG)
60 @false
61
62 all-local: filter-lexer.c
63 endif # HAVE_FLEX
64
65 filter_grammar_test_SOURCES = filter-grammar-test.c
66 filter_grammar_test_LDADD = libfilter.la
This page took 0.031751 seconds and 4 git commands to generate.