From a4a97b6b268cec0f0c468fdc4700b17092bc3ba5 Mon Sep 17 00:00:00 2001 From: Mark Wooding Date: Sat, 24 May 2014 23:20:55 +0100 Subject: [PATCH] Makefile: Add `dist' target. I don't think source distributions are really the right answer for Chopwood, but it's a tradition, and it doesn't seem like a harmful one. For the record: you're expected to run Chopwood out of a Git clone; and users should get distributions from you using the AGPL-required `source' command. --- Makefile | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) diff --git a/Makefile b/Makefile index 13a7b59..3ccd4e5 100644 --- a/Makefile +++ b/Makefile @@ -117,4 +117,23 @@ CLEANFILES += $(TARGETS) clean::; rm -f $(CLEANFILES) .PHONY: clean +###-------------------------------------------------------------------------- +### Distributions. + +distdir = $(PACKAGE)-$(VERSION) + +DISTFILES = $(SOURCES) +DISTFILES += AGPLv3 +DISTFILES += Makefile get-version +DISTFILES += userv.rc + +dist: + rm -rf $(distdir) + mkdir $(distdir) + cp $(DISTFILES) $(distdir) + echo $(VERSION) >$(distdir)/RELEASE + tar cvfz $(distdir).tar.gz $(distdir) + rm -rf $(distdir) +.PHONY: dist + ###----- That's all, folks -------------------------------------------------- -- 2.11.0