From 841e8775eb867da863cf04a6ed3354ceb7c1c1a6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jean-S=C3=A9bastien=20P=C3=A9dron?= Date: Thu, 19 Jan 2017 13:34:21 +0100 Subject: [PATCH] packaging/windows: Allow to override `PRODUCTVERSION` This will allow to keep a semver-formatted version everywhere and have a valid `PRODUCTVERSION` made of for integers. [#131645343] --- packaging/windows-exe/Makefile | 2 ++ packaging/windows-exe/rabbitmq_nsi.in | 2 +- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/packaging/windows-exe/Makefile b/packaging/windows-exe/Makefile index 47bc489bb8..10f2c34915 100644 --- a/packaging/windows-exe/Makefile +++ b/packaging/windows-exe/Makefile @@ -6,6 +6,7 @@ endif ZIP = $(notdir $(wildcard $(ZIP_DIR)/rabbitmq-server-windows-*.zip)) VERSION = $(patsubst rabbitmq-server-windows-%.zip,%,$(ZIP)) +PRODUCT_VERSION ?= $(VERSION).0 unexport DEPS_DIR unexport ERL_LIBS @@ -25,6 +26,7 @@ dist: rabbitmq-$(VERSION).nsi rabbitmq_server-$(VERSION) rabbitmq-$(VERSION).nsi: rabbitmq_nsi.in sed \ -e 's|%%VERSION%%|$(VERSION)|' \ + -e 's|%%PRODUCT_VERSION%%|$(PRODUCT_VERSION)|' \ $< > $@ rabbitmq_server-$(VERSION): diff --git a/packaging/windows-exe/rabbitmq_nsi.in b/packaging/windows-exe/rabbitmq_nsi.in index 4c47e86628..4e633fee4c 100644 --- a/packaging/windows-exe/rabbitmq_nsi.in +++ b/packaging/windows-exe/rabbitmq_nsi.in @@ -61,7 +61,7 @@ SetCompressor /solid lzma ;-------------------------------- -VIProductVersion "%%VERSION%%.0" +VIProductVersion "%%PRODUCT_VERSION%%" VIAddVersionKey /LANG=${LANG_ENGLISH} "ProductVersion" "%%VERSION%%" VIAddVersionKey /LANG=${LANG_ENGLISH} "ProductName" "RabbitMQ Server" ;VIAddVersionKey /LANG=${LANG_ENGLISH} "Comments" ""