aboutsummaryrefslogtreecommitdiff
path: root/tools/kconfig/build.mk
blob: 060dd995561f00784d14a517dcb28b2b9d984d6e (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
#!../../mach

HOSTTARGETBIN += conf mconf

lxdiag_srcs := \
    lxdialog/checklist.c lxdialog/inputbox.c lxdialog/menubox.c lxdialog/textbox.c lxdialog/util.c lxdialog/yesno.c

parser_srcs := \
    confdata.c expr.c menu.c preprocess.c symbol.c util.c \
    lex.yy.c parser.tab.c

conf.SRCS := ${parser_srcs} conf.c

mconf.SRCS := ${parser_srcs} ${lxdiag_srcs} mconf.c

HOST_CFLAGS := -D_GNU_SOURCE $(shell pkg-config --cflags ncursesw)
HOST_LDFLAGS := $(shell pkg-config --libs ncursesw)

%.tab.c: %.y
	bison --header --debug $<

lex.yy.c: lexer.l parser.tab.c
	flex $<

clean: clean.base
	@rm -f parser.tab.h parser.tab.c lex.yy.c