help2man_dir := $(build_dir)/help2man
lls_suite_dir := $(build_dir)/lls
lls_m4_dir := m4/lls
-m4_ggo_dir := m4/gengetopt
test_dir := t
# sort removes duplicate words, which is all we need here
tarball: $(tarball)
include $(lls_m4_dir)/makefile
-include $(m4_ggo_dir)/makefile
include $(test_dir)/makefile.test
ifeq ($(findstring clean, $(MAKECMDGOALS)),)
-include $(deps)
+++ /dev/null
-define ggo_opts
- --output-dir=$(cmdline_dir) \
- --set-version="$(GIT_VERSION)" \
- --arg-struct-name=$(*F)_args_info \
- --file-name=$(*F).cmdline \
- --func-name=$(*F)_cmdline_parser \
- --set-package="para_$(*F)"
-endef
-
-.PRECIOUS: $(cmdline_dir)/%.cmdline.c $(cmdline_dir)/%.cmdline.h $(ggo_dir)/%.ggo
-
-$(cmdline_dir)/%.cmdline.h $(cmdline_dir)/%.cmdline.c: $(ggo_dir)/%.ggo | $(cmdline_dir)
- @[ -z "$(Q)" ] || echo 'GGO $<'
- $(Q) $(GENGETOPT) $(ggo_opts) < $<
-ifeq ($(ggo_descriptions_declared),no)
- @echo 'extern const char *$(*F)_args_info_description;' >> $(cmdline_dir)/$(*F).cmdline.h
-endif
-
-$(m4depdir)/%.m4d: $(m4_ggo_dir)/%.m4 | $(m4depdir)
- @[ -z "$(Q)" ] || echo 'M4D $<'
- $(Q) $(M4) -I $(m4_ggo_dir) -s $< \
- | awk '{if ($$1 ~ /#line/) {gsub(/"/, "", $$3); if ($$3 != "$<") \
- print "$(ggo_dir)/$(*F).ggo: " $$3}}' | sort | uniq > $@
-
-$(ggo_dir)/%.ggo: $(m4_ggo_dir)/%.m4 $(m4_ggo_dir)/header.m4 | $(ggo_dir)
- @[ -z "$(Q)" ] || echo 'M4 $<'
- $(Q) $(M4) -I $(m4_ggo_dir) $< > $@