diff options
author | Tor Andersson <tor.andersson@artifex.com> | 2013-07-26 14:23:37 +0200 |
---|---|---|
committer | Tor Andersson <tor.andersson@artifex.com> | 2013-07-26 14:23:37 +0200 |
commit | d812f7ca3a2d1f87b18d6583dad4abfc9d01b3ae (patch) | |
tree | df191269b22be30f5edca39e3b276648a3e25683 | |
parent | 98f7bb73113424f8a7e5163185962d9a49e0b9f1 (diff) | |
download | mupdf-d812f7ca3a2d1f87b18d6583dad4abfc9d01b3ae.tar.xz |
Add script to create source tarballs using git-archive.
-rw-r--r-- | Makefile | 3 | ||||
-rw-r--r-- | scripts/archive.sh | 19 |
2 files changed, 22 insertions, 0 deletions
@@ -303,6 +303,9 @@ install: libs apps install -d $(DESTDIR)$(docdir) install README COPYING CHANGES docs/*.txt $(DESTDIR)$(docdir) +tarball: + bash scripts/archive.sh + # --- Clean and Default --- tags: $(shell find include source -name '*.[ch]') diff --git a/scripts/archive.sh b/scripts/archive.sh new file mode 100644 index 00000000..0a6e8b3d --- /dev/null +++ b/scripts/archive.sh @@ -0,0 +1,19 @@ +#!/bin/bash + +REV=$(git describe --tags) +O=mupdf-$REV-source + +echo git archive $O.tar +git archive --format=tar --prefix=$O/ HEAD > $O.tar + +git submodule | while read R P T +do + M=$(basename $P) + echo git archive $O.$M.tar + git archive --format=tar --remote=$P --prefix=$O/$P/ HEAD > $O.$M.tar + tar Af $O.tar $O.$M.tar + rm -f $O.$M.tar +done + +echo gzip $O.tar +gzip -f $O.tar |