From 3f54a989f3516cb47cf435c38490b098ebac8fa7 Mon Sep 17 00:00:00 2001 From: prozessorkern Date: Sun, 19 Apr 2020 14:45:42 +0200 Subject: [PATCH] fixed cppcheck call for older versions of cppcheck - removed misra checking (is broken anyway if there is no misra text file present --- makefile | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/makefile b/makefile index 4d5d3f4..b3f2998 100644 --- a/makefile +++ b/makefile @@ -53,7 +53,7 @@ TESTFLAGS := $(INCLUDES:%=-I%) -g -Wall -Werror -Wextra -fprofile-arcs -ftest- TESTLFLAGS := -fprofile-arcs -Wl,--allow-multiple-definition DEPEND = -MT $@ -MF "$(@:%.o=%.d)" -MG -MM - + COBJ := $(patsubst %.c,$(OBJ_DIR)%.o,$(SOURCES)) EXAMPLE_SOURCES := example/main.c @@ -72,17 +72,18 @@ export help: @echo Shellmatta help - @echo ------------------------- + @echo ----------------------------------------------- @echo test - run all tests + @echo cppcheck - run static code analysis (cppcheck) @echo example - build example - @echo ------------------------- + @echo ----------------------------------------------- test: unittest integrationtest cppcheck: - @mkdir -p output/cppcheck/html - cppcheck --addon=/usr/bin/misra.py --enable=all --template=gcc --cppcheck-build-dir=output/cppcheck $(SOURCES) - cppcheck --addon=/usr/bin/misra.py --enable=all --template=gcc --cppcheck-build-dir=output/cppcheck $(SOURCES) --xml 2>output/cppcheck/cppcheck.xml + cppcheck --enable=all --template=gcc --cppcheck-build-dir=output/cppcheck $(SOURCES) + cppcheck --enable=all --template=gcc --cppcheck-build-dir=output/cppcheck $(SOURCES) --xml 2>output/cppcheck/cppcheck.xml cppcheck-htmlreport --file=output/cppcheck/cppcheck.xml --title="Shellmatta" --report-dir=output/cppcheck/html unittest: $(UNITTEST_TARGET)