1 |
INCLUDES = $(all_includes) |
2 |
METASOURCES = AUTO |
3 |
|
4 |
AM_CXXFLAGS = -ffast-math -march=$(target_cpu) -mcpu=$(target_cpu) |
5 |
|
6 |
noinst_LTLIBRARIES = liblinuxsamplernetwork.la |
7 |
liblinuxsamplernetwork_la_SOURCES = lscp.h lscpparser.cpp lscpparser.h lscpscanner.cpp lscpserver.cpp lscpserver.h lscpsymbols.h |
8 |
|
9 |
.PHONY: parser |
10 |
|
11 |
# generate parser with lex and yacc |
12 |
parser: |
13 |
@echo "Generating LSCP parser..." |
14 |
@if which "lex" > /dev/null && which "yacc" > /dev/null; then \ |
15 |
yacc -d lscp.y && \ |
16 |
lex --fast --8bit lscp.l && \ |
17 |
yacc lscp.y && \ |
18 |
mv -f y.tab.h lscpsymbols.h && \ |
19 |
mv -f y.tab.c lscpparser.cpp && \ |
20 |
mv -f lex.yy.c lscpscanner.cpp; \ |
21 |
else \ |
22 |
echo "You need lex (or flex) and yacc (or bison) to generate the parser."; \ |
23 |
fi; |