X-Git-Url: http://git.openwrt.org/?a=blobdiff_plain;f=rules.mk;h=8f41ff5861a046bcad893b9a11874f96e3f43e3e;hb=HEAD;hp=cf4aa30d213f09e586a937147fec6c403481b1fe;hpb=9ae3c6f94c616cfbf854d3ec749c7fafc9893942;p=openwrt%2Fstaging%2Frmilecki.git diff --git a/rules.mk b/rules.mk index cf4aa30d213..8f41ff5861a 100644 --- a/rules.mk +++ b/rules.mk @@ -1,10 +1,7 @@ +# SPDX-License-Identifier: GPL-2.0-only # # Copyright (C) 2006-2010 OpenWrt.org # Copyright (C) 2016 LEDE Project -# -# This is free software, licensed under the GNU General Public License v2. -# See /LICENSE for more information. -# ifneq ($(__rules_inc),1) __rules_inc=1 @@ -421,7 +418,7 @@ $(shell \ if [ -n "$$last_bump" ]; then \ echo -n $$(($$(git rev-list --count "$$last_bump..HEAD" .) + 1)); \ else \ - echo -n $$(($$(git rev-list --count HEAD .) + 1)); \ + git rev-list --count HEAD .; \ fi; \ else \ secs="$$(($(SOURCE_DATE_EPOCH) % 86400))"; \ @@ -431,8 +428,10 @@ $(shell \ ) endef -COMMITCOUNT = $(if $(DUMP),,$(call commitcount)) -AUTORELEASE = $(if $(DUMP),,$(call commitcount,1)) +abi_version_str = $(subst -,,$(subst _,,$(subst .,,$(1)))) + +COMMITCOUNT = $(if $(DUMP),0,$(call commitcount)) +AUTORELEASE = $(if $(DUMP),0,$(call commitcount,1)) all: FORCE: ;