Skip to content

Commit

Permalink
Merge pull request #600 from davidvossel/master
Browse files Browse the repository at this point in the history
Low: build: Add ability to set custom spec version for 'make rpm'
  • Loading branch information
beekhof committed Oct 21, 2014
2 parents 347ee3b + 1b855f9 commit ff52d84
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion GNUmakefile
Expand Up @@ -58,6 +58,8 @@ BUILD_COUNTER ?= build.counter
LAST_COUNT = $(shell test ! -e $(BUILD_COUNTER) && echo 0; test -e $(BUILD_COUNTER) && cat $(BUILD_COUNTER))
COUNT = $(shell expr 1 + $(LAST_COUNT))

SPECVERSION ?= $(COUNT)

init:
./autogen.sh

Expand Down Expand Up @@ -144,7 +146,7 @@ srpm-%: export $(PACKAGE)-%.spec
if [ -e $(BUILD_COUNTER) ]; then \
echo $(COUNT) > $(BUILD_COUNTER); \
fi
sed -i 's/global\ specversion.*/global\ specversion\ $(COUNT)/' $(PACKAGE).spec
sed -i 's/global\ specversion.*/global\ specversion\ $(SPECVERSION)/' $(PACKAGE).spec
sed -i 's/global\ commit.*/global\ commit\ $(TAG)/' $(PACKAGE).spec
case "$(WITH)" in \
*pre_release*) \
Expand Down

0 comments on commit ff52d84

Please sign in to comment.