From 98d8e730407977e2cdc6afc03eb5cbbe225be034 Mon Sep 17 00:00:00 2001 From: Attila Kovacs Date: Mon, 2 Dec 2024 14:46:47 +0100 Subject: [PATCH] Tweaked infer target --- Makefile | 14 ++++++++++---- build.mk | 5 ----- 2 files changed, 10 insertions(+), 9 deletions(-) diff --git a/Makefile b/Makefile index e7ebac8..5ca19ea 100644 --- a/Makefile +++ b/Makefile @@ -32,14 +32,14 @@ endif # Link against thread lib LDFLAGS += -pthread -# Build everything... -.PHONY: all -all: shared static $(DOC_TARGETS) check - # Build for distribution .PHONY: distro distro: shared $(DOC_TARGETS) +# Build everything... +.PHONY: all +all: shared static $(DOC_TARGETS) check + # Shared libraries (versioned and unversioned) .PHONY: shared shared: $(LIB)/libredisx.so @@ -57,6 +57,11 @@ test: .PHONY: check check: test analyze +# Static code analysis via Facebook's infer +.PHONY: infer +infer: clean + infer run -- make shared + # Remove intermediates .PHONY: clean clean: @@ -178,6 +183,7 @@ help: @echo " local-dox Compiles local HTML API documentation using 'doxygen'." @echo " analyze Performs static analysis with 'cppcheck'." @echo " all All of the above." + @echo " distro shared libs and documentation (default target)." @echo " install Install components (e.g. 'make prefix= install')" @echo " clean Removes intermediate products." @echo " distclean Deletes all generated files." diff --git a/build.mk b/build.mk index 20df924..a6ace54 100644 --- a/build.mk +++ b/build.mk @@ -54,11 +54,6 @@ analyze: @echo " [analyze]" @cppcheck $(CPPFLAGS) $(CHECKOPTS) src -# Static code analysis via Facebook's infer -.PHONY: infer -infer: CC := infer run -- $(CC) -infer: distclean shared - # Doxygen documentation (HTML and man pages) under apidocs/ .PHONY: dox dox: README.md Doxyfile apidoc $(SRC) $(INC)