]> git.ipfire.org Git - people/ms/u-boot.git/blobdiff - Makefile
Makefile: add coccicheck target
[people/ms/u-boot.git] / Makefile
index b5f81e3627b48957c78a8418683c27f77d7a67be..fea1954247143e8a41226693e2f490ab698be5aa 100644 (file)
--- a/Makefile
+++ b/Makefile
@@ -1572,6 +1572,7 @@ help:
        @echo  ''
        @echo  'Static analysers'
        @echo  '  checkstack      - Generate a list of stack hogs'
+       @echo  '  coccicheck      - Execute static code analysis with Coccinelle'
        @echo  ''
        @echo  'Documentation targets:'
        @$(MAKE) -f $(srctree)/doc/DocBook/Makefile dochelp
@@ -1664,6 +1665,14 @@ endif
        $(build)=$(build-dir) $(@:.ko=.o)
        $(Q)$(MAKE) -f $(srctree)/scripts/Makefile.modpost
 
+# Consistency checks
+# ---------------------------------------------------------------------------
+
+PHONY += coccicheck
+
+coccicheck:
+       $(Q)$(CONFIG_SHELL) $(srctree)/scripts/$@
+
 # FIXME Should go into a make.lib or something
 # ===========================================================================