about summary refs log tree commit diff
path: root/Makefile
diff options
context:
space:
mode:
authorRich Felker <dalias@aerifal.cx>2014-06-25 16:14:37 -0400
committerRich Felker <dalias@aerifal.cx>2014-06-25 16:14:37 -0400
commitf80710718026d8ad4767ed36651da7b5b5d63530 (patch)
treede750b0a9c1fdf606325948204e2fc6c7de238df /Makefile
parent8facd5638c8fce5eb6b6c11e4bdc34755d03344d (diff)
downloadmusl-f80710718026d8ad4767ed36651da7b5b5d63530.tar.gz
musl-f80710718026d8ad4767ed36651da7b5b5d63530.tar.xz
musl-f80710718026d8ad4767ed36651da7b5b5d63530.zip
add tarball-producing targets to Makefile for ease of release
my old, out-of-tree release script that performed a clone rather than
using git archive checked the VERSION file to make sure that it
matched before doing a release. I believe there should be a way to do
the same with git commands (without resorting to checking out the
desired tag) but I have not yet found a way, so care should be taken
when using these targets that the correctness of the VERSION file is
not overlooked.
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile4
1 files changed, 4 insertions, 0 deletions
diff --git a/Makefile b/Makefile
index d5a64fce..8cc3de81 100644
--- a/Makefile
+++ b/Makefile
@@ -171,7 +171,11 @@ install-headers: $(ALL_INCLUDES:include/%=$(DESTDIR)$(includedir)/%)
 
 install-tools: $(ALL_TOOLS:tools/%=$(DESTDIR)$(bindir)/%)
 
+musl-git-%.tar.gz: .git
+	 git archive --format=tar.gz --prefix=$(patsubst %.tar.gz,%,$@)/ -o $@ $(patsubst musl-git-%.tar.gz,%,$@)
 
+musl-%.tar.gz: .git
+	 git archive --format=tar.gz --prefix=$(patsubst %.tar.gz,%,$@)/ -o $@ v$(patsubst musl-%.tar.gz,%,$@)
 
 .PRECIOUS: $(CRT_LIBS:lib/%=crt/%)