build: add support for packing version control downloads with xz
authorFelix Fietkau <nbd@openwrt.org>
Thu, 10 Apr 2014 14:43:26 +0000 (14:43 +0000)
committerFelix Fietkau <nbd@openwrt.org>
Thu, 10 Apr 2014 14:43:26 +0000 (14:43 +0000)
Signed-off-by: Felix Fietkau <nbd@openwrt.org>
SVN-Revision: 40446

include/download.mk

index 1c3f23e94ba552aa2297ac3c1f5165152c98bf3c..cc4ffb0cfb544131704d7d0ffca3f11c0d8ef33b 100644 (file)
@@ -31,6 +31,7 @@ endef
 # code for creating tarballs from cvs/svn/git/bzr/hg/darcs checkouts - useful for mirror support
 dl_pack/bz2=$(TAR) cjf $(1) $(2)
 dl_pack/gz=$(TAR) czf $(1) $(2)
+dl_pack/xz=$(TAR) c $(2) | xz -zc > $(1)
 dl_pack/unknown=echo "ERROR: Unknown pack format for file $(1)"; false
 define dl_pack
        $(if $(dl_pack/$(call ext,$(1))),$(dl_pack/$(call ext,$(1))),$(dl_pack/unknown))