From 405053de2c6f515e6114f9a13f90110ef5aff6b1 Mon Sep 17 00:00:00 2001 From: Georg Hopp Date: Thu, 26 Jan 2017 21:35:10 +0100 Subject: [PATCH] add target to create dist file --- AUTHORS | 1 + Makefile | 18 ++++++++++++++++-- VERSION | 1 + 3 files changed, 18 insertions(+), 2 deletions(-) create mode 100644 AUTHORS create mode 100644 VERSION diff --git a/AUTHORS b/AUTHORS new file mode 100644 index 0000000..354d97f --- /dev/null +++ b/AUTHORS @@ -0,0 +1 @@ +Georg Hopp diff --git a/Makefile b/Makefile index 34a875d..d78a64c 100644 --- a/Makefile +++ b/Makefile @@ -21,7 +21,16 @@ DESTDIR ?= export PREFIX DESTDIR -PROGRAM := accountmanager.sh +PROGRAM = accountmanager.sh + +DIST_FILES = doc/Makefile \ + doc/accountmanager.1 \ + $(PROGRAM) \ + Makefile \ + README.md \ + LICENSE \ + VERSION \ + AUTHORS all: doc @@ -29,7 +38,12 @@ README_new.md: doc/accountmanager.1 groff -D utf8 -mandoc -Thtml "$<" |\ pandoc -f html -t markdown_strict >"$@" -.PHONY: clean install doc +.PHONY: clean install doc dist + +dist: ARCHIVE_NAME = $(basename $(PROGRAM))-`cat VERSION` +dist: clean $(DIST_FILES) + tar cvf - --xform="s/^/$(ARCHIVE_NAME)\//" $(DIST_FILES) | \ + bzip2 -9 -c >$(ARCHIVE_NAME).tar.bz2 doc: make -C doc diff --git a/VERSION b/VERSION new file mode 100644 index 0000000..9f8e9b6 --- /dev/null +++ b/VERSION @@ -0,0 +1 @@ +1.0 \ No newline at end of file