2
0
mirror of https://github.com/vasi/pixz synced 2024-10-30 15:21:41 +00:00

Add "make tarball"

This commit is contained in:
Dave Vasilevsky 2012-12-22 18:25:45 -05:00
parent 745b624361
commit 0f2fe4f601
3 changed files with 17 additions and 4 deletions

1
.gitattributes vendored
View File

@ -1 +1,2 @@
.gitignore export-ignore .gitignore export-ignore
.gitattributes export-ignore

2
.gitignore vendored
View File

@ -1,5 +1,7 @@
pixz pixz
pixz.1 pixz.1
dist
pixz-*.tgz
*.o *.o

View File

@ -1,4 +1,6 @@
VERSION = 1.0 VERSION = 1.0
DISTNAME = pixz-$(VERSION)
TARBALL = $(DISTNAME).tgz
ifneq ($(shell gcc -v 2>&1 | grep 'Apple Inc'),) ifneq ($(shell gcc -v 2>&1 | grep 'Apple Inc'),)
APPLE=1 APPLE=1
@ -35,12 +37,20 @@ $(PROGS): %: %.o $(COMMON)
$(LD) $@ $^ $(LIBADD) $(LD) $@ $^ $(LIBADD)
clean: clean:
rm -f *.o $(PROGS) $(MANPAGE) rm -rf *.o $(PROGS) $(MANPAGE) dist
$(MANPAGE): pixz.1.asciidoc $(MANPAGE): pixz.1.asciidoc
a2x -a manversion=$(VERSION) -f manpage $< a2x -a manversion=$(VERSION) -f manpage $<
dist: $(MANPAGE) dist:
rm -rf dist
mkdir -p dist
git archive --prefix=$(DISTNAME)/ --format=tar HEAD | tar -x -C dist
.PHONY: all clean dist $(TARBALL): $(MANPAGE) dist
cp pixz.1 dist/$(DISTNAME)/
tar -cf $(TARBALL) -C dist $(DISTNAME)
tarball: $(TARBALL)
.PHONY: all clean tarball dist