[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[elpa] externals/org eb6cabdee5: mk: Expand shell commands once only
From: |
ELPA Syncer |
Subject: |
[elpa] externals/org eb6cabdee5: mk: Expand shell commands once only |
Date: |
Sun, 30 Apr 2023 06:05:31 -0400 (EDT) |
branch: externals/org
commit eb6cabdee591a18e6885998917ae767043610391
Author: Ihor Radchenko <yantar92@posteo.net>
Commit: Ihor Radchenko <yantar92@posteo.net>
mk: Expand shell commands once only
* mk/targets.mk (GITVERSION):
(GITSTATUS):
(DATE):
(YEAR): Only expand the variables once, not in every make sub-process.
Previous code ran pwd/date/git in every make sub-process, slowing
things down significantly and unnecessarily.
---
mk/targets.mk | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/mk/targets.mk b/mk/targets.mk
index 0bd293d680..06016561cf 100644
--- a/mk/targets.mk
+++ b/mk/targets.mk
@@ -14,15 +14,15 @@ ifneq ($(wildcard .git),)
# Use the org.el header.
ORGVERSION := $(patsubst %-dev,%,$(shell $(BATCH) --eval "(require
'lisp-mnt)" \
--visit lisp/org.el --eval '(princ (lm-header "version"))'))
- GITVERSION ?= $(shell git describe --match release\* --abbrev=6 HEAD
2>/dev/null || echo "release_N/A-N/A-$(shell git describe --match release\*
--abbrev=6 --always HEAD)")
- GITSTATUS ?= $(shell git status -uno --porcelain)
+ GITVERSION := $(shell git describe --match release\* --abbrev=6 HEAD
2>/dev/null || echo "release_N/A-N/A-$(shell git describe --match release\*
--abbrev=6 --always HEAD)")
+ GITSTATUS := $(shell git status -uno --porcelain)
else
-include mk/version.mk
GITVERSION ?= N/A
ORGVERSION ?= N/A
endif
-DATE = $(shell date +%Y-%m-%d)
-YEAR = $(shell date +%Y)
+DATE := $(shell date +%Y-%m-%d)
+YEAR := $(shell date +%Y)
ifneq ($(GITSTATUS),)
GITVERSION := $(GITVERSION:.dirty=).dirty
endif
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [elpa] externals/org eb6cabdee5: mk: Expand shell commands once only,
ELPA Syncer <=