Conf: Fixed makefiles
This commit is contained in:
parent
4f082dfa89
commit
75206f266f
5 changed files with 11 additions and 5 deletions
|
@ -76,6 +76,8 @@ $(daemon): LIBS += $(DAEMON_LIBS)
|
||||||
# Include directories
|
# Include directories
|
||||||
dirs := client conf doc filter lib nest test $(addprefix proto/,$(protocols)) @sysdep_dirs@
|
dirs := client conf doc filter lib nest test $(addprefix proto/,$(protocols)) @sysdep_dirs@
|
||||||
|
|
||||||
|
# conf/Makefile declarations needed for all other modules
|
||||||
|
conf-lex-targets := $(addprefix $(objdir)/conf/,cf-lex.o)
|
||||||
conf-y-targets := $(addprefix $(objdir)/conf/,cf-parse.y keywords.h commands.h)
|
conf-y-targets := $(addprefix $(objdir)/conf/,cf-parse.y keywords.h commands.h)
|
||||||
cf-local = $(conf-y-targets): $(s)config.Y
|
cf-local = $(conf-y-targets): $(s)config.Y
|
||||||
|
|
||||||
|
@ -99,6 +101,7 @@ endef
|
||||||
|
|
||||||
clean = $(eval $(call clean_in,$(1)))
|
clean = $(eval $(call clean_in,$(1)))
|
||||||
|
|
||||||
|
# Include main Makefiles of the directories
|
||||||
include $(addsuffix /Makefile,$(addprefix $(srcdir)/,$(dirs)))
|
include $(addsuffix /Makefile,$(addprefix $(srcdir)/,$(dirs)))
|
||||||
|
|
||||||
# Generic rules
|
# Generic rules
|
||||||
|
|
|
@ -2,6 +2,7 @@ src := commands.c util.c client.c
|
||||||
obj := $(src-o-files)
|
obj := $(src-o-files)
|
||||||
|
|
||||||
$(all-client)
|
$(all-client)
|
||||||
|
$(conf-y-targets): $(s)cmds.Y
|
||||||
|
|
||||||
$(o)commands.o: $(objdir)/conf/commands.h
|
$(o)commands.o: $(objdir)/conf/commands.h
|
||||||
|
|
||||||
|
|
|
@ -10,12 +10,12 @@ BISON_DEBUG=-t
|
||||||
#FLEX_DEBUG=-d
|
#FLEX_DEBUG=-d
|
||||||
endif
|
endif
|
||||||
|
|
||||||
$(conf-y-targets): $(s)confbase.Y $(s)flowspec.Y
|
$(o)cf-parse.y: $(s)gen_parser.m4
|
||||||
$(M4) $(M4FLAGS) -P $| $^ >$@
|
$(o)keywords.h: $(s)gen_keywords.m4
|
||||||
|
$(o)commands.h: $(s)gen_commands.m4
|
||||||
|
|
||||||
$(o)cf-parse.y: | $(s)gen_parser.m4
|
$(conf-y-targets): $(s)confbase.Y $(s)flowspec.Y
|
||||||
$(o)keywords.h: | $(s)gen_keywords.m4
|
$(M4) $(M4FLAGS) -P $(if $(word 2,$(filter %.m4,$^)),$(error "Too many M4 scripts for one target"),$(filter %.m4,$^)) $(filter %.Y,$^) >$@
|
||||||
$(o)commands.h: | $(s)gen_commands.m4 $(srcdir)/client/cmds.m4
|
|
||||||
|
|
||||||
$(o)cf-parse.tab.h: $(o)cf-parse.tab.c
|
$(o)cf-parse.tab.h: $(o)cf-parse.tab.c
|
||||||
|
|
||||||
|
|
|
@ -3,6 +3,8 @@ obj := $(src-o-files)
|
||||||
$(all-daemon)
|
$(all-daemon)
|
||||||
$(cf-local)
|
$(cf-local)
|
||||||
|
|
||||||
|
$(conf-y-targets) $(conf-lex-targets): $(o)f-inst-decl.h
|
||||||
|
|
||||||
M4FLAGS_FILTERS=$(filter-out -s,$(M4FLAGS))
|
M4FLAGS_FILTERS=$(filter-out -s,$(M4FLAGS))
|
||||||
|
|
||||||
$(o)f-inst-postfixify.c: $(s)postfixify.m4 $(s)f-inst.c $(objdir)/.dir-stamp
|
$(o)f-inst-postfixify.c: $(s)postfixify.m4 $(s)f-inst.c $(objdir)/.dir-stamp
|
||||||
|
|
Loading…
Reference in a new issue