Skip to content

Commit 8e2a5cc

Browse files
ChemicalRascalgitster
authored andcommitted
contrib/subtree/Makefile: use GIT-VERSION-FILE
GVF is already being used in most/all other makefiles in the project, and has been for _quite_ a while. Hence, drop file-unique gitver and replace with GIT_VERSION. Reviewed-by: Jeff King <[email protected]> Signed-off-by: James Denholm <[email protected]> Signed-off-by: Junio C Hamano <[email protected]>
1 parent 3330311 commit 8e2a5cc

File tree

1 file changed

+8
-3
lines changed

1 file changed

+8
-3
lines changed

contrib/subtree/Makefile

Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,10 @@ mandir ?= $(prefix)/share/man
66
libexecdir ?= $(prefix)/libexec/git-core
77
man1dir ?= $(mandir)/man1
88

9-
gitver ?= $(word 3,$(shell git --version))
9+
../../GIT-VERSION-FILE: FORCE
10+
$(MAKE) -C ../../ GIT-VERSION-FILE
11+
12+
-include ../../GIT-VERSION-FILE
1013

1114
# this should be set to a 'standard' bsd-type install program
1215
INSTALL ?= install
@@ -44,15 +47,17 @@ $(GIT_SUBTREE_DOC): $(GIT_SUBTREE_XML)
4447

4548
$(GIT_SUBTREE_XML): $(GIT_SUBTREE_TXT)
4649
asciidoc -b docbook -d manpage -f $(ASCIIDOC_CONF) \
47-
-agit_version=$(gitver) $^
50+
-agit_version=$(GIT_VERSION) $^
4851

4952
$(GIT_SUBTREE_HTML): $(GIT_SUBTREE_TXT)
5053
asciidoc -b xhtml11 -d manpage -f $(ASCIIDOC_CONF) \
51-
-agit_version=$(gitver) $^
54+
-agit_version=$(GIT_VERSION) $^
5255

5356
test:
5457
$(MAKE) -C t/ test
5558

5659
clean:
5760
rm -f *~ *.xml *.html *.1
5861
rm -rf subproj mainline
62+
63+
.PHONY: FORCE

0 commit comments

Comments
 (0)