From: Guido Günther Date: Fri, 28 May 2021 09:06:07 +0000 (+0200) Subject: docs: Use either python3 or python X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=e34e595b58d0b6ccfb057dd64e3006a72f14f6a4;p=tools%2Fgit-buildpackage.git docs: Use either python3 or python Some distros (such as Debian) don't ship a /usr/bin/python anymore --- diff --git a/docs/Makefile b/docs/Makefile index 41f172b0..505d74b1 100644 --- a/docs/Makefile +++ b/docs/Makefile @@ -40,6 +40,13 @@ MAN_DATE=$(shell dpkg-parsechangelog -l ../debian/changelog -SDate | TZ=UTC LC_A IMAGES=$(wildcard images/*png) DEST_IMAGES=$(subst images/,$(MANUAL)/images/,$(IMAGES)) +# Select python +ifneq ($(strip $(shell which python3)),) + PYTHON=python3 +else + PYTHON=python +endif + # Select docbook-to-man tool ifeq ($(shell which docbook2x-man), ) DOCBOOK_TO_MAN=docbook-to-man @@ -79,7 +86,7 @@ git-pbuilder.1: ../bin/git-pbuilder manual.xml: $(VERSION_ENT) $(GBP_VERSION): ../debian/changelog - cd .. && python setup.py build --help >/dev/null + cd .. && $(PYTHON) setup.py build --help >/dev/null $(VERSION_ENT): $(GBP_VERSION) echo '' > $(VERSION_ENT)