@@ -1005,8 +1005,8 @@ SPATCH_TEST_FLAGS =
10051005# COMPUTE_HEADER_DEPENDENCIES=no this will be unset too.
10061006SPATCH_USE_O_DEPENDENCIES = YesPlease
10071007
1008- # Set SPATCH_CONCAT_COCCI to concatenate the contrib/cocci /*.cocci
1009- # files into a single contrib/cocci /ALL.cocci before running
1008+ # Set SPATCH_CONCAT_COCCI to concatenate the tools/coccinelle /*.cocci
1009+ # files into a single tools/coccinelle /ALL.cocci before running
10101010# "coccicheck".
10111011#
10121012# Pros:
@@ -1025,7 +1025,7 @@ SPATCH_USE_O_DEPENDENCIES = YesPlease
10251025# generate a specific patch, e.g. this will always use strbuf.cocci,
10261026# not ALL.cocci:
10271027#
1028- # make contrib /coccinelle/strbuf.cocci.patch
1028+ # make tools /coccinelle/strbuf.cocci.patch
10291029SPATCH_CONCAT_COCCI = YesPlease
10301030
10311031# Rebuild 'coccicheck' if $(SPATCH), its flags etc. change
@@ -3457,15 +3457,15 @@ check:
34573457 exit 1; \
34583458 fi
34593459
3460- COCCI_GEN_ALL = .build/contrib /coccinelle/ALL.cocci
3461- COCCI_GLOB = $(wildcard contrib /coccinelle/* .cocci)
3460+ COCCI_GEN_ALL = .build/tools /coccinelle/ALL.cocci
3461+ COCCI_GLOB = $(wildcard tools /coccinelle/* .cocci)
34623462COCCI_RULES_TRACKED = $(COCCI_GLOB:%=.build/% )
34633463COCCI_RULES_TRACKED_NO_PENDING = $(filter-out % .pending.cocci,$(COCCI_RULES_TRACKED ) )
34643464COCCI_RULES =
34653465COCCI_RULES += $(COCCI_GEN_ALL )
34663466COCCI_RULES += $(COCCI_RULES_TRACKED )
34673467COCCI_NAMES =
3468- COCCI_NAMES += $(COCCI_RULES:.build/contrib /coccinelle/%.cocci=% )
3468+ COCCI_NAMES += $(COCCI_RULES:.build/tools /coccinelle/%.cocci=% )
34693469
34703470COCCICHECK_PENDING = $(filter % .pending.cocci,$(COCCI_RULES ) )
34713471COCCICHECK = $(filter-out $(COCCICHECK_PENDING ) ,$(COCCI_RULES ) )
@@ -3480,20 +3480,20 @@ COCCICHECK_PATCHES_PENDING_INTREE = $(COCCICHECK_PATCHES_PENDING:.build/%=%)
34803480# on $(MAKECMDGOALS) that match these $(COCCI_RULES)
34813481COCCI_RULES_GLOB =
34823482COCCI_RULES_GLOB += cocci%
3483- COCCI_RULES_GLOB += .build/contrib /coccinelle/%
3483+ COCCI_RULES_GLOB += .build/tools /coccinelle/%
34843484COCCI_RULES_GLOB += $(COCCICHECK_PATCHES )
34853485COCCI_RULES_GLOB += $(COCCICHEC_PATCHES_PENDING )
34863486COCCI_RULES_GLOB += $(COCCICHECK_PATCHES_INTREE )
34873487COCCI_RULES_GLOB += $(COCCICHECK_PATCHES_PENDING_INTREE )
34883488COCCI_GOALS = $(filter $(COCCI_RULES_GLOB ) ,$(MAKECMDGOALS ) )
34893489
3490- COCCI_TEST_RES = $(wildcard contrib /coccinelle/tests/* .res)
3490+ COCCI_TEST_RES = $(wildcard tools /coccinelle/tests/* .res)
34913491
34923492$(COCCI_RULES_TRACKED ) : .build/% : %
34933493 $(call mkdir_p_parent_template)
34943494 $(QUIET_CP ) cp $< $@
34953495
3496- .build/contrib /coccinelle/FOUND_H_SOURCES : $(FOUND_H_SOURCES )
3496+ .build/tools /coccinelle/FOUND_H_SOURCES : $(FOUND_H_SOURCES )
34973497 $(call mkdir_p_parent_template)
34983498 $(QUIET_GEN ) > $@
34993499
@@ -3507,12 +3507,12 @@ endif
35073507define cocci-rule
35083508
35093509# # Rule for .build/$(1).patch/$(2); Params:
3510- # $(1) = e.g. ".build/contrib /coccinelle/free.cocci"
3510+ # $(1) = e.g. ".build/tools /coccinelle/free.cocci"
35113511# $(2) = e.g. "grep.c"
35123512# $(3) = e.g. "grep.o"
3513- COCCI_$(1:.build/contrib /coccinelle/%.cocci=% ) += $(1 ) .d/$(2 ) .patch
3513+ COCCI_$(1:.build/tools /coccinelle/%.cocci=% ) += $(1 ) .d/$(2 ) .patch
35143514$(1 ) .d/$(2 ) .patch: GIT-SPATCH-DEFINES
3515- $(1 ) .d/$(2 ) .patch: $(if $(and $(SPATCH_USE_O_DEPENDENCIES ) ,$(wildcard $(3 ) ) ) ,$(3 ) ,.build/contrib /coccinelle/FOUND_H_SOURCES)
3515+ $(1 ) .d/$(2 ) .patch: $(if $(and $(SPATCH_USE_O_DEPENDENCIES ) ,$(wildcard $(3 ) ) ) ,$(3 ) ,.build/tools /coccinelle/FOUND_H_SOURCES)
35163516$(1 ) .d/$(2 ) .patch: $(1 )
35173517$(1 ) .d/$(2 ) .patch: $(1 ) .d/%.patch : %
35183518 $$(call mkdir_p_parent_template)
@@ -3538,13 +3538,13 @@ endif
35383538
35393539define spatch-rule
35403540
3541- .build/contrib /coccinelle/$(1 ) .cocci.patch: $$(COCCI_$(1 ) )
3541+ .build/tools /coccinelle/$(1 ) .cocci.patch: $$(COCCI_$(1 ) )
35423542 $$(QUIET_SPATCH_CAT ) cat $$^ >$$@ && \
35433543 if test -s $$@ ; \
35443544 then \
35453545 echo ' ' SPATCH result: $$@ ; \
35463546 fi
3547- contrib /coccinelle/$(1 ) .cocci.patch: .build/contrib /coccinelle/$(1 ) .cocci.patch
3547+ tools /coccinelle/$(1 ) .cocci.patch: .build/tools /coccinelle/$(1 ) .cocci.patch
35483548 $$(QUIET_CP ) cp $$< $$@
35493549
35503550endef
@@ -3558,9 +3558,9 @@ $(COCCI_TEST_RES_GEN): GIT-SPATCH-DEFINES
35583558$(COCCI_TEST_RES_GEN ) : .build/% .res : % .c
35593559$(COCCI_TEST_RES_GEN ) : .build/% .res : % .res
35603560ifdef SPATCH_CONCAT_COCCI
3561- $(COCCI_TEST_RES_GEN ) : .build/contrib /coccinelle/tests/% .res : $(COCCI_GEN_ALL )
3561+ $(COCCI_TEST_RES_GEN ) : .build/tools /coccinelle/tests/% .res : $(COCCI_GEN_ALL )
35623562else
3563- $(COCCI_TEST_RES_GEN ) : .build/contrib /coccinelle/tests/% .res : contrib /coccinelle/% .cocci
3563+ $(COCCI_TEST_RES_GEN ) : .build/tools /coccinelle/tests/% .res : tools /coccinelle/% .cocci
35643564endif
35653565 $(call mkdir_p_parent_template)
35663566 $(QUIET_SPATCH_TEST)$(SPATCH) $(SPATCH_TEST_FLAGS) \
@@ -3576,14 +3576,14 @@ coccicheck-test: $(COCCI_TEST_RES_GEN)
35763576coccicheck : coccicheck-test
35773577
35783578ifdef SPATCH_CONCAT_COCCI
3579- COCCICHECK_PATCH_MUST_BE_EMPTY_FILES = contrib /coccinelle/ALL.cocci.patch
3579+ COCCICHECK_PATCH_MUST_BE_EMPTY_FILES = tools /coccinelle/ALL.cocci.patch
35803580else
35813581COCCICHECK_PATCH_MUST_BE_EMPTY_FILES = $(COCCICHECK_PATCHES_INTREE )
35823582endif
35833583coccicheck : $(COCCICHECK_PATCH_MUST_BE_EMPTY_FILES )
35843584 ! grep ^ $(COCCICHECK_PATCH_MUST_BE_EMPTY_FILES ) /dev/null
35853585
3586- # See contrib /coccinelle/README
3586+ # See tools /coccinelle/README
35873587coccicheck-pending : coccicheck-test
35883588coccicheck-pending : $(COCCICHECK_PATCHES_PENDING_INTREE )
35893589
@@ -3857,8 +3857,8 @@ profile-clean:
38573857
38583858cocciclean :
38593859 $(RM ) GIT-SPATCH-DEFINES
3860- $(RM ) -r .build/contrib /coccinelle
3861- $(RM ) contrib /coccinelle/* .cocci.patch
3860+ $(RM ) -r .build/tools /coccinelle
3861+ $(RM ) tools /coccinelle/* .cocci.patch
38623862
38633863clean : profile-clean coverage-clean cocciclean
38643864 $(RM ) -r .build $(UNIT_TEST_BIN )
0 commit comments