From 3ad99311e355ac9c684aabda7dd0571c1be2d95e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Petr=20=C5=A0tetiar?= Date: Sun, 1 Oct 2023 06:00:32 +0000 Subject: [PATCH] version.mk: introduce prplOS Git based versioning MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Henceforth, we will utilize the prplOS version throughout the development cycle, determined by the output of the `git describe` command. The version will be composed of: - The fixed version number of the upcoming release currently in development. - The abbreviated (8 characters) object hash of the most recent commit. For instance, with the ongoing development of prplOS version 3.0.0 and having the Git hash `5a2a69d`, the resulting version would be `3.0.0-5a2a69d`. References: PCF-691 Signed-off-by: Petr Štetiar (cherry picked from commit d2499f3e10aa6a8982122c0def4dc7997bbc1753) --- include/version.mk | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/include/version.mk b/include/version.mk index a6ebe58779..a2c07851f3 100644 --- a/include/version.mk +++ b/include/version.mk @@ -22,8 +22,10 @@ PKG_CONFIG_DEPENDS += \ sanitize = $(call tolower,$(subst _,-,$(subst $(space),-,$(1)))) +VERSION_PRPLOS:=$(if $(VERSION_PRPLOS),$(VERSION_PRPLOS),$(shell $(TOPDIR)/scripts/prplos_version.sh)) + VERSION_NUMBER:=$(call qstrip,$(CONFIG_VERSION_NUMBER)) -VERSION_NUMBER:=$(if $(VERSION_NUMBER),$(VERSION_NUMBER),24.10-SNAPSHOT) +VERSION_NUMBER:=$(if $(VERSION_NUMBER),$(VERSION_NUMBER),$(VERSION_PRPLOS)) VERSION_CODE:=$(call qstrip,$(CONFIG_VERSION_CODE)) VERSION_CODE:=$(if $(VERSION_CODE),$(VERSION_CODE),$(REVISION))