From 24651c482af1964b42e921d23f260c4266f1fe61 Mon Sep 17 00:00:00 2001 From: Jim Meyering Date: Wed, 3 Jul 2024 23:07:16 +0200 Subject: [PATCH] maintainer-makefile: derive VERSION from RELEASE only from command line * top/maint.mk (VERSION, RELEASE_TYPE): Do not let an environment- specified RELEASE influence the VERSION and RELEASE_TYPE variables. Reported by Simon Josefsson in https://lists.gnu.org/archive/html/bug-gnulib/2024-07/msg00021.html --- ChangeLog | 8 ++++++++ top/maint.mk | 6 ++++-- 2 files changed, 12 insertions(+), 2 deletions(-) diff --git a/ChangeLog b/ChangeLog index fcef360b22..a886e25cc2 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,11 @@ +2024-07-03 Jim Meyering + + maintainer-makefile: derive VERSION from RELEASE only from command line + * top/maint.mk (VERSION, RELEASE_TYPE): Do not let an environment- + specified RELEASE influence the VERSION and RELEASE_TYPE variables. + Reported by Simon Josefsson in + https://lists.gnu.org/archive/html/bug-gnulib/2024-07/msg00021.html + 2024-07-02 Bruno Haible git-merge-changelog: Simplify installation instructions. diff --git a/top/maint.mk b/top/maint.mk index 2f35253fb7..de2aff8b9b 100644 --- a/top/maint.mk +++ b/top/maint.mk @@ -124,8 +124,10 @@ release_archive_dir ?= ../release # If RELEASE_TYPE is undefined, but RELEASE is, use its second word. # But overwrite VERSION. ifdef RELEASE - VERSION := $(word 1, $(RELEASE)) - RELEASE_TYPE ?= $(word 2, $(RELEASE)) + ifeq ($(origin RELEASE),command line) + VERSION := $(word 1,$(RELEASE)) + RELEASE_TYPE ?= $(word 2,$(RELEASE)) + endif endif # Validate and return $(RELEASE_TYPE), or die. -- 2.39.5