summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorPatrick McHardy <kaber@trash.net>2010-07-06 05:57:18 +0200
committerPatrick McHardy <kaber@trash.net>2010-07-06 05:57:18 +0200
commit969482e3144911c71a9cb73019e086cc8adec991 (patch)
treec2a012c91f5452548780811da10b7da23d839862
parent882a58ec5c8405470cf7550218682b3144dd7cb8 (diff)
build: add 'archive' target
make archive creates a tar.bz2 from the HEAD version. Signed-off-by: Patrick McHardy <kaber@trash.net>
-rw-r--r--Makefile.rules.in4
1 files changed, 4 insertions, 0 deletions
diff --git a/Makefile.rules.in b/Makefile.rules.in
index 67c4ff6d..3abd48c8 100644
--- a/Makefile.rules.in
+++ b/Makefile.rules.in
@@ -36,6 +36,10 @@ configure: configure.ac
@echo -e " PDF\t\t$@"
db2pdf -o $(SUBDIR) $<
+archive:
+ git archive --prefix=nftables-@PACKAGE_VERSION@/ HEAD | \
+ bzip2 -c > nftables-@PACKAGE_VERSION@.tar.bz2
+
define program_template
$(1)-obj := $$(patsubst %,$(SUBDIR)%,$$($(1)-obj))
$(1)-extra-clean-files := $$(patsubst %,$(SUBDIR)%,$$($(1)-extra-clean-files))