about summary refs log tree commit homepage
path: root/GNUmakefile
diff options
context:
space:
mode:
Diffstat (limited to 'GNUmakefile')
-rw-r--r--GNUmakefile92
1 files changed, 3 insertions, 89 deletions
diff --git a/GNUmakefile b/GNUmakefile
index 8cd6df8..6b9ee5e 100644
--- a/GNUmakefile
+++ b/GNUmakefile
@@ -1,90 +1,4 @@
-# use GNU Make to run tests in parallel, and without depending on Rubygems
-all:: test
+all::
 RSYNC_DEST := bogomips.org:/srv/bogomips/mogilefs-client
-git_version_gen := $(shell ./GIT-VERSION-GEN)
-
-T := $(wildcard test/test*.rb)
-TO := $(subst .rb,.log,$(T))
-
-test: $(T)
-        @cat $(TO) | ruby test/aggregate.rb
-        @$(RM) $(TO)
-clean:
-        $(RM) $(TO) $(addsuffix +,$(TO))
-
-
-ifndef V
-  quiet_pre = @echo '* $@';
-  quiet_post = >$(t) 2>&1
-else
-  # we can't rely on -o pipefail outside of bash 3+,
-  # so we use a stamp file to indicate success and
-  # have rm fail if the stamp didn't get created
-  stamp = $@$(log_suffix).ok
-  quiet_pre = @echo $(ruby) $@ $(TEST_OPTS); ! test -f $(stamp) && (
-  quiet_post = && > $(stamp) )>&2 | tee $(t); rm $(stamp) 2>/dev/null
-endif
-ruby = ruby
-run_test = $(quiet_pre) setsid $(ruby) -w $@ $(TEST_OPTS) $(quiet_post) || \
-  (sed "s,^,$(extra): ," >&2 < $(t); exit 1)
-
-$(T): t = $(subst .rb,.log,$@)
-$(T): export RUBYLIB := $(CURDIR)/lib:$(RUBYLIB)
-$(T):
-        $(run_test)
-
-RUBY_VERSION_FILE = lib/mogilefs/version.rb
-package:
-        git diff --exit-code HEAD^0
-        $(RM) -r pkg/
-        rake fix_perms
-        rake package
-
-libs := $(wildcard lib/*.rb lib/*/*.rb)
-flay_flags =
-flog_flags =
-flay: $(libs)
-        flay $(flay_flags) $^
-flog: $(libs)
-        flog $(flog_flags) $^
-.PHONY: $(T)
-
-check-warnings:
-        @(for i in $$(git ls-files '*.rb'| grep -v '^setup\.rb$$'); \
-          do ruby -d -W2 -c $$i; done) | grep -v '^Syntax OK$$' || :
-RSYNC = rsync
-WRONGDOC = wrongdoc
-
-doc:: .document .wrongdoc.yml $(pkg_extra)
-        -find lib -type f -name '*.rbc' -exec rm -f '{}' ';'
-        $(RM) -r doc
-        $(WRONGDOC) all
-        install -m644 $(shell LC_ALL=C grep '^[A-Z]' .document) doc/
-        cd doc && \
-                ln -s README README.txt && \
-                ln -s README.html README_txt.html && \
-                ln -s LICENSE LICENSE.txt && \
-                ln -s LICENSE.html LICENSE_txt.html && \
-                ln -s History History.txt && \
-                ln -s History.html History_txt.html
-
-# Create gzip variants of the same timestamp as the original so nginx
-# "gzip_static on" can serve the gzipped versions directly.
-doc_gz: docs = $(shell find doc -type f ! -regex '^.*\.\(gif\|jpg\|png\|gz\)$$')
-doc_gz:
-        for i in $(docs); do \
-          gzip --rsyncable -9 < $$i > $$i.gz; touch -r $$i $$i.gz; done
-
-# this requires GNU coreutils variants
-ifneq ($(RSYNC_DEST),)
-publish_doc:
-        -git set-file-times
-        $(MAKE) doc
-        find doc/images -type f | \
-                TZ=UTC xargs touch -d '1970-01-01 00:00:06' doc/rdoc.css
-        $(MAKE) doc_gz
-        $(RSYNC) -av doc/ $(RSYNC_DEST)/
-        git ls-files | xargs touch
-endif
-
-.PHONY: doc .FORCE-GIT-VERSION-FILE
+rfpackage := mogilefs-client
+include pkg.mk