From: Alejandro Colomar Date: Sat, 30 Jul 2022 18:31:40 +0000 (+0200) Subject: dist.mk: Create tarballs with a top-level directory X-Git-Tag: man-pages-6.0-rc1~74 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=e67acee2089dd957d629b0e6faaa796e356b05dd;p=thirdparty%2Fman-pages.git dist.mk: Create tarballs with a top-level directory Need to use a trick with sed(1) to avoid tar(1) modifying the symlinks. Signed-off-by: Alejandro Colomar --- diff --git a/lib/dist.mk b/lib/dist.mk index 7798d59a19..570c81f2c8 100644 --- a/lib/dist.mk +++ b/lib/dist.mk @@ -21,7 +21,8 @@ $(DISTFILE): $(shell git ls-files 2>/dev/null) | $$(@D)/. $(info TAR $@) tar cf $@ -T /dev/null git ls-files \ - | xargs tar rf $@ + | sed 's,^,./,' \ + | xargs tar rf $@ -C $(srcdir) --transform 's,^\.,$(DISTNAME),' $(DISTFILE).gz: %.gz: % | $$(@D)/. $(info GZIP $@)