From 34c1b4cc87ea990ea262694cdf8ee681bfdef6d2 Mon Sep 17 00:00:00 2001 From: Tobias Klauser Date: Thu, 22 Dec 2016 10:12:21 +0100 Subject: build: Add release target Add a release target to the Makefile (akin to the one from netsniff-ng) in order to streamline the release process. Signed-off-by: Tobias Klauser --- Makefile | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/Makefile b/Makefile index 6c87f7a..16752fc 100644 --- a/Makefile +++ b/Makefile @@ -72,3 +72,18 @@ clean: @echo " CLEAN" @rm -f $(D_OBJS) $(D_P) @rm -f $(Q_OBJS) $(Q_P) + +# Maintainer targets + +GIT_TAG = git tag -a v$(VERSION) -s -m "llmnrd $(VERSION) release" +GIT_ARCHIVE = git archive --prefix=llmnrd-$(VERSION)/ v$(VERSION) | \ + $(1) -9 > ../llmnrd-$(VERSION).tar.$(2) +GPG_SIGN = gpg -a --output ../llmnrd-$(VERSION).tar.$(1).asc --detach-sig \ + ../llmnrd-$(VERSION).tar.$(1) +release: + $(GIT_TAG) + $(call GIT_ARCHIVE,gzip,gz) + $(call GIT_ARCHIVE,bzip2,bz2) + $(call GPG_SIGN,gz) + $(call GPG_SIGN,bz2) + $(Q)echo "Created release $(VERSION)" -- cgit v1.2.3-54-g00ecf