Script 'mail_helper' called by obssrc
Hello community,

here is the log from the commit of package python38 for openSUSE:Factory 
checked in at 2021-05-02 18:35:21
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/python38 (Old)
 and      /work/SRC/openSUSE:Factory/.python38.new.1947 (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "python38"

Sun May  2 18:35:21 2021 rev:12 rq:889131 version:3.8.9

Changes:
--------
--- /work/SRC/openSUSE:Factory/python38/python38.changes        2021-03-18 
22:55:04.951540039 +0100
+++ /work/SRC/openSUSE:Factory/.python38.new.1947/python38.changes      
2021-05-02 18:35:39.429065130 +0200
@@ -1,0 +2,86 @@
+Wed Apr 28 17:32:55 UTC 2021 - Matej Cepl <mc...@suse.com>
+
+- Update to 3.8.9:
+  - bpo#42988 (bsc#1183374) CVE-2021-3426: Remove the getfile
+    feature of the pydoc module which could be abused to read
+    arbitrary files on the disk (directory traversal
+    vulnerability). Moreover, even source code of Python modules
+    can contain sensitive data like passwords. Vulnerability
+    reported by David Schw??rer.
+  - bpo-43285: ftplib no longer trusts the IP address value
+    returned from the server in response to the PASV command by
+    default. This prevents a malicious FTP server from using the
+    response to probe IPv4 address and port combinations on the
+    client network.
+  - Code that requires the former vulnerable behavior may set
+    a trust_server_pasv_ipv4_address attribute on their
+    ftplib.FTP instances to True to re-enable it.
+  - bpo-43439: Add audit hooks for gc.get_objects(),
+    gc.get_referrers() and gc.get_referents(). Patch by Pablo
+    Galindo.
+  - bpo-43660: Fix crash that happens when replacing sys.stderr
+    with a callable that can remove the object while an exception
+    is being printed. Patch by Pablo Galindo.
+  - bpo-35883: Python no longer fails at startup with a fatal
+    error if a command line argument contains an invalid Unicode
+    character. The Py_DecodeLocale() function now escapes byte
+    sequences which would be decoded as Unicode characters
+    outside the [U+0000; U+10ffff] range.
+  - bpo-43406: Fix a possible race condition where
+    PyErr_CheckSignals tries to execute a non-Python signal
+    handler.
+  - bpo-35930: Raising an exception raised in a ???future??? instance
+    will create reference cycles.
+  - bpo-43577: Fix deadlock when using ssl.SSLContext debug
+    callback with ssl.SSLContext.sni_callback().
+  - bpo-43423: subprocess.communicate() no longer raises an
+    IndexError when there is an empty stdout or stderr IO buffer
+    during a timeout on Windows.
+  - bpo-27820: Fixed long-standing bug of smtplib.SMTP where
+    doing AUTH LOGIN with initial_response_ok=False will fail.
+    The cause is that SMTP.auth_login _always_ returns a password
+    if provided with a challenge string, thus non-compliant with
+    the standard for AUTH LOGIN. Also fixes bug with the test for
+    smtpd.
+  - bpo-43399: Fix ElementTree.extend not working on iterators
+    when using the Python implementation
+  - bpo-43316: The python -m gzip command line application now
+    properly fails when detecting an unsupported extension. It
+    exits with a non-zero exit code and prints an error message
+    to stderr.
+  - bpo-43260: Fix TextIOWrapper can not flush internal buffer
+    forever after very large text is written.
+  - bpo-42782: Fail fast in shutil.move() to avoid creating
+    destination directories on failure.
+  - bpo-37193: Fixed memory leak in socketserver.ThreadingMixIn
+    introduced in Python 3.7.
+  - bpo-43199: Answer ???Why is there no goto???? in the Design and
+    History FAQ.
+  - bpo-43407: Clarified that a result from time.monotonic(),
+    time.perf_counter(), time.process_time(), or
+    time.thread_time() can be compared with the result from any
+    following call to the same function - not just the next
+    immediate call.
+  - bpo-27646: Clarify that ???yield from <expr>??? works with any
+    iterable, not just iterators.
+  - bpo-36346: Update some deprecated unicode APIs which are
+    documented as ???will be removed in 4.0??? to ???3.12???. See PEP 623
+    for detail.
+  - bpo-37945: Fix test_getsetlocale_issue1813() of test_locale:
+    skip the test if setlocale() fails. Patch by Victor Stinner.
+  - bpo-41561: Add workaround for Ubuntu???s custom OpenSSL
+    security level policy.
+  - bpo-43631: Update macOS, Windows, and CI to OpenSSL 1.1.1k.
+  - bpo-43617: Improve configure.ac: Check for presence of
+    autoconf-archive package and remove our copies of M4 macros.
+  - bpo-41837: Update macOS installer build to use OpenSSL
+    1.1.1j.
+  - bpo-42225: Document that IDLE can fail on Unix either from
+    misconfigured IP masquerage rules or failure displaying
+    complex colored (non-ascii) characters.
+  - bpo-43283: Document why printing to IDLE???s Shell is often
+    slower than printing to a system terminal and that it can be
+    made faster by pre-formatting a single string before
+    printing.
+
+-------------------------------------------------------------------

Old:
----
  Python-3.8.8.tar.xz
  Python-3.8.8.tar.xz.asc

New:
----
  Python-3.8.9.tar.xz
  Python-3.8.9.tar.xz.asc

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Other differences:
------------------
++++++ python38.spec ++++++
--- /var/tmp/diff_new_pack.bJtjS4/_old  2021-05-02 18:35:40.181061926 +0200
+++ /var/tmp/diff_new_pack.bJtjS4/_new  2021-05-02 18:35:40.181061926 +0200
@@ -87,7 +87,7 @@
 %bcond_without profileopt
 %endif
 Name:           %{python_pkg_name}%{psuffix}
-Version:        3.8.8
+Version:        3.8.9
 Release:        0
 Summary:        Python 3 Interpreter
 License:        Python-2.0
@@ -151,6 +151,7 @@
 Patch29:        bpo-31046_ensurepip_honours_prefix.patch
 # PATCH-FIX-UPSTREAM stop calling removed Sphinx function 
gh#python/cpython#13236
 Patch32:        sphinx-update-removed-function.patch
+BuildRequires:  autoconf-archive
 BuildRequires:  automake
 BuildRequires:  fdupes
 BuildRequires:  gmp-devel

++++++ F00102-lib64.patch ++++++
--- /var/tmp/diff_new_pack.bJtjS4/_old  2021-05-02 18:35:40.229061721 +0200
+++ /var/tmp/diff_new_pack.bJtjS4/_new  2021-05-02 18:35:40.229061721 +0200
@@ -19,17 +19,17 @@
 Co-authored-by: Miro Hron??ok <m...@hroncok.cz>
 Co-authored-by: Iryna Shcherbina <shcherbina.ir...@gmail.com>
 ---
- Lib/distutils/command/install.py    |  4 ++--
- Lib/distutils/sysconfig.py          |  6 +++++-
- Lib/distutils/tests/test_install.py |  3 ++-
- Lib/site.py                         |  4 ++++
- Lib/sysconfig.py                    | 12 ++++++------
- Lib/test/test_site.py               |  4 ++--
- Makefile.pre.in                     |  2 +-
- Modules/getpath.c                   |  6 +++---
- configure                           |  4 ++--
- configure.ac                        |  4 ++--
- setup.py                            |  6 +++---
+ Lib/distutils/command/install.py    |    4 ++--
+ Lib/distutils/sysconfig.py          |    6 +++++-
+ Lib/distutils/tests/test_install.py |    3 ++-
+ Lib/site.py                         |    4 ++++
+ Lib/sysconfig.py                    |   12 ++++++------
+ Lib/test/test_site.py               |    4 ++--
+ Makefile.pre.in                     |    2 +-
+ Modules/getpath.c                   |    6 +++---
+ configure                           |    4 ++--
+ configure.ac                        |    4 ++--
+ setup.py                            |    6 +++---
  11 files changed, 32 insertions(+), 23 deletions(-)
 
 --- a/Lib/distutils/command/install.py
@@ -183,7 +183,7 @@
      }
 --- a/configure
 +++ b/configure
-@@ -15233,9 +15233,9 @@ fi
+@@ -15222,9 +15222,9 @@ fi
  
  
  if test x$PLATFORM_TRIPLET = x; then
@@ -197,7 +197,7 @@
  
 --- a/configure.ac
 +++ b/configure.ac
-@@ -4691,9 +4691,9 @@ fi
+@@ -4698,9 +4698,9 @@ fi
  dnl define LIBPL after ABIFLAGS and LDVERSION is defined.
  AC_SUBST(PY_ENABLE_SHARED)
  if test x$PLATFORM_TRIPLET = x; then

++++++ Python-3.8.8.tar.xz -> Python-3.8.9.tar.xz ++++++
/work/SRC/openSUSE:Factory/python38/Python-3.8.8.tar.xz 
/work/SRC/openSUSE:Factory/.python38.new.1947/Python-3.8.9.tar.xz differ: char 
27, line 1

++++++ SUSE-FEDORA-multilib.patch ++++++
--- /var/tmp/diff_new_pack.bJtjS4/_old  2021-05-02 18:35:40.345061227 +0200
+++ /var/tmp/diff_new_pack.bJtjS4/_new  2021-05-02 18:35:40.345061227 +0200
@@ -1,130 +1,18 @@
---- a/configure.ac
-+++ b/configure.ac
-@@ -4688,12 +4688,26 @@ else
-   LIBPYTHON=''
- fi
- 
-+# platsubdir must be defined before LIBPL definition
-+AC_MSG_CHECKING(for custom platsubdir)
-+AC_ARG_WITH(custom-platsubdir,
-+    [AS_HELP_STRING([--with-custom-platsubdir=<libdirname>],
-+        [set the platsubdir name to a custom string])],
-+    [],
-+    [with_custom_platsubdir=yes])
-+AS_CASE($with_custom_platsubdir,
-+    [yes],[platsubdir=`basename ${libdir}`],
-+    [no],[platsubdir=lib],
-+    [platsubdir=$with_custom_platsubdir])
-+AC_MSG_RESULT($platsubdir)
-+AC_SUBST(platsubdir)
-+
- dnl define LIBPL after ABIFLAGS and LDVERSION is defined.
- AC_SUBST(PY_ENABLE_SHARED)
- if test x$PLATFORM_TRIPLET = x; then
--  LIBPL='$(prefix)'"/lib64/python${VERSION}/config-${LDVERSION}"
-+  LIBPL='$(prefix)'"/${platsubdir}/python${VERSION}/config-${LDVERSION}"
- else
--  
LIBPL='$(prefix)'"/lib64/python${VERSION}/config-${LDVERSION}-${PLATFORM_TRIPLET}"
-+  
LIBPL='$(prefix)'"/${platsubdir}/python${VERSION}/config-${LDVERSION}-${PLATFORM_TRIPLET}"
- fi
- AC_SUBST(LIBPL)
- 
---- a/Makefile.pre.in
-+++ b/Makefile.pre.in
-@@ -137,13 +137,16 @@ exec_prefix=     @exec_prefix@
- # Install prefix for data files
- datarootdir=    @datarootdir@
- 
-+# Name of "lib" directory under prefix
-+platsubdir=   @platsubdir@
-+
- # Expanded directories
- BINDIR=               @bindir@
- LIBDIR=               @libdir@
- MANDIR=               @mandir@
- INCLUDEDIR=   @includedir@
- CONFINCLUDEDIR=       $(exec_prefix)/include
--SCRIPTDIR=    $(prefix)/lib64
-+SCRIPTDIR=    @libdir@
- ABIFLAGS=     @ABIFLAGS@
- 
- # Detailed destination directories
-@@ -754,6 +757,7 @@ Modules/getpath.o: $(srcdir)/Modules/get
-               -DEXEC_PREFIX='"$(exec_prefix)"' \
-               -DVERSION='"$(VERSION)"' \
-               -DVPATH='"$(VPATH)"' \
-+              -DPLATLIBDIR='"$(platsubdir)"' \
-               -o $@ $(srcdir)/Modules/getpath.c
- 
- Programs/python.o: $(srcdir)/Programs/python.c
---- a/Modules/getpath.c
-+++ b/Modules/getpath.c
-@@ -55,12 +55,12 @@
-  * pybuilddir.txt.  If the landmark is found, we're done.
-  *
-  * For the remaining steps, the prefix landmark will always be
-- * lib/python$VERSION/os.py and the exec_prefix will always be
-- * lib/python$VERSION/lib-dynload, where $VERSION is Python's version
-- * number as supplied by the Makefile.  Note that this means that no more
-- * build directory checking is performed; if the first step did not find
-- * the landmarks, the assumption is that python is running from an
-- * installed setup.
-+ * $lib/python$VERSION/os.py and the exec_prefix will always be
-+ * $lib/python$VERSION/lib-dynload, where $VERSION is Python's version
-+ * number and $lib is PLATLIBDIR as supplied by the Makefile.  Note that
-+ * this means that no more build directory checking is performed; if the
-+ * first step did not find the landmarks, the assumption is that python
-+ * is running from an installed setup.
-  *
-  * Step 2. See if the $PYTHONHOME environment variable points to the
-  * installed location of the Python libraries.  If $PYTHONHOME is set, then
-@@ -86,7 +86,7 @@
-  * containing the shared library modules is appended.  The environment
-  * variable $PYTHONPATH is inserted in front of it all.  Finally, the
-  * prefix and exec_prefix globals are tweaked so they reflect the values
-- * expected by other code, by stripping the "lib/python$VERSION/..." stuff
-+ * expected by other code, by stripping the "$lib/python$VERSION/..." stuff
-  * off.  If either points to the build directory, the globals are reset to
-  * the corresponding preprocessor variables (so sys.prefix will reflect the
-  * installation location, even though sys.path points into the build
-@@ -105,8 +105,8 @@ extern "C" {
- #endif
- 
- 
--#if !defined(PREFIX) || !defined(EXEC_PREFIX) || !defined(VERSION) || 
!defined(VPATH)
--#error "PREFIX, EXEC_PREFIX, VERSION, and VPATH must be constant defined"
-+#if !defined(PREFIX) || !defined(EXEC_PREFIX) || !defined(VERSION) || 
!defined(VPATH) || !defined(PLATLIBDIR)
-+#error "PREFIX, EXEC_PREFIX, VERSION, VPATH, and PLATLIBDIR must be constant 
defined"
- #endif
- 
- #ifndef LANDMARK
-@@ -730,7 +730,7 @@ calculate_exec_prefix(PyCalculatePath *c
-         if (safe_wcscpy(exec_prefix, calculate->exec_prefix, exec_prefix_len) 
< 0) {
-             return PATHLEN_ERR();
-         }
--        status = joinpath(exec_prefix, L"lib64/lib-dynload", exec_prefix_len);
-+        status = joinpath(exec_prefix, L"lib/lib-dynload", exec_prefix_len);
-         if (_PyStatus_EXCEPTION(status)) {
-             return status;
-         }
-@@ -1067,7 +1067,7 @@ calculate_zip_path(PyCalculatePath *calc
-             return PATHLEN_ERR();
-         }
-     }
--    status = joinpath(zip_path, L"lib64/python00.zip", zip_path_len);
-+    status = joinpath(zip_path, L"lib/python00.zip", zip_path_len);
-     if (_PyStatus_EXCEPTION(status)) {
-         return status;
-     }
-@@ -1197,7 +1197,7 @@ calculate_init(PyCalculatePath *calculat
-     if (!calculate->exec_prefix) {
-         return DECODE_LOCALE_ERR("EXEC_PREFIX define", len);
-     }
--    calculate->lib_python = Py_DecodeLocale("lib64/python" VERSION, &len);
-+    calculate->lib_python = Py_DecodeLocale(PLATLIBDIR "/python" VERSION, 
&len);
-     if (!calculate->lib_python) {
-         return DECODE_LOCALE_ERR("EXEC_PREFIX define", len);
-     }
+---
+ Lib/distutils/command/install.py |   18 +++++++++---------
+ Lib/distutils/sysconfig.py       |    7 ++-----
+ Lib/site.py                      |   19 +++++++++----------
+ Lib/sysconfig.py                 |   12 ++++++------
+ Lib/test/test_embed.py           |   10 +++++++---
+ Lib/test/test_site.py            |    7 +++++--
+ Lib/test/test_sysconfig.py       |   14 +++++++++++++-
+ Makefile.pre.in                  |    6 +++++-
+ Modules/getpath.c                |   24 ++++++++++++------------
+ configure                        |    4 ++--
+ configure.ac                     |   18 ++++++++++++++++--
+ setup.py                         |    6 +++---
+ 12 files changed, 89 insertions(+), 56 deletions(-)
+
 --- a/Lib/distutils/command/install.py
 +++ b/Lib/distutils/command/install.py
 @@ -30,14 +30,14 @@ WINDOWS_SCHEME = {
@@ -196,36 +84,6 @@
          if standard_lib:
              return libpython
          else:
---- a/Lib/sysconfig.py
-+++ b/Lib/sysconfig.py
-@@ -20,10 +20,10 @@ __all__ = [
- 
- _INSTALL_SCHEMES = {
-     'posix_prefix': {
--        'stdlib': '{installed_base}/lib64/python{py_version_short}',
--        'platstdlib': '{platbase}/lib64/python{py_version_short}',
-+        'stdlib': '{installed_base}/{platsubdir}/python{py_version_short}',
-+        'platstdlib': '{platbase}/{platsubdir}/python{py_version_short}',
-         'purelib': '{base}/lib/python{py_version_short}/site-packages',
--        'platlib': '{platbase}/lib64/python{py_version_short}/site-packages',
-+        'platlib': 
'{platbase}/{platsubdir}/python{py_version_short}/site-packages',
-         'include':
-             '{installed_base}/include/python{py_version_short}{abiflags}',
-         'platinclude':
-@@ -62,10 +62,10 @@ _INSTALL_SCHEMES = {
-         'data': '{userbase}',
-         },
-     'posix_user': {
--        'stdlib': '{userbase}/lib64/python{py_version_short}',
--        'platstdlib': '{userbase}/lib64/python{py_version_short}',
-+        'stdlib': '{userbase}/lib/python{py_version_short}',
-+        'platstdlib': '{userbase}/lib/python{py_version_short}',
-         'purelib': '{userbase}/lib/python{py_version_short}/site-packages',
--        'platlib': '{userbase}/lib64/python{py_version_short}/site-packages',
-+        'platlib': '{userbase}/lib/python{py_version_short}/site-packages',
-         'include': '{userbase}/include/python{py_version_short}',
-         'scripts': '{userbase}/bin',
-         'data': '{userbase}',
 --- a/Lib/site.py
 +++ b/Lib/site.py
 @@ -335,12 +335,18 @@ def getsitepackages(prefixes=None):
@@ -265,6 +123,79 @@
      for sitedir in getsitepackages(prefixes):
          if os.path.isdir(sitedir):
              addsitedir(sitedir, known_paths)
+--- a/Lib/sysconfig.py
++++ b/Lib/sysconfig.py
+@@ -20,10 +20,10 @@ __all__ = [
+ 
+ _INSTALL_SCHEMES = {
+     'posix_prefix': {
+-        'stdlib': '{installed_base}/lib64/python{py_version_short}',
+-        'platstdlib': '{platbase}/lib64/python{py_version_short}',
++        'stdlib': '{installed_base}/{platsubdir}/python{py_version_short}',
++        'platstdlib': '{platbase}/{platsubdir}/python{py_version_short}',
+         'purelib': '{base}/lib/python{py_version_short}/site-packages',
+-        'platlib': '{platbase}/lib64/python{py_version_short}/site-packages',
++        'platlib': 
'{platbase}/{platsubdir}/python{py_version_short}/site-packages',
+         'include':
+             '{installed_base}/include/python{py_version_short}{abiflags}',
+         'platinclude':
+@@ -62,10 +62,10 @@ _INSTALL_SCHEMES = {
+         'data': '{userbase}',
+         },
+     'posix_user': {
+-        'stdlib': '{userbase}/lib64/python{py_version_short}',
+-        'platstdlib': '{userbase}/lib64/python{py_version_short}',
++        'stdlib': '{userbase}/lib/python{py_version_short}',
++        'platstdlib': '{userbase}/lib/python{py_version_short}',
+         'purelib': '{userbase}/lib/python{py_version_short}/site-packages',
+-        'platlib': '{userbase}/lib64/python{py_version_short}/site-packages',
++        'platlib': '{userbase}/lib/python{py_version_short}/site-packages',
+         'include': '{userbase}/include/python{py_version_short}',
+         'scripts': '{userbase}/bin',
+         'data': '{userbase}',
+--- a/Lib/test/test_embed.py
++++ b/Lib/test/test_embed.py
+@@ -10,6 +10,7 @@ import re
+ import shutil
+ import subprocess
+ import sys
++import sysconfig
+ import tempfile
+ import textwrap
+ 
+@@ -1072,12 +1073,13 @@ class InitConfigTests(EmbeddingTestsMixi
+             return config['config']['module_search_paths']
+         else:
+             ver = sys.version_info
++            platsubdir = sysconfig.get_config_var('platsubdir')
+             return [
+                 os.path.join(prefix, 'lib',
+                              f'python{ver.major}{ver.minor}.zip'),
+-                os.path.join(prefix, 'lib',
++                os.path.join(prefix, platsubdir,
+                              f'python{ver.major}.{ver.minor}'),
+-                os.path.join(exec_prefix, 'lib',
++                os.path.join(exec_prefix, platsubdir,
+                              f'python{ver.major}.{ver.minor}', 'lib-dynload'),
+             ]
+ 
+@@ -1188,13 +1190,15 @@ class InitConfigTests(EmbeddingTestsMixi
+     def test_init_pyvenv_cfg(self):
+         # Test path configuration with pyvenv.cfg configuration file
+ 
++        platsubdir = sysconfig.get_config_var('platsubdir')
++
+         with self.tmpdir_with_python() as tmpdir, \
+              tempfile.TemporaryDirectory() as pyvenv_home:
+             ver = sys.version_info
+ 
+             if not MS_WINDOWS:
+                 lib_dynload = os.path.join(pyvenv_home,
+-                                           'lib',
++                                           platsubdir,
+                                            f'python{ver.major}.{ver.minor}',
+                                            'lib-dynload')
+                 os.makedirs(lib_dynload)
 --- a/Lib/test/test_site.py
 +++ b/Lib/test/test_site.py
 @@ -267,8 +267,11 @@ class HelperFunctionsTests(unittest.Test
@@ -312,9 +243,105 @@
  
      def test_main(self):
          # just making sure _main() runs and returns things in the stdout
+--- a/Makefile.pre.in
++++ b/Makefile.pre.in
+@@ -137,13 +137,16 @@ exec_prefix=     @exec_prefix@
+ # Install prefix for data files
+ datarootdir=    @datarootdir@
+ 
++# Name of "lib" directory under prefix
++platsubdir=   @platsubdir@
++
+ # Expanded directories
+ BINDIR=               @bindir@
+ LIBDIR=               @libdir@
+ MANDIR=               @mandir@
+ INCLUDEDIR=   @includedir@
+ CONFINCLUDEDIR=       $(exec_prefix)/include
+-SCRIPTDIR=    $(prefix)/lib64
++SCRIPTDIR=    @libdir@
+ ABIFLAGS=     @ABIFLAGS@
+ 
+ # Detailed destination directories
+@@ -754,6 +757,7 @@ Modules/getpath.o: $(srcdir)/Modules/get
+               -DEXEC_PREFIX='"$(exec_prefix)"' \
+               -DVERSION='"$(VERSION)"' \
+               -DVPATH='"$(VPATH)"' \
++              -DPLATLIBDIR='"$(platsubdir)"' \
+               -o $@ $(srcdir)/Modules/getpath.c
+ 
+ Programs/python.o: $(srcdir)/Programs/python.c
+--- a/Modules/getpath.c
++++ b/Modules/getpath.c
+@@ -55,12 +55,12 @@
+  * pybuilddir.txt.  If the landmark is found, we're done.
+  *
+  * For the remaining steps, the prefix landmark will always be
+- * lib/python$VERSION/os.py and the exec_prefix will always be
+- * lib/python$VERSION/lib-dynload, where $VERSION is Python's version
+- * number as supplied by the Makefile.  Note that this means that no more
+- * build directory checking is performed; if the first step did not find
+- * the landmarks, the assumption is that python is running from an
+- * installed setup.
++ * $lib/python$VERSION/os.py and the exec_prefix will always be
++ * $lib/python$VERSION/lib-dynload, where $VERSION is Python's version
++ * number and $lib is PLATLIBDIR as supplied by the Makefile.  Note that
++ * this means that no more build directory checking is performed; if the
++ * first step did not find the landmarks, the assumption is that python
++ * is running from an installed setup.
+  *
+  * Step 2. See if the $PYTHONHOME environment variable points to the
+  * installed location of the Python libraries.  If $PYTHONHOME is set, then
+@@ -86,7 +86,7 @@
+  * containing the shared library modules is appended.  The environment
+  * variable $PYTHONPATH is inserted in front of it all.  Finally, the
+  * prefix and exec_prefix globals are tweaked so they reflect the values
+- * expected by other code, by stripping the "lib/python$VERSION/..." stuff
++ * expected by other code, by stripping the "$lib/python$VERSION/..." stuff
+  * off.  If either points to the build directory, the globals are reset to
+  * the corresponding preprocessor variables (so sys.prefix will reflect the
+  * installation location, even though sys.path points into the build
+@@ -105,8 +105,8 @@ extern "C" {
+ #endif
+ 
+ 
+-#if !defined(PREFIX) || !defined(EXEC_PREFIX) || !defined(VERSION) || 
!defined(VPATH)
+-#error "PREFIX, EXEC_PREFIX, VERSION, and VPATH must be constant defined"
++#if !defined(PREFIX) || !defined(EXEC_PREFIX) || !defined(VERSION) || 
!defined(VPATH) || !defined(PLATLIBDIR)
++#error "PREFIX, EXEC_PREFIX, VERSION, VPATH, and PLATLIBDIR must be constant 
defined"
+ #endif
+ 
+ #ifndef LANDMARK
+@@ -730,7 +730,7 @@ calculate_exec_prefix(PyCalculatePath *c
+         if (safe_wcscpy(exec_prefix, calculate->exec_prefix, exec_prefix_len) 
< 0) {
+             return PATHLEN_ERR();
+         }
+-        status = joinpath(exec_prefix, L"lib64/lib-dynload", exec_prefix_len);
++        status = joinpath(exec_prefix, L"lib/lib-dynload", exec_prefix_len);
+         if (_PyStatus_EXCEPTION(status)) {
+             return status;
+         }
+@@ -1067,7 +1067,7 @@ calculate_zip_path(PyCalculatePath *calc
+             return PATHLEN_ERR();
+         }
+     }
+-    status = joinpath(zip_path, L"lib64/python00.zip", zip_path_len);
++    status = joinpath(zip_path, L"lib/python00.zip", zip_path_len);
+     if (_PyStatus_EXCEPTION(status)) {
+         return status;
+     }
+@@ -1197,7 +1197,7 @@ calculate_init(PyCalculatePath *calculat
+     if (!calculate->exec_prefix) {
+         return DECODE_LOCALE_ERR("EXEC_PREFIX define", len);
+     }
+-    calculate->lib_python = Py_DecodeLocale("lib64/python" VERSION, &len);
++    calculate->lib_python = Py_DecodeLocale(PLATLIBDIR "/python" VERSION, 
&len);
+     if (!calculate->lib_python) {
+         return DECODE_LOCALE_ERR("EXEC_PREFIX define", len);
+     }
 --- a/configure
 +++ b/configure
-@@ -15233,9 +15233,9 @@ fi
+@@ -15222,9 +15222,9 @@ fi
  
  
  if test x$PLATFORM_TRIPLET = x; then
@@ -326,6 +353,37 @@
  fi
  
  
+--- a/configure.ac
++++ b/configure.ac
+@@ -4695,12 +4695,26 @@ else
+   LIBPYTHON=''
+ fi
+ 
++# platsubdir must be defined before LIBPL definition
++AC_MSG_CHECKING(for custom platsubdir)
++AC_ARG_WITH(custom-platsubdir,
++    [AS_HELP_STRING([--with-custom-platsubdir=<libdirname>],
++        [set the platsubdir name to a custom string])],
++    [],
++    [with_custom_platsubdir=yes])
++AS_CASE($with_custom_platsubdir,
++    [yes],[platsubdir=`basename ${libdir}`],
++    [no],[platsubdir=lib],
++    [platsubdir=$with_custom_platsubdir])
++AC_MSG_RESULT($platsubdir)
++AC_SUBST(platsubdir)
++
+ dnl define LIBPL after ABIFLAGS and LDVERSION is defined.
+ AC_SUBST(PY_ENABLE_SHARED)
+ if test x$PLATFORM_TRIPLET = x; then
+-  LIBPL='$(prefix)'"/lib64/python${VERSION}/config-${LDVERSION}"
++  LIBPL='$(prefix)'"/${platsubdir}/python${VERSION}/config-${LDVERSION}"
+ else
+-  
LIBPL='$(prefix)'"/lib64/python${VERSION}/config-${LDVERSION}-${PLATFORM_TRIPLET}"
++  
LIBPL='$(prefix)'"/${platsubdir}/python${VERSION}/config-${LDVERSION}-${PLATFORM_TRIPLET}"
+ fi
+ AC_SUBST(LIBPL)
+ 
 --- a/setup.py
 +++ b/setup.py
 @@ -649,7 +649,7 @@ class PyBuildExt(build_ext):
@@ -351,46 +409,3 @@
                                 extra_link_args=readline_extra_link_args,
                                 libraries=readline_libs))
          else:
---- a/Lib/test/test_embed.py
-+++ b/Lib/test/test_embed.py
-@@ -10,6 +10,7 @@ import re
- import shutil
- import subprocess
- import sys
-+import sysconfig
- import tempfile
- import textwrap
- 
-@@ -1072,12 +1073,13 @@ class InitConfigTests(EmbeddingTestsMixi
-             return config['config']['module_search_paths']
-         else:
-             ver = sys.version_info
-+            platsubdir = sysconfig.get_config_var('platsubdir')
-             return [
-                 os.path.join(prefix, 'lib',
-                              f'python{ver.major}{ver.minor}.zip'),
--                os.path.join(prefix, 'lib',
-+                os.path.join(prefix, platsubdir,
-                              f'python{ver.major}.{ver.minor}'),
--                os.path.join(exec_prefix, 'lib',
-+                os.path.join(exec_prefix, platsubdir,
-                              f'python{ver.major}.{ver.minor}', 'lib-dynload'),
-             ]
- 
-@@ -1188,13 +1190,15 @@ class InitConfigTests(EmbeddingTestsMixi
-     def test_init_pyvenv_cfg(self):
-         # Test path configuration with pyvenv.cfg configuration file
- 
-+        platsubdir = sysconfig.get_config_var('platsubdir')
-+
-         with self.tmpdir_with_python() as tmpdir, \
-              tempfile.TemporaryDirectory() as pyvenv_home:
-             ver = sys.version_info
- 
-             if not MS_WINDOWS:
-                 lib_dynload = os.path.join(pyvenv_home,
--                                           'lib',
-+                                           platsubdir,
-                                            f'python{ver.major}.{ver.minor}',
-                                            'lib-dynload')
-                 os.makedirs(lib_dynload)

Reply via email to