The top level Makefile allows the user to specify their Python using the PYTHON variable; however the sub-Makefiles weren't honouring this, which meant that if you didn't have a 'python2' executable then the make 'all' and 'install' targets would work but 'doc' and 'install-doc' would not.
Add explicit uses of $(PYTHON) everywhere we run a python script from the Makefiles, bringing the sub-makefiles in line with the top level one. Signed-off-by: Peter Maydell <[email protected]> --- This bit me on a MacOSX system, where Python is just "python" and there is no "python2". The install process automatically substitutes in the correct interpreter path for scripts it installs, so we only need to worry about scripts run as part of the build/install process. Documentation/Makefile | 6 +++--- t/Makefile | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/Documentation/Makefile b/Documentation/Makefile index dd029d5..5deb033 100644 --- a/Documentation/Makefile +++ b/Documentation/Makefile @@ -1,4 +1,4 @@ -COMMANDS = $(shell ../stg-build --commands) +COMMANDS = $(shell $(PYTHON) ../stg-build --commands) COMMANDS_TXT = $(patsubst %,stg-%.txt,$(COMMANDS)) MAN1_TXT= stg.txt $(COMMANDS_TXT) @@ -63,10 +63,10 @@ clean: ALL_PY = $(shell find ../stgit -name '*.py') $(COMMANDS_TXT): $(ALL_PY) - ../stg-build --asciidoc $(basename $(subst stg-,,$@)) > $@ + $(PYTHON) ../stg-build --asciidoc $(basename $(subst stg-,,$@)) > $@ command-list.txt: $(ALL_PY) - ../stg-build --cmd-list > $@ + $(PYTHON) ../stg-build --cmd-list > $@ %.html : %.txt $(ASCIIDOC) -b xhtml11 -d manpage -f asciidoc.conf $(ASCIIDOC_EXTRA) $< diff --git a/t/Makefile b/t/Makefile index 3e34232..e781131 100644 --- a/t/Makefile +++ b/t/Makefile @@ -7,7 +7,7 @@ SHELL_PATH ?= $(SHELL) TAR ?= $(TAR) all: - python test.py + $(PYTHON) test.py clean: rm -rf trash* -- 2.0.0 _______________________________________________ stgit-users mailing list [email protected] https://mail.gna.org/listinfo/stgit-users
