From 86830d3c84fef2d68fee2def7a276caaa94d72f4 Mon Sep 17 00:00:00 2001 From: Tilman Sauerbeck Date: Sat, 21 Apr 2007 12:31:09 +0200 Subject: [PATCH] Improved "dist" target. --- Makefile | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/Makefile b/Makefile index 958f08d..67c334c 100644 --- a/Makefile +++ b/Makefile @@ -26,6 +26,7 @@ MANDIR = /usr/man ETCDIR = /etc VERSION = 5.30.0 +NAME = pkgutils-$(VERSION) CXXFLAGS += -DNDEBUG CXXFLAGS += -O2 -Wall -pedantic -D_GNU_SOURCE -DVERSION=\"$(VERSION)\" \ @@ -66,12 +67,11 @@ endif .PHONY: install clean distclean dist dist: distclean - rm -rf /tmp/pkgutils-$(VERSION) - mkdir -p /tmp/pkgutils-$(VERSION) - git-log > ChangeLog - cp -rf . /tmp/pkgutils-$(VERSION) - tar -C /tmp --exclude .git -czvf ../pkgutils-$(VERSION).tar.gz pkgutils-$(VERSION) - rm -rf /tmp/pkgutils-$(VERSION) + rm -rf $(NAME) $(NAME).tar.gz + git archive --format=tar --prefix=$(NAME)/ HEAD | tar -x + git log > $(NAME)/ChangeLog + tar czvf $(NAME).tar.gz $(NAME) + rm -rf $(NAME) install: all install -D -m0755 pkgadd $(DESTDIR)$(BINDIR)/pkgadd -- 2.26.2