From 092e760d22c1a8e70a86d16fd3fe3d9d4819d922 Mon Sep 17 00:00:00 2001 From: Joey Castillo Date: Sun, 10 Apr 2022 12:45:21 -0400 Subject: add rule for static analysis --- rules.mk | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/rules.mk b/rules.mk index 1aa135a8..2f2f3922 100644 --- a/rules.mk +++ b/rules.mk @@ -4,6 +4,8 @@ OBJS = $(addprefix $(BUILD)/, $(notdir %/$(subst .c,.o, $(SRCS)))) SUBMODULES = tinyusb +COBRA = cobra -f + ifndef EMSCRIPTEN all: directory $(SUBMODULES) $(BUILD)/$(BIN).elf $(BUILD)/$(BIN).hex $(BUILD)/$(BIN).bin $(BUILD)/$(BIN).uf2 size else @@ -54,4 +56,7 @@ clean: @echo clean @-rm -rf $(BUILD) +analyze: + @$(COBRA) basic $(INCLUDES) $(DEFINES) $(SRCS) + -include $(wildcard $(BUILD)/*.d) -- cgit v1.2.3