mirror of
https://github.com/checkpoint-restore/criu.git
synced 2026-01-23 02:14:37 +00:00
build: Rework @dist and @tar generation
Currently our @tar target imples that there is a tag in form of "vX.X", if such tag is not present in the repo we're in trouble. So make it sane - if tag present then create tar from this tag - if tag is not present simply use git describe helper Signed-off-by: Cyrill Gorcunov <gorcunov@openvz.org> Signed-off-by: Pavel Emelyanov <xemul@virtuozzo.com>
This commit is contained in:
parent
c1f31142f8
commit
d51539ccd2
1 changed files with 8 additions and 5 deletions
13
Makefile
13
Makefile
|
|
@ -155,11 +155,14 @@ test: zdtm
|
|||
$(Q) $(MAKE) -C test
|
||||
PHONY += test
|
||||
|
||||
dist: tar
|
||||
tar: criu-$(CRTOOLSVERSION).tar.bz2
|
||||
criu-$(CRTOOLSVERSION).tar.bz2:
|
||||
git archive --format tar --prefix 'criu-$(CRTOOLSVERSION)/' \
|
||||
v$(CRTOOLSVERSION) | bzip2 > $@
|
||||
tar-name := $(shell git tag -l v$(CRIU_VERSION))
|
||||
ifeq ($(tar-name),)
|
||||
tar-name := $(shell git describe)
|
||||
endif
|
||||
criu-$(tar-name).tar.bz2:
|
||||
git archive --format tar --prefix 'criu-$(tar-name)/' $(tar-name) | bzip2 > $@
|
||||
dist tar: criu-$(tar-name).tar.bz2
|
||||
@true
|
||||
.PHONY: dist tar
|
||||
|
||||
tags:
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue