about summary refs log tree commit homepage
path: root/GNUmakefile
diff options
context:
space:
mode:
authorEric Wong <e@80x24.org>2017-12-22 02:33:48 +0000
committerEric Wong <e@80x24.org>2017-12-22 03:14:34 +0000
commit2dedd116c95c5e675f37b053a8f09c8b3a294db6 (patch)
tree122d20722a6b268ea1fa1a1f23d9a32e93c0df36 /GNUmakefile
parent30e3c6abe542c6a9f5955e1d65896a0c3bab534f (diff)
downloadunicorn-2dedd116c95c5e675f37b053a8f09c8b3a294db6.tar.gz
Add a new "check-warnings" target to the GNUmakefile to make
checking for this easier.  Warnings aren't fatal, and newer
versions of Ruby tend to increase warnings.
Diffstat (limited to 'GNUmakefile')
-rw-r--r--GNUmakefile5
1 files changed, 5 insertions, 0 deletions
diff --git a/GNUmakefile b/GNUmakefile
index 51045d4..2505e1f 100644
--- a/GNUmakefile
+++ b/GNUmakefile
@@ -249,5 +249,10 @@ endif
 $(PLACEHOLDERS):
         echo olddoc_placeholder > $@
 
+check-warnings:
+        @(for i in $$(git ls-files '*.rb' bin | grep -v '^setup\.rb$$'); \
+          do $(RUBY) --disable-gems -d -W2 -c \
+          $$i; done) | grep -v '^Syntax OK$$' || :
+
 .PHONY: .FORCE-GIT-VERSION-FILE doc $(T) $(slow_tests) man
 .PHONY: test-install