Move to xz dist tarballs

For consistency with the already xz'ed node tarball.

Rename the oddly named `dist-gzip` target to the standard `dist`.

Cherry-picked from starter-kit commit 4ca75f143c
This commit is contained in:
Katerina Koukiou 2021-11-08 12:30:33 +01:00 committed by Justin Stephenson
parent 47c1eb0804
commit 3ebdcfa4fe
3 changed files with 6 additions and 6 deletions

View file

@ -5,7 +5,7 @@ ifeq ($(TEST_OS),)
TEST_OS = rhel-x
endif
export TEST_OS
TARFILE=cockpit-$(PACKAGE_NAME)-$(VERSION).tar.gz
TARFILE=cockpit-$(PACKAGE_NAME)-$(VERSION).tar.xz
RPMFILE=$(shell rpmspec -D"VERSION $(VERSION)" -q cockpit-session-recording.spec.in).rpm
VM_IMAGE=$(CURDIR)/test/images/$(TEST_OS)
# stamp file to check if/when npm install ran
@ -88,7 +88,7 @@ devel-install: $(WEBPACK_TEST)
mkdir -p ~/.local/share/cockpit
ln -s `pwd`/dist ~/.local/share/cockpit/$(PACKAGE_NAME)
dist-gzip: $(TARFILE)
dist: $(TARFILE)
# when building a distribution tarball, call webpack with a 'production' environment
# we don't ship node_modules for license and compactness reasons; we ship a
@ -100,7 +100,7 @@ $(TARFILE): $(WEBPACK_TEST) cockpit-$(PACKAGE_NAME).spec
mv node_modules node_modules.release
touch -r package.json $(NODE_MODULES_TEST)
touch dist/*
tar czf cockpit-$(PACKAGE_NAME)-$(VERSION).tar.gz --transform 's,^,cockpit-$(PACKAGE_NAME)/,' \
tar --xz -cf cockpit-$(PACKAGE_NAME)-$(VERSION).tar.xz --transform 's,^,cockpit-$(PACKAGE_NAME)/,' \
--exclude cockpit-$(PACKAGE_NAME).spec.in \
$$(git ls-files) package-lock.json cockpit-$(PACKAGE_NAME).spec dist/
mv node_modules.release node_modules
@ -175,4 +175,4 @@ $(NODE_MODULES_TEST): package.json
env -u NODE_ENV npm install
env -u NODE_ENV npm prune
.PHONY: all clean install devel-install dist-gzip srpm rpm check vm update-po
.PHONY: all clean install devel-install dist srpm rpm check vm update-po