mirror of
https://git.savannah.gnu.org/git/emacs/org-mode.git
synced 2024-11-24 07:20:29 +00:00
mk/targets.mk: Fix ORGVERSION in tag-less repos
* mk/targets.mk (ORGVERSION, GITVERSION): trim "-dev" suffix from ORGVERSION.
61336f80
uses org.el's Version metadata to generate ORGVERSION when
the source repository has no tags.
This can result in an org-version of "Major.Minor-dev".
The "-dev" suffix is not recognized by `version-to-list' as a valid
version syntax because it is not part of `version-regexp-alist'.
This commit is contained in:
parent
c9dc6603a4
commit
9a4a24a949
@ -15,8 +15,8 @@ ifneq ($(wildcard .git),)
|
||||
ifeq ($(ORGVERSION),)
|
||||
# In elpa.git, there are no tags available. Fall back to using
|
||||
# the org.el header.
|
||||
ORGVERSION := $(shell $(BATCH) --eval "(require 'lisp-mnt)" \
|
||||
--visit lisp/org.el --eval '(princ (lm-header "version"))')
|
||||
ORGVERSION := $(patsubst %-dev,%,$(shell $(BATCH) --eval "(require 'lisp-mnt)" \
|
||||
--visit lisp/org.el --eval '(princ (lm-header "version"))'))
|
||||
GITVERSION ?= $(ORGVERSION)-g$(shell git rev-parse --short=6 HEAD)
|
||||
else
|
||||
GITVERSION ?= $(shell git describe --match release\* --abbrev=6 HEAD)
|
||||
|
Loading…
Reference in New Issue
Block a user