X-Git-Url: http://git.ozlabs.org/?p=ccan;a=blobdiff_plain;f=tools%2Fccanlint%2FMakefile;h=691f270890e0f352edc3f2815c97a01ab59428ad;hp=f027e20af102f2ee706dba12ab453ffb7c94a34b;hb=9e207bca5bf5e0a1e3653a91649414fab793c801;hpb=7beaa3448fa8e6015798c1609f33d96e8986063d diff --git a/tools/ccanlint/Makefile b/tools/ccanlint/Makefile index f027e20a..691f2708 100644 --- a/tools/ccanlint/Makefile +++ b/tools/ccanlint/Makefile @@ -1,33 +1,50 @@ -OBJS := tools/ccanlint/no_info.o \ - tools/ccanlint/has_main_header.o \ - tools/ccanlint/has_tests.o \ - tools/ccanlint/trailing_whitespace.o \ - tools/ccanlint/idempotent.o \ +TEST_CFILES := $(wildcard tools/ccanlint/tests/*.c) +TEST_OBJS := $(TEST_CFILES:.c=.o) -FUTURE:=tools/ccanlint/if_have_not_ifdef.o \ - tools/ccanlint/needs_depends.o \ - tools/ccanlint/has_info_documentation.o \ - tools/ccanlint/has_header_documentation.o \ - tools/ccanlint/has_tests.o \ - tools/ccanlint/builds_ok.o \ - tools/ccanlint/builds_ok_all_have_variants.o \ - tools/ccanlint/run_tests.o \ - tools/ccanlint/test_coverage.o \ - -tools/ccanlint/generated-init-tests: $(OBJS) - cat $(OBJS:.o=.c) | sed -n 's/^struct ccanlint \([A-Za-z0-9_]*\) = {/{ extern struct ccanlint \1; list_add(\&tests, \&\1.list); }/p' >$@ - -tools/ccanlint/ccanlint.o: tools/ccanlint/generated-init-tests - -tools/ccanlint/ccanlint: \ - $(OBJS) \ +CORE_OBJS := \ + ccan/asort/asort.o \ + ccan/autodata/autodata.o \ + ccan/dgraph/dgraph.o \ + ccan/foreach/foreach.o \ + ccan/hash/hash.o \ + ccan/htable/htable.o \ + ccan/ilog/ilog.o \ + ccan/lbalance/lbalance.o \ + ccan/list/list.o \ + ccan/noerr/noerr.o \ + ccan/opt/helpers.o \ + ccan/opt/opt.o \ + ccan/opt/parse.o \ + ccan/opt/usage.o \ + ccan/ptr_valid/ptr_valid.o \ + ccan/rbuf/rbuf.o \ + ccan/read_write_all/read_write_all.o \ + ccan/str/str.o ccan/str/debug.o \ + ccan/strmap/strmap.o \ + ccan/take/take.o \ + ccan/tal/tal.o \ + ccan/tal/grab_file/grab_file.o \ + ccan/tal/link/link.o \ + ccan/tal/path/path.o \ + ccan/tal/str/str.o \ + ccan/time/time.o \ + tools/ccanlint/async.o \ tools/ccanlint/ccanlint.o \ tools/ccanlint/file_analysis.o \ + tools/ccanlint/licenses.o \ + tools/ccan_dir.o \ + tools/compile.o \ + tools/depends.o \ tools/doc_extract-core.o \ - ccan/str_talloc/str_talloc.o ccan/grab_file/grab_file.o \ - ccan/talloc/talloc.o ccan/noerr/noerr.o + tools/manifest.o \ + tools/read_config_header.o \ + tools/tools.o + +OBJS := $(CORE_OBJS) $(TEST_OBJS) + +$(CORE_OBJS): config.h + +tools/ccanlint/ccanlint: $(OBJS) ccanlint-clean: - $(RM) tools/ccanlint/generated-init-tests $(RM) tools/ccanlint/ccanlint -