From: Jeff Donahue Date: Tue, 5 Aug 2014 23:19:31 +0000 (-0700) Subject: lint targets should depend on the lint script itself X-Git-Tag: submit/tizen/20180823.020014~620^2~118^2~3 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=dd883bdda70c11101badf194661770d7f358577c;p=platform%2Fupstream%2Fcaffeonacl.git lint targets should depend on the lint script itself --- diff --git a/Makefile b/Makefile index 2c071c8..287120a 100644 --- a/Makefile +++ b/Makefile @@ -62,6 +62,7 @@ NONGEN_CXX_SRCS := $(shell find \ examples \ tools \ -name "*.cpp" -or -name "*.hpp" -or -name "*.cu" -or -name "*.cuh") +LINT_SCRIPT := scripts/cpp_lint.py LINT_OUTPUT_DIR := $(BUILD_DIR)/.lint LINT_EXT := lint.txt LINT_OUTPUTS := $(addsuffix .$(LINT_EXT), $(addprefix $(LINT_OUTPUT_DIR)/, $(NONGEN_CXX_SRCS))) @@ -322,9 +323,9 @@ $(EMPTY_LINT_REPORT): $(LINT_OUTPUTS) | $(BUILD_DIR) $(RM) $(NONEMPTY_LINT_REPORT); \ echo "No lint errors!"; -$(LINT_OUTPUTS): $(LINT_OUTPUT_DIR)/%.lint.txt : % | $(LINT_OUTPUT_DIR) +$(LINT_OUTPUTS): $(LINT_OUTPUT_DIR)/%.lint.txt : % $(LINT_SCRIPT) | $(LINT_OUTPUT_DIR) @ mkdir -p $(dir $@) - @ python ./scripts/cpp_lint.py $< 2>&1 \ + @ python $(LINT_SCRIPT) $< 2>&1 \ | grep -v "^Done processing " \ | grep -v "^Total errors found: 0" \ > $@ \