Run the specified perl in Documentation/
Makefile uses $(PERL_PATH) but Documentation/Makefile uses "perl"; that means the two Makefiles can use two different Perl installations. Teach Documentation/Makefile to use PERL_PATH that is exported from the toplevel Makefile, and give a sane fallback for people who run "make" from Documentation directory. Signed-off-by: Junio C Hamano <gitster@pobox.com>
Junio C Hamano committed
Nov 30, 2007 at 18:36 UTC
c680dd8341c2aa429acfc13223220d72b8d2c5c9
1 file changed
+6
-3
Documentation/Makefile
+6
-3
@@ -45,6 +45,9 @@ infodir?=$(prefix)/share/info
45
MAKEINFO=makeinfo
46
INSTALL_INFO=install-info
47
DOCBOOK2X_TEXI=docbook2x-texi
48
+ifndef PERL_PATH
49
+ PERL_PATH = /usr/bin/perl
50
+endif
51
52
-include ../config.mak.autogen
53
-include ../config.mak
@@ -105,7 +108,7 @@ install-info: info
108
#
109
doc.dep : $(wildcard *.txt) build-docdep.perl
110
$(RM) $@+ $@
108
- perl ./build-docdep.perl >$@+
111
+ $(PERL_PATH) ./build-docdep.perl >$@+
112
mv $@+ $@
113
114
-include doc.dep
@@ -124,7 +127,7 @@ $(cmds_txt): cmd-list.made
127
128
cmd-list.made: cmd-list.perl ../command-list.txt $(MAN1_TXT)
129
$(RM) $@
127
- perl ./cmd-list.perl ../command-list.txt
130
+ $(PERL_PATH) ./cmd-list.perl ../command-list.txt
131
date >$@
132
133
git.7 git.html: git.txt
@@ -161,7 +164,7 @@ user-manual.html: user-manual.xml
164
git.info: user-manual.xml
165
$(RM) $@ $*.texi $*.texi+
166
$(DOCBOOK2X_TEXI) user-manual.xml --to-stdout >$*.texi+
164
- perl fix-texi.perl <$*.texi+ >$*.texi
167
+ $(PERL_PATH) fix-texi.perl <$*.texi+ >$*.texi
168
$(MAKEINFO) --no-split $*.texi
169
$(RM) $*.texi $*.texi+
170