From c962e7de51be765584504b11c84eb7023a9b9e89 Mon Sep 17 00:00:00 2001 From: Jeff Donahue Date: Sat, 12 Jul 2014 22:37:10 -0700 Subject: [PATCH] Travis build failure wasn't working for lint/warn because they didn't exit with a non-zero code -- this fixes that. --- Makefile | 18 ++++++++++-------- 1 file changed, 10 insertions(+), 8 deletions(-) diff --git a/Makefile b/Makefile index fc3ffe6..38c180c 100644 --- a/Makefile +++ b/Makefile @@ -292,10 +292,11 @@ $(EMPTY_LINT_REPORT): $(LINT_OUTPUTS) | $(BUILD_DIR) @ if [ -s "$@" ]; then \ cat $@; \ mv $@ $(NONEMPTY_LINT_REPORT); \ - else \ - $(RM) $(NONEMPTY_LINT_REPORT); \ - echo "No lint errors!"; \ - fi + echo "Found one or more lint errors."; \ + exit 1; \ + fi; \ + $(RM) $(NONEMPTY_LINT_REPORT); \ + echo "No lint errors!"; $(LINT_OUTPUTS): $(LINT_OUTPUT_DIR)/%.lint.txt : % | $(LINT_OUTPUT_DIR) @ mkdir -p $(dir $@) @@ -348,10 +349,11 @@ $(EMPTY_WARN_REPORT): $(ALL_WARNS) | $(BUILD_DIR) @ if [ -s "$@" ]; then \ cat $@; \ mv $@ $(NONEMPTY_WARN_REPORT); \ - else \ - $(RM) $(NONEMPTY_WARN_REPORT); \ - echo "No compiler warnings!"; \ - fi + echo "Found one or more lint errors."; \ + exit 1; \ + fi; \ + $(RM) $(NONEMPTY_WARN_REPORT); \ + echo "No compiler warnings!"; $(ALL_CXX_WARNS): %.o.$(WARNS_EXT) : %.o -- 2.7.4