D10251: makefile: use Python 3 by default when building docs as well

classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

D10251: makefile: use Python 3 by default when building docs as well

marmoute (Pierre-Yves David)
martinvonz created this revision.
Herald added a reviewer: hg-reviewers.
Herald added a subscriber: mercurial-patches.

REVISION SUMMARY
  I copied the snippet defining `PYTHON` from the root Makefile.

REPOSITORY
  rHG Mercurial

BRANCH
  default

REVISION DETAIL
  https://phab.mercurial-scm.org/D10251

AFFECTED FILES
  doc/Makefile

CHANGE DETAILS

diff --git a/doc/Makefile b/doc/Makefile
--- a/doc/Makefile
+++ b/doc/Makefile
@@ -6,7 +6,14 @@
 PREFIX=/usr/local
 MANDIR=$(PREFIX)/share/man
 INSTALL=install -m 644
-PYTHON?=python
+# Default to Python 3.
+#
+# Windows ships Python 3 as `python.exe`, which may not be on PATH.  py.exe is.
+ifeq ($(OS),Windows_NT)
+PYTHON?=py -3
+else
+PYTHON?=python3
+endif
 RSTARGS=
 
 export HGENCODING=UTF-8



To: martinvonz, #hg-reviewers
Cc: mercurial-patches, mercurial-devel
_______________________________________________
Mercurial-devel mailing list
[hidden email]
https://www.mercurial-scm.org/mailman/listinfo/mercurial-devel