Skip to content
Snippets Groups Projects
Commit 0a364131 authored by Marcus M. Darden's avatar Marcus M. Darden
Browse files

Add "make static" for static analysis testing.

parent 02cbffe3
No related branches found
No related tags found
No related merge requests found
...@@ -24,7 +24,7 @@ LD_RUN_PATH := /usr/um/gcc-6.2.0/lib64 ...@@ -24,7 +24,7 @@ LD_RUN_PATH := /usr/um/gcc-6.2.0/lib64
# TODO # TODO
# Change EXECUTABLE to match the command name given in the project spec. # Change EXECUTABLE to match the command name given in the project spec.
EXECUTABLE = project0 EXECUTABLE = executable
DEBUG = $(EXECUTABLE)_debug DEBUG = $(EXECUTABLE)_debug
# designate which compiler to use # designate which compiler to use
...@@ -70,6 +70,11 @@ debug: clean all ...@@ -70,6 +70,11 @@ debug: clean all
profile: CXXFLAGS += -pg profile: CXXFLAGS += -pg
profile: clean all profile: clean all
# make static - will perform static analysis in the matter currently used
# on the autograder
static:
cppcheck --enable=all --suppress=missingIncludeSystem *.c* *.h*
# highest target; sews together all objects into executable # highest target; sews together all objects into executable
all: $(EXECUTABLE) all: $(EXECUTABLE)
...@@ -161,6 +166,11 @@ EECS281 Advanced Makefile Help ...@@ -161,6 +166,11 @@ EECS281 Advanced Makefile Help
C) If test drivers need special dependencies, they must be added manually. C) If test drivers need special dependencies, they must be added manually.
D) IMPORTANT: NO SOURCE FILES THAT BEGIN WITH test WILL BE ADDED TO ANY D) IMPORTANT: NO SOURCE FILES THAT BEGIN WITH test WILL BE ADDED TO ANY
SUBMISSION TARBALLS. SUBMISSION TARBALLS.
* Static Analysis support
A) Matches current autograder style grading tests
B) Usage:
$$ make static
endef endef
export MAKEFILE_HELP export MAKEFILE_HELP
...@@ -195,6 +205,6 @@ help: ...@@ -195,6 +205,6 @@ help:
###################### ######################
# these targets do not create any files # these targets do not create any files
.PHONY: all release debug profile clean alltests partialsubmit fullsubmit help .PHONY: all release debug profile static clean alltests partialsubmit fullsubmit help
# disable built-in rules # disable built-in rules
.SUFFIXES: .SUFFIXES:
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment