Updated app tarball version

Currently, the debian build system produces a debian package version
with the format: "1.0-1.stx.<revision>"

The rules file then parses this deb pkg version at build time
to produce the app tarball version, which always comes up to
be "1.0-1" at this time [1]. This commit changes the app tarball
version calculation so that the resulting tarball version will
be "1.0-<revision>" [2].

This correction is necessary because the application framework
cannot update an app between instances with the same version.

This commit is part of a set of commits updating the app tarball
version calculation to all apps based off of [3].

[1]: /usr/local/share/applications/helm/<APPNAME>-1.0-1.tgz
[2]: /usr/local/share/applications/helm/<APPNAME>-1.0-<N>.tgz

[3]: https://review.opendev.org/c/starlingx/cert-manager-armada-app/+/872628

Test Plan:
pass - build-pkg
pass - tarball version updated

Story: 2010542
Task: 47523

Signed-off-by: Leonardo Fagundes Luz Serrano <Leonardo.FagundesLuzSerrano@windriver.com>
Change-Id: Ib24b17676953e4485e220ce6dcdf168d3e5ecdba
This commit is contained in:
Leonardo Fagundes Luz Serrano 2023-02-25 01:38:28 -03:00
parent dcd76cd624
commit 90cd1a27a8

View File

@ -5,11 +5,11 @@ export ROOT = debian/tmp
export APP_FOLDER = $(ROOT)/usr/local/share/applications/helm
export DEB_VERSION = $(shell dpkg-parsechangelog | egrep '^Version:' | cut -f 2 -d ' ')
export MAJOR = $(shell echo $(DEB_VERSION) | cut -f 1 -d '.')
export MINOR_PATCH = $(shell echo $(DEB_VERSION) | cut -f 2 -d '.')
export RELEASE = $(shell echo $(DEB_VERSION) | cut -f 1 -d '-')
export REVISION = $(shell echo $(DEB_VERSION) | cut -f 4 -d '.')
export APP_NAME = sriov-fec-operator
export APP_VERSION = $(MAJOR).$(MINOR_PATCH)
export APP_VERSION = $(RELEASE)-$(REVISION)
export APP_TARBALL = $(APP_NAME)-$(APP_VERSION).tgz
export HELM_REPO = stx-platform
export STAGING = staging