Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commitf201da3

Browse files
committed
Make configure prefer python3 to plain python.
This avoids possibly selecting Python 2.x on systems that haveboth Python 2 and Python 3. We used to feel that what "python"links to is a user choice that we should honor. However, we'reabout to cease support for Python 2, so users will no longer haveany choice of that sort. This small change is being made aheadof the big Python-2-ectomy so that we can see how much of thebuildfarm is not yet prepared for that. Systems with onlyPython 2 will continue to build that way, for now.Discussion:https://postgr.es/m/2872c9a0-4b0a-1354-d5f6-94d6f85ba354@enterprisedb.com
1 parenta7f4171 commitf201da3

File tree

3 files changed

+7
-9
lines changed

3 files changed

+7
-9
lines changed

‎config/python.m4

Lines changed: 5 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -9,14 +9,12 @@
99
# Look for Python and set the output variable 'PYTHON' if found,
1010
# fail otherwise.
1111
#
12-
# As the Python 3 transition happens and PEP 394 isn't updated, we
13-
# need to cater to systems that don't have unversioned "python" by
14-
# default. Some systems ship with "python3" by default and perhaps
15-
# have "python" in an optional package. Some systems only have
16-
# "python2" and "python3", in which case it's reasonable to prefer the
17-
# newer version.
12+
# Since we are transitioning to supporting only Python 3.x,
13+
# prefer python3 to plain python. If the latter exists at all,
14+
# it very possibly points to python2, which we don't want to
15+
# select unless it's the only choice.
1816
AC_DEFUN([PGAC_PATH_PYTHON],
19-
[PGAC_PATH_PROGS(PYTHON,[pythonpython3 python2])
17+
[PGAC_PATH_PROGS(PYTHON,[python3 python python2])
2018
AC_ARG_VAR(PYTHON,[Python program])dnl
2119
if test x"$PYTHON" = x""; then
2220
AC_MSG_ERROR([Python not found])

‎configure

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10279,7 +10279,7 @@ fi
1027910279

1028010280
if test "$with_python" = yes; then
1028110281
if test -z "$PYTHON"; then
10282-
for ac_prog inpythonpython3 python2
10282+
for ac_prog in python3 python python2
1028310283
do
1028410284
# Extract the first word of "$ac_prog", so it can be a program name with args.
1028510285
set dummy $ac_prog; ac_word=$2

‎doc/src/sgml/installation.sgml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1875,7 +1875,7 @@ build-postgresql:
18751875
language becomes available. See
18761876
<xref linkend="plpython-python23"/>
18771877
for more information. If this is not set, the following are probed
1878-
in this order: <literal>pythonpython3 python2</literal>.
1878+
in this order: <literal>python3 python python2</literal>.
18791879
</para>
18801880
</listitem>
18811881
</varlistentry>

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp