diff --git a/README.md b/README.md index 1c26d6426..e876d31f3 100644 --- a/README.md +++ b/README.md @@ -1,5 +1,5 @@ -About python-split -================== +About python +============ Home: https://www.python.org/ @@ -106,10 +106,10 @@ Current release info | [![Conda Recipe](https://img.shields.io/badge/recipe-libpython--static-green.svg)](https://anaconda.org/conda-forge/libpython-static) | [![Conda Downloads](https://img.shields.io/conda/dn/conda-forge/libpython-static.svg)](https://anaconda.org/conda-forge/libpython-static) | [![Conda Version](https://img.shields.io/conda/vn/conda-forge/libpython-static.svg)](https://anaconda.org/conda-forge/libpython-static) | [![Conda Platforms](https://img.shields.io/conda/pn/conda-forge/libpython-static.svg)](https://anaconda.org/conda-forge/libpython-static) | | [![Conda Recipe](https://img.shields.io/badge/recipe-python-green.svg)](https://anaconda.org/conda-forge/python) | [![Conda Downloads](https://img.shields.io/conda/dn/conda-forge/python.svg)](https://anaconda.org/conda-forge/python) | [![Conda Version](https://img.shields.io/conda/vn/conda-forge/python.svg)](https://anaconda.org/conda-forge/python) | [![Conda Platforms](https://img.shields.io/conda/pn/conda-forge/python.svg)](https://anaconda.org/conda-forge/python) | -Installing python-split -======================= +Installing python +================= -Installing `python-split` from the `conda-forge` channel can be achieved by adding `conda-forge` to your channels with: +Installing `python` from the `conda-forge` channel can be achieved by adding `conda-forge` to your channels with: ``` conda config --add channels conda-forge @@ -166,17 +166,17 @@ Terminology produce the finished article (built conda distributions) -Updating python-split-feedstock -=============================== +Updating python-feedstock +========================= -If you would like to improve the python-split recipe or build a new +If you would like to improve the python recipe or build a new package version, please fork this repository and submit a PR. Upon submission, your changes will be run on the appropriate platforms to give the reviewer an opportunity to confirm that the changes result in a successful build. Once merged, the recipe will be re-built and uploaded automatically to the `conda-forge` channel, whereupon the built conda packages will be available for everybody to install and use from the `conda-forge` channel. -Note that all branches in the conda-forge/python-split-feedstock are +Note that all branches in the conda-forge/python-feedstock are immediately built and any created packages are uploaded, so PRs should be based on branches in forks and branches in the main repository should only be used to build distinct package versions. diff --git a/recipe/meta.yaml b/recipe/meta.yaml index 960222d98..e06936665 100644 --- a/recipe/meta.yaml +++ b/recipe/meta.yaml @@ -1,4 +1,4 @@ -{% set version = "3.8.5" %} +{% set version = "3.8.6" %} {% set linkage_nature = os.environ.get('PY_INTERP_LINKAGE_NATURE', '') %} {% set debug = os.environ.get('PY_INTERP_DEBUG', '') %} {% if linkage_nature != '' %} @@ -15,41 +15,43 @@ package: source: - url: https://www.python.org/ftp/python/{{ version }}/Python-{{ version }}.tar.xz # md5 from: https://www.python.org/downloads/release/python-385/ - md5: 35b5a3d0254c1c59be9736373d429db7 + md5: 69e73c49eeb1a853cefd26d18c9d069d patches: - - patches/0000-Fix-off-by-one-error-in-_winapi_WaitForMultipleObjec.patch + - patches/0001-Fix-off-by-one-error-in-_winapi_WaitForMultipleObjec.patch {% if 'conda-forge' not in channel_targets %} - - patches/0001-Add-Anaconda-Distribution-version-logic.patch + - patches/0002-Add-Anaconda-Distribution-version-logic.patch {% endif %} - - patches/0002-Darwin-Add-arch-x86_64-to-UnicCCompiler-ld_args.patch - - patches/0003-Win32-Change-FD_SETSIZE-from-512-to-2048.patch - - patches/0004-Win32-distutils-Add-support-to-cygwinccompiler-for-V.patch - - patches/0005-Do-not-pass-g-to-GCC-when-not-Py_DEBUG.patch - - patches/0006-Support-cross-compiling-byte-code.patch - - patches/0007-Win32-Fixes-for-Windows-GCC-interop-needed-by-RPy2-a.patch - - patches/0008-Darwin-Look-in-sysroot-usr-lib-include-if-sysroot-is.patch - - patches/0009-runtime_library_dir_option-Use-1st-word-of-CC-as-com.patch - - patches/0010-Win32-Do-not-download-externals.patch - - patches/0011-Add-support-for-_CONDA_PYTHON_SYSCONFIGDATA_NAME-if-.patch - - patches/0012-Fix-find_library-so-that-it-looks-in-sys.prefix-lib-.patch - - patches/0013-Disable-new-dtags-in-unixccompiler.py.patch - - patches/0014-Fix-cross-compilation-on-Debian-based-distros.patch - - patches/0015-Disable-registry-lookup-unless-CONDA_PY_ALLOW_REG_PA.patch - - patches/0016-Unvendor-openssl.patch - - patches/0017-Unvendor-sqlite3.patch + - patches/0003-Darwin-Add-arch-x86_64-to-UnicCCompiler-ld_args.patch + - patches/0004-Win32-Change-FD_SETSIZE-from-512-to-2048.patch + - patches/0005-Win32-distutils-Add-support-to-cygwinccompiler-for-V.patch + - patches/0006-Do-not-pass-g-to-GCC-when-not-Py_DEBUG.patch + - patches/0007-Support-cross-compiling-byte-code.patch + - patches/0008-Win32-Fixes-for-Windows-GCC-interop-needed-by-RPy2-a.patch + - patches/0009-Darwin-Look-in-sysroot-usr-lib-include-if-sysroot-is.patch + - patches/0010-runtime_library_dir_option-Use-1st-word-of-CC-as-com.patch + - patches/0011-Win32-Do-not-download-externals.patch + - patches/0012-Add-support-for-_CONDA_PYTHON_SYSCONFIGDATA_NAME-if-.patch + - patches/0013-Fix-find_library-so-that-it-looks-in-sys.prefix-lib-.patch + - patches/0014-Disable-new-dtags-in-unixccompiler.py.patch + - patches/0015-Fix-cross-compilation-on-Debian-based-distros.patch + - patches/0016-Disable-registry-lookup-unless-CONDA_PY_ALLOW_REG_PA.patch + - patches/0017-Unvendor-openssl.patch + - patches/0018-Unvendor-sqlite3.patch # https://bugs.python.org/issue35644 - - patches/0018-venv-Revert-a-change-from-https-github.com-python-cp.patch - - patches/0019-Win-Add-back-the-DLLSuffix-used-to-find-the-openssl-.patch - - patches/0020-Use-ranlib-from-env-if-env-variable-is-set.patch - - patches/0021-roll-back-2e33ecd-for-py_compile.main.patch + - patches/0019-venv-Revert-a-change-from-https-github.com-python-cp.patch + - patches/0020-Win-Add-back-the-DLLSuffix-used-to-find-the-openssl-.patch + - patches/0021-Use-ranlib-from-env-if-env-variable-is-set.patch # Python 3.8 is pretty broken without this. - patches/0022-Add-CondaEcosystemModifyDllSearchPath.patch - - patches/0026-Revert-part-of-https-bugs.python.org-issue33895-http.patch - - patches/0027-cross-compile-darwin.patch - - patches/gh21114.patch - - patches/gh21241.patch - - patches/gh21228.patch - - patches/gh21564.patch # [osx and arm64] + - patches/0023-Revert-part-of-https-bugs.python.org-issue33895-http.patch + - patches/0024-cross-compile-darwin.patch.patch + - patches/0025-BPO-41101-Support-arm64-in-Mac-Tools-pythonw.patch + - patches/0026-fix-_decimal-for-arm64-Mac-OS.patch + - patches/0027-Added-by-blurb_it.patch + - patches/0028-ctypes-check-_dyld_shared_cache_contains_path-in-fin.patch + - patches/0029-fix-test_macholib-for-Mac-OS-11.patch + - patches/0030-Xcode-12-Beta-4-declares-_dyld_shared_cache_contains.patch + - patches/0031-gh21564.patch.patch # [osx and arm64] # TODO :: Depend on our own packages for these: - url: https://github.com/python/cpython-source-deps/archive/xz-5.2.2.zip # [win] @@ -83,7 +85,7 @@ source: sha256: 4872e72e188a5aa1124db0c3b163a4163e84ead359a514d86dd7c6fa2d2ff02a # [win] build: - number: 9 + number: 0 script_env: - PY_INTERP_LINKAGE_NATURE - PY_INTERP_DEBUG @@ -268,6 +270,7 @@ about: dev_url: https://docs.python.org/devguide/ extra: + feedstock-name: python recipe-maintainers: - isuruf - jakirkham diff --git a/recipe/patches/0000-Fix-off-by-one-error-in-_winapi_WaitForMultipleObjec.patch b/recipe/patches/0001-Fix-off-by-one-error-in-_winapi_WaitForMultipleObjec.patch similarity index 86% rename from recipe/patches/0000-Fix-off-by-one-error-in-_winapi_WaitForMultipleObjec.patch rename to recipe/patches/0001-Fix-off-by-one-error-in-_winapi_WaitForMultipleObjec.patch index 1af14206b..da30fd450 100644 --- a/recipe/patches/0000-Fix-off-by-one-error-in-_winapi_WaitForMultipleObjec.patch +++ b/recipe/patches/0001-Fix-off-by-one-error-in-_winapi_WaitForMultipleObjec.patch @@ -1,7 +1,7 @@ -From 48755cdaaeb7e4ab82d1b96cc80c0ab67a0c7b0d Mon Sep 17 00:00:00 2001 +From ff73ed68d55b4e19fa12c9c743c75df513cf9ca2 Mon Sep 17 00:00:00 2001 From: Ray Donnelly Date: Sun, 12 Apr 2020 18:22:21 +0200 -Subject: [PATCH 00/26] Fix off-by-one-error in +Subject: [PATCH 01/31] Fix off-by-one-error in _winapi_WaitForMultipleObjects_impl --- @@ -22,5 +22,5 @@ index 647075cdb1..aec836ad82 100644 "need at most %zd handles, got a sequence of length %zd", MAXIMUM_WAIT_OBJECTS - 1, nhandles); -- -2.24.3 (Apple Git-128) +2.28.0 diff --git a/recipe/patches/0001-Add-Anaconda-Distribution-version-logic.patch b/recipe/patches/0002-Add-Anaconda-Distribution-version-logic.patch similarity index 91% rename from recipe/patches/0001-Add-Anaconda-Distribution-version-logic.patch rename to recipe/patches/0002-Add-Anaconda-Distribution-version-logic.patch index ed84463d8..f03cf6bad 100644 --- a/recipe/patches/0001-Add-Anaconda-Distribution-version-logic.patch +++ b/recipe/patches/0002-Add-Anaconda-Distribution-version-logic.patch @@ -1,7 +1,7 @@ -From 82cbac6e16381c7c0f6f096f5be97e361d262402 Mon Sep 17 00:00:00 2001 +From 15ee989aff78d9f18f4bec79bff3cb8d28baa890 Mon Sep 17 00:00:00 2001 From: Ray Donnelly Date: Tue, 15 Aug 2017 22:34:16 +0100 -Subject: [PATCH 01/22] Add Anaconda Distribution version logic +Subject: [PATCH 02/31] Add Anaconda Distribution version logic --- Include/pylifecycle.h | 1 + @@ -11,7 +11,7 @@ Subject: [PATCH 01/22] Add Anaconda Distribution version logic 4 files changed, 50 insertions(+), 1 deletion(-) diff --git a/Include/pylifecycle.h b/Include/pylifecycle.h -index c5368b3..06cb88e 100644 +index c5368b3c5e..06cb88ee9c 100644 --- a/Include/pylifecycle.h +++ b/Include/pylifecycle.h @@ -52,6 +52,7 @@ int _Py_CheckPython3(void); @@ -23,7 +23,7 @@ index c5368b3..06cb88e 100644 PyAPI_FUNC(const char *) Py_GetPlatform(void); PyAPI_FUNC(const char *) Py_GetCopyright(void); diff --git a/Lib/platform.py b/Lib/platform.py -index 994d892..2df9c1e 100755 +index 994d892c5e..2df9c1ef92 100755 --- a/Lib/platform.py +++ b/Lib/platform.py @@ -943,6 +943,7 @@ def processor(): @@ -35,7 +35,7 @@ index 994d892..2df9c1e 100755 r'(?:,\s*([\w ]*)' # ", builddate" r'(?:,\s*([\w :]*))?)?\)\s*' # ", buildtime)" diff --git a/Modules/main.c b/Modules/main.c -index 70be4cf..5150587 100644 +index 70be4cfacb..5150587a75 100644 --- a/Modules/main.c +++ b/Modules/main.c @@ -204,7 +204,7 @@ pymain_header(const PyConfig *config) @@ -48,7 +48,7 @@ index 70be4cf..5150587 100644 fprintf(stderr, "%s\n", COPYRIGHT); } diff --git a/Python/getversion.c b/Python/getversion.c -index c32b6f9..b5dfffb 100644 +index c32b6f9d60..b5dfffb606 100644 --- a/Python/getversion.c +++ b/Python/getversion.c @@ -2,9 +2,56 @@ @@ -109,5 +109,5 @@ index c32b6f9..b5dfffb 100644 Py_GetVersion(void) { -- -2.20.1 +2.28.0 diff --git a/recipe/patches/0002-Darwin-Add-arch-x86_64-to-UnicCCompiler-ld_args.patch b/recipe/patches/0003-Darwin-Add-arch-x86_64-to-UnicCCompiler-ld_args.patch similarity index 73% rename from recipe/patches/0002-Darwin-Add-arch-x86_64-to-UnicCCompiler-ld_args.patch rename to recipe/patches/0003-Darwin-Add-arch-x86_64-to-UnicCCompiler-ld_args.patch index 5f4d8b80c..42a14e6f1 100644 --- a/recipe/patches/0002-Darwin-Add-arch-x86_64-to-UnicCCompiler-ld_args.patch +++ b/recipe/patches/0003-Darwin-Add-arch-x86_64-to-UnicCCompiler-ld_args.patch @@ -1,14 +1,14 @@ -From 0fcc174b9cef0d93ebf1c95fd942c1368132cfdc Mon Sep 17 00:00:00 2001 +From fa4bcb5f1681a298b7f1bfe9184b83550f28c3d3 Mon Sep 17 00:00:00 2001 From: Ray Donnelly Date: Wed, 16 Aug 2017 08:48:16 +0100 -Subject: [PATCH 02/22] Darwin: Add -arch x86_64 to UnicCCompiler ld_args +Subject: [PATCH 03/31] Darwin: Add -arch x86_64 to UnicCCompiler ld_args --- - Lib/distutils/unixccompiler.py | 1 + - 1 file changed, 1 insertion(+) + Lib/distutils/unixccompiler.py | 2 ++ + 1 file changed, 2 insertions(+) diff --git a/Lib/distutils/unixccompiler.py b/Lib/distutils/unixccompiler.py -index 4d7a6de..3f05cf7 100644 +index 4d7a6de740..0ca7c8466a 100644 --- a/Lib/distutils/unixccompiler.py +++ b/Lib/distutils/unixccompiler.py @@ -200,6 +200,8 @@ class UnixCCompiler(CCompiler): @@ -21,5 +21,5 @@ index 4d7a6de..3f05cf7 100644 self.spawn(linker + ld_args) except DistutilsExecError as msg: -- -2.20.1 +2.28.0 diff --git a/recipe/patches/0003-Win32-Change-FD_SETSIZE-from-512-to-2048.patch b/recipe/patches/0004-Win32-Change-FD_SETSIZE-from-512-to-2048.patch similarity index 77% rename from recipe/patches/0003-Win32-Change-FD_SETSIZE-from-512-to-2048.patch rename to recipe/patches/0004-Win32-Change-FD_SETSIZE-from-512-to-2048.patch index 070d8aedc..f66ac5907 100644 --- a/recipe/patches/0003-Win32-Change-FD_SETSIZE-from-512-to-2048.patch +++ b/recipe/patches/0004-Win32-Change-FD_SETSIZE-from-512-to-2048.patch @@ -1,7 +1,7 @@ -From 3cfb2a1a74d411520729a6b817855fbd73f70e40 Mon Sep 17 00:00:00 2001 +From a39af2eb640918cf10e412811fe5706d83000ca0 Mon Sep 17 00:00:00 2001 From: Ray Donnelly Date: Wed, 16 Aug 2017 11:53:55 +0100 -Subject: [PATCH 03/22] Win32: Change FD_SETSIZE from 512 to 2048 +Subject: [PATCH 04/31] Win32: Change FD_SETSIZE from 512 to 2048 https://github.com/ContinuumIO/anaconda-issues/issues/1241 --- @@ -9,7 +9,7 @@ https://github.com/ContinuumIO/anaconda-issues/issues/1241 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Modules/selectmodule.c b/Modules/selectmodule.c -index a71b642..746bae1 100644 +index a71b64223d..746bae17ab 100644 --- a/Modules/selectmodule.c +++ b/Modules/selectmodule.c @@ -33,7 +33,7 @@ @@ -22,5 +22,5 @@ index a71b642..746bae1 100644 #if defined(HAVE_POLL_H) -- -2.20.1 +2.28.0 diff --git a/recipe/patches/0004-Win32-distutils-Add-support-to-cygwinccompiler-for-V.patch b/recipe/patches/0005-Win32-distutils-Add-support-to-cygwinccompiler-for-V.patch similarity index 80% rename from recipe/patches/0004-Win32-distutils-Add-support-to-cygwinccompiler-for-V.patch rename to recipe/patches/0005-Win32-distutils-Add-support-to-cygwinccompiler-for-V.patch index a691c6e41..1a0dde2d0 100644 --- a/recipe/patches/0004-Win32-distutils-Add-support-to-cygwinccompiler-for-V.patch +++ b/recipe/patches/0005-Win32-distutils-Add-support-to-cygwinccompiler-for-V.patch @@ -1,7 +1,7 @@ -From d6363bb4855d87106c55f383731331dce628b8b9 Mon Sep 17 00:00:00 2001 +From e159e24dd7fb2be2dbbb6ac5dabb4c808721de91 Mon Sep 17 00:00:00 2001 From: Ray Donnelly Date: Wed, 16 Aug 2017 11:59:00 +0100 -Subject: [PATCH 04/22] Win32: distutils: Add support to cygwinccompiler for +Subject: [PATCH 05/31] Win32: distutils: Add support to cygwinccompiler for VS>=2015 Really this is for mingw-w64 though @@ -10,7 +10,7 @@ Really this is for mingw-w64 though 1 file changed, 3 insertions(+) diff --git a/Lib/distutils/cygwinccompiler.py b/Lib/distutils/cygwinccompiler.py -index 6c5d777..48013e1 100644 +index 6c5d77746b..48013e1000 100644 --- a/Lib/distutils/cygwinccompiler.py +++ b/Lib/distutils/cygwinccompiler.py @@ -82,6 +82,9 @@ def get_msvcr(): @@ -24,5 +24,5 @@ index 6c5d777..48013e1 100644 raise ValueError("Unknown MS Compiler version %s " % msc_ver) -- -2.20.1 +2.28.0 diff --git a/recipe/patches/0005-Do-not-pass-g-to-GCC-when-not-Py_DEBUG.patch b/recipe/patches/0006-Do-not-pass-g-to-GCC-when-not-Py_DEBUG.patch similarity index 83% rename from recipe/patches/0005-Do-not-pass-g-to-GCC-when-not-Py_DEBUG.patch rename to recipe/patches/0006-Do-not-pass-g-to-GCC-when-not-Py_DEBUG.patch index 1066f006c..8651cd57e 100644 --- a/recipe/patches/0005-Do-not-pass-g-to-GCC-when-not-Py_DEBUG.patch +++ b/recipe/patches/0006-Do-not-pass-g-to-GCC-when-not-Py_DEBUG.patch @@ -1,7 +1,7 @@ -From 6c2f2d4da6c31b3c2d5dbac48ef5b0ae9365c330 Mon Sep 17 00:00:00 2001 +From cd06372f06730c2c07d82ad42a30f6e5dcbd7e6e Mon Sep 17 00:00:00 2001 From: Ray Donnelly Date: Wed, 16 Aug 2017 11:45:28 +0100 -Subject: [PATCH 05/22] Do not pass -g to GCC when not Py_DEBUG +Subject: [PATCH 06/31] Do not pass -g to GCC when not Py_DEBUG This bloats our exe and our modules a lot. --- @@ -10,7 +10,7 @@ This bloats our exe and our modules a lot. 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/configure b/configure -index 96dcd0d..917ec25 100755 +index 96dcd0dcd5..917ec25dcc 100755 --- a/configure +++ b/configure @@ -4235,9 +4235,9 @@ if test "$ac_test_CFLAGS" = set; then @@ -35,7 +35,7 @@ index 96dcd0d..917ec25 100755 ;; *) diff --git a/configure.ac b/configure.ac -index 18a0446..f37c6a4 100644 +index 18a044629a..f37c6a4256 100644 --- a/configure.ac +++ b/configure.ac @@ -1538,7 +1538,7 @@ then @@ -48,5 +48,5 @@ index 18a0446..f37c6a4 100644 ;; *) -- -2.20.1 +2.28.0 diff --git a/recipe/patches/0006-Support-cross-compiling-byte-code.patch b/recipe/patches/0007-Support-cross-compiling-byte-code.patch similarity index 96% rename from recipe/patches/0006-Support-cross-compiling-byte-code.patch rename to recipe/patches/0007-Support-cross-compiling-byte-code.patch index 94870b59f..7d5379b44 100644 --- a/recipe/patches/0006-Support-cross-compiling-byte-code.patch +++ b/recipe/patches/0007-Support-cross-compiling-byte-code.patch @@ -1,7 +1,7 @@ -From aaf58893a6fc09793fd37e47181975c9c8c988d5 Mon Sep 17 00:00:00 2001 +From 4c5f7ff7abb6444b77ea29631f272bd1b08844fd Mon Sep 17 00:00:00 2001 From: Ray Donnelly Date: Wed, 16 Aug 2017 12:17:33 +0100 -Subject: [PATCH 06/22] Support cross-compiling byte-code +Subject: [PATCH 07/31] Support cross-compiling byte-code https://bugs.python.org/issue22724 --- @@ -11,7 +11,7 @@ https://bugs.python.org/issue22724 3 files changed, 13 insertions(+), 8 deletions(-) diff --git a/Makefile.pre.in b/Makefile.pre.in -index a914a9c..1802362 100644 +index a914a9c70f..18023625df 100644 --- a/Makefile.pre.in +++ b/Makefile.pre.in @@ -245,6 +245,7 @@ BUILDPYTHON= python$(BUILDEXE) @@ -77,7 +77,7 @@ index a914a9c..1802362 100644 --install-scripts=$(BINDIR) \ --install-platlib=$(DESTSHARED) \ diff --git a/configure b/configure -index 917ec25..f3979f1 100755 +index 917ec25dcc..f3979f16be 100755 --- a/configure +++ b/configure @@ -749,6 +749,7 @@ CONFIG_ARGS @@ -99,7 +99,7 @@ index 917ec25..f3979f1 100755 elif test "$cross_compiling" = maybe; then as_fn_error $? "Cross compiling required --host=HOST-TUPLE and --build=ARCH" "$LINENO" 5 diff --git a/configure.ac b/configure.ac -index f37c6a4..7c68866 100644 +index f37c6a4256..7c688668c1 100644 --- a/configure.ac +++ b/configure.ac @@ -75,13 +75,15 @@ if test "$cross_compiling" = yes; then @@ -120,5 +120,5 @@ index f37c6a4..7c68866 100644 dnl Ensure that if prefix is specified, it does not end in a slash. If -- -2.20.1 +2.28.0 diff --git a/recipe/patches/0007-Win32-Fixes-for-Windows-GCC-interop-needed-by-RPy2-a.patch b/recipe/patches/0008-Win32-Fixes-for-Windows-GCC-interop-needed-by-RPy2-a.patch similarity index 88% rename from recipe/patches/0007-Win32-Fixes-for-Windows-GCC-interop-needed-by-RPy2-a.patch rename to recipe/patches/0008-Win32-Fixes-for-Windows-GCC-interop-needed-by-RPy2-a.patch index faf530fe3..ca8fb9f62 100644 --- a/recipe/patches/0007-Win32-Fixes-for-Windows-GCC-interop-needed-by-RPy2-a.patch +++ b/recipe/patches/0008-Win32-Fixes-for-Windows-GCC-interop-needed-by-RPy2-a.patch @@ -1,7 +1,7 @@ -From 7196edaa2dd25f3256b6b1bafc041079801006fc Mon Sep 17 00:00:00 2001 +From 5d956db96ff04c56b6d4d9f7f1f70fbb087b8c95 Mon Sep 17 00:00:00 2001 From: Ray Donnelly Date: Wed, 16 Aug 2017 12:23:02 +0100 -Subject: [PATCH 07/22] Win32: Fixes for Windows GCC interop needed by RPy2 and +Subject: [PATCH 08/31] Win32: Fixes for Windows GCC interop needed by RPy2 and CVXOPT We must pass -DMS_WIN32 or -DMS_WIN64 @@ -10,7 +10,7 @@ We must pass -DMS_WIN32 or -DMS_WIN64 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/Lib/distutils/cygwinccompiler.py b/Lib/distutils/cygwinccompiler.py -index 48013e1..339c278 100644 +index 48013e1000..339c2782f0 100644 --- a/Lib/distutils/cygwinccompiler.py +++ b/Lib/distutils/cygwinccompiler.py @@ -302,9 +302,13 @@ class Mingw32CCompiler(CygwinCCompiler): @@ -31,5 +31,5 @@ index 48013e1..339c278 100644 linker_so='%s %s %s' % (self.linker_dll, shared_option, -- -2.20.1 +2.28.0 diff --git a/recipe/patches/0008-Darwin-Look-in-sysroot-usr-lib-include-if-sysroot-is.patch b/recipe/patches/0009-Darwin-Look-in-sysroot-usr-lib-include-if-sysroot-is.patch similarity index 86% rename from recipe/patches/0008-Darwin-Look-in-sysroot-usr-lib-include-if-sysroot-is.patch rename to recipe/patches/0009-Darwin-Look-in-sysroot-usr-lib-include-if-sysroot-is.patch index 25086d217..473a2edf9 100644 --- a/recipe/patches/0008-Darwin-Look-in-sysroot-usr-lib-include-if-sysroot-is.patch +++ b/recipe/patches/0009-Darwin-Look-in-sysroot-usr-lib-include-if-sysroot-is.patch @@ -1,7 +1,7 @@ -From 1f18ce94acc5a9814b1f9536695e8afad1c0686c Mon Sep 17 00:00:00 2001 +From cad23e6c5c7cd1c66c0652c75a9ffd039fa374c1 Mon Sep 17 00:00:00 2001 From: Ray Donnelly Date: Sun, 20 Aug 2017 00:22:22 +0100 -Subject: [PATCH 08/22] Darwin: Look in ${sysroot}/usr/{lib,include} if sysroot +Subject: [PATCH 09/31] Darwin: Look in ${sysroot}/usr/{lib,include} if sysroot is set --- @@ -9,7 +9,7 @@ Subject: [PATCH 08/22] Darwin: Look in ${sysroot}/usr/{lib,include} if sysroot 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/setup.py b/setup.py -index 6340669..021d5d1 100644 +index 6340669fff..021d5d142e 100644 --- a/setup.py +++ b/setup.py @@ -675,7 +675,13 @@ class PyBuildExt(build_ext): @@ -28,5 +28,5 @@ index 6340669..021d5d1 100644 self.inc_dirs = self.compiler.include_dirs + system_include_dirs else: -- -2.20.1 +2.28.0 diff --git a/recipe/patches/0009-runtime_library_dir_option-Use-1st-word-of-CC-as-com.patch b/recipe/patches/0010-runtime_library_dir_option-Use-1st-word-of-CC-as-com.patch similarity index 82% rename from recipe/patches/0009-runtime_library_dir_option-Use-1st-word-of-CC-as-com.patch rename to recipe/patches/0010-runtime_library_dir_option-Use-1st-word-of-CC-as-com.patch index 8ea40246f..b3d00a2f4 100644 --- a/recipe/patches/0009-runtime_library_dir_option-Use-1st-word-of-CC-as-com.patch +++ b/recipe/patches/0010-runtime_library_dir_option-Use-1st-word-of-CC-as-com.patch @@ -1,7 +1,7 @@ -From 768340fb29f75a91f3e08290f511c443a0d0fad1 Mon Sep 17 00:00:00 2001 +From da5da7473a0c3c9aeb2fcb1805fcc85b3219e513 Mon Sep 17 00:00:00 2001 From: Ray Donnelly Date: Thu, 5 Oct 2017 02:00:41 +0100 -Subject: [PATCH 09/22] runtime_library_dir_option: Use 1st word of CC as +Subject: [PATCH 10/31] runtime_library_dir_option: Use 1st word of CC as compiler Previous, 'CC' got passed to os.path.basename, so any paths in it after @@ -12,10 +12,10 @@ not get detected as gcc (or whatever it actually is). 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Lib/distutils/unixccompiler.py b/Lib/distutils/unixccompiler.py -index 3f05cf7..84a4217 100644 +index 0ca7c8466a..3147ba0f41 100644 --- a/Lib/distutils/unixccompiler.py +++ b/Lib/distutils/unixccompiler.py -@@ -232,7 +232,7 @@ class UnixCCompiler(CCompiler): +@@ -233,7 +233,7 @@ class UnixCCompiler(CCompiler): # this time, there's no way to determine this information from # the configuration data stored in the Python installation, so # we use this hack. @@ -25,5 +25,5 @@ index 3f05cf7..84a4217 100644 # MacOSX's linker doesn't understand the -R flag at all return "-L" + dir -- -2.20.1 +2.28.0 diff --git a/recipe/patches/0010-Win32-Do-not-download-externals.patch b/recipe/patches/0011-Win32-Do-not-download-externals.patch similarity index 80% rename from recipe/patches/0010-Win32-Do-not-download-externals.patch rename to recipe/patches/0011-Win32-Do-not-download-externals.patch index 08160ae72..5aee4029d 100644 --- a/recipe/patches/0010-Win32-Do-not-download-externals.patch +++ b/recipe/patches/0011-Win32-Do-not-download-externals.patch @@ -1,14 +1,14 @@ -From e2b1c75599b38512f238759051ede31deed8bfcc Mon Sep 17 00:00:00 2001 +From 36c395de0fea87e760c0be9799e478991ef829f6 Mon Sep 17 00:00:00 2001 From: Ray Donnelly Date: Thu, 7 Sep 2017 11:35:47 +0100 -Subject: [PATCH 10/22] Win32: Do not download externals +Subject: [PATCH 11/31] Win32: Do not download externals --- PCbuild/build.bat | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/PCbuild/build.bat b/PCbuild/build.bat -index e2f8f87..e57c2eb 100644 +index 7f9de1f5b3..a32ac895d9 100644 --- a/PCbuild/build.bat +++ b/PCbuild/build.bat @@ -95,7 +95,7 @@ if "%IncludeCTypes%"=="" set IncludeCTypes=true @@ -20,6 +20,6 @@ index e2f8f87..e57c2eb 100644 if "%do_pgo%" EQU "true" if "%platf%" EQU "x64" ( if "%PROCESSOR_ARCHITEW6432%" NEQ "AMD64" if "%PROCESSOR_ARCHITECTURE%" NEQ "AMD64" ( --- -2.20.1 - +-- +2.28.0 + diff --git a/recipe/patches/0011-Add-support-for-_CONDA_PYTHON_SYSCONFIGDATA_NAME-if-.patch b/recipe/patches/0012-Add-support-for-_CONDA_PYTHON_SYSCONFIGDATA_NAME-if-.patch similarity index 93% rename from recipe/patches/0011-Add-support-for-_CONDA_PYTHON_SYSCONFIGDATA_NAME-if-.patch rename to recipe/patches/0012-Add-support-for-_CONDA_PYTHON_SYSCONFIGDATA_NAME-if-.patch index 470cc8b5d..1f7096c13 100644 --- a/recipe/patches/0011-Add-support-for-_CONDA_PYTHON_SYSCONFIGDATA_NAME-if-.patch +++ b/recipe/patches/0012-Add-support-for-_CONDA_PYTHON_SYSCONFIGDATA_NAME-if-.patch @@ -1,7 +1,7 @@ -From 0b62d9fafca2656ab4914720d2b44da1b617ed6c Mon Sep 17 00:00:00 2001 +From d559f6256aa3dd0749abbb0a094f16385719e5bd Mon Sep 17 00:00:00 2001 From: Ray Donnelly Date: Sun, 3 Dec 2017 17:31:27 +0000 -Subject: [PATCH 11/22] Add support for _CONDA_PYTHON_SYSCONFIGDATA_NAME if +Subject: [PATCH 12/31] Add support for _CONDA_PYTHON_SYSCONFIGDATA_NAME if _PYTHON_SYSCONFIGDATA_NAME is not set and ignore {_CONDA,}_PYTHON_SYSCONFIGDATA_NAME if it does not exist @@ -14,7 +14,7 @@ manually). 2 files changed, 23 insertions(+), 13 deletions(-) diff --git a/Lib/distutils/sysconfig.py b/Lib/distutils/sysconfig.py -index b51629e..849f98f 100644 +index b51629eb94..849f98f929 100644 --- a/Lib/distutils/sysconfig.py +++ b/Lib/distutils/sysconfig.py @@ -433,11 +433,13 @@ def _init_posix(): @@ -37,7 +37,7 @@ index b51629e..849f98f 100644 build_time_vars = _temp.build_time_vars global _config_vars diff --git a/Lib/sysconfig.py b/Lib/sysconfig.py -index b9e2faf..1812a10 100644 +index b9e2fafbc0..1812a108e0 100644 --- a/Lib/sysconfig.py +++ b/Lib/sysconfig.py @@ -343,13 +343,21 @@ def get_makefile_filename(): @@ -79,5 +79,5 @@ index b9e2faf..1812a10 100644 build_time_vars = _temp.build_time_vars vars.update(build_time_vars) -- -2.20.1 +2.28.0 diff --git a/recipe/patches/0012-Fix-find_library-so-that-it-looks-in-sys.prefix-lib-.patch b/recipe/patches/0013-Fix-find_library-so-that-it-looks-in-sys.prefix-lib-.patch similarity index 93% rename from recipe/patches/0012-Fix-find_library-so-that-it-looks-in-sys.prefix-lib-.patch rename to recipe/patches/0013-Fix-find_library-so-that-it-looks-in-sys.prefix-lib-.patch index 14e0b063d..fb58358fe 100644 --- a/recipe/patches/0012-Fix-find_library-so-that-it-looks-in-sys.prefix-lib-.patch +++ b/recipe/patches/0013-Fix-find_library-so-that-it-looks-in-sys.prefix-lib-.patch @@ -1,7 +1,7 @@ -From b4d2ab3930441d3a9881c4a03f41a58d63e4bca6 Mon Sep 17 00:00:00 2001 +From 621100103c16c2a6accc3c408b13b46fface9d6a Mon Sep 17 00:00:00 2001 From: Ray Donnelly Date: Tue, 5 Dec 2017 22:47:59 +0000 -Subject: [PATCH 12/22] Fix find_library so that it looks in sys.prefix/lib +Subject: [PATCH 13/31] Fix find_library so that it looks in sys.prefix/lib first --- @@ -10,7 +10,7 @@ Subject: [PATCH 12/22] Fix find_library so that it looks in sys.prefix/lib 2 files changed, 28 insertions(+), 3 deletions(-) diff --git a/Lib/ctypes/macholib/dyld.py b/Lib/ctypes/macholib/dyld.py -index 9d86b05..9ab447c 100644 +index 9d86b05876..9ab447c0a1 100644 --- a/Lib/ctypes/macholib/dyld.py +++ b/Lib/ctypes/macholib/dyld.py @@ -88,6 +88,10 @@ def dyld_executable_path_search(name, executable_path=None): @@ -25,7 +25,7 @@ index 9d86b05..9ab447c 100644 yield os.path.join(executable_path, name[len('@executable_path/'):]) diff --git a/Lib/ctypes/util.py b/Lib/ctypes/util.py -index 97973bc..1340ad7 100644 +index 97973bce00..1340ad7c25 100644 --- a/Lib/ctypes/util.py +++ b/Lib/ctypes/util.py @@ -70,7 +70,8 @@ if os.name == "nt": @@ -72,5 +72,5 @@ index 97973bc..1340ad7 100644 ################################################################ # test code -- -2.20.1 +2.28.0 diff --git a/recipe/patches/0013-Disable-new-dtags-in-unixccompiler.py.patch b/recipe/patches/0014-Disable-new-dtags-in-unixccompiler.py.patch similarity index 91% rename from recipe/patches/0013-Disable-new-dtags-in-unixccompiler.py.patch rename to recipe/patches/0014-Disable-new-dtags-in-unixccompiler.py.patch index 7ba161ec6..a87627e95 100644 --- a/recipe/patches/0013-Disable-new-dtags-in-unixccompiler.py.patch +++ b/recipe/patches/0014-Disable-new-dtags-in-unixccompiler.py.patch @@ -1,7 +1,7 @@ -From e536f3463a15fb2991008476088f2886f114f58b Mon Sep 17 00:00:00 2001 +From 3d1116ba6b91b3b416077865cbcef148b0f1548d Mon Sep 17 00:00:00 2001 From: Ray Donnelly Date: Sun, 29 Apr 2018 16:10:42 +0100 -Subject: [PATCH 13/22] Disable new-dtags in unixccompiler.py +Subject: [PATCH 14/31] Disable new-dtags in unixccompiler.py They prevent isolation from system libraries and the HPC 'modules' system by giving precedence to LD_LIBRARY_PATH. We never want our libraries to @@ -21,7 +21,7 @@ itself, MSVC). 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/Lib/distutils/tests/test_unixccompiler.py b/Lib/distutils/tests/test_unixccompiler.py -index eef702c..2d8d61d 100644 +index eef702cf01..2d8d61df03 100644 --- a/Lib/distutils/tests/test_unixccompiler.py +++ b/Lib/distutils/tests/test_unixccompiler.py @@ -59,7 +59,7 @@ class UnixCCompilerTestCase(unittest.TestCase): @@ -43,10 +43,10 @@ index eef702c..2d8d61d 100644 # GCC GNULD with fully qualified configuration prefix # see #7617 diff --git a/Lib/distutils/unixccompiler.py b/Lib/distutils/unixccompiler.py -index 84a4217..12a9f77 100644 +index 3147ba0f41..489032238c 100644 --- a/Lib/distutils/unixccompiler.py +++ b/Lib/distutils/unixccompiler.py -@@ -248,12 +248,12 @@ class UnixCCompiler(CCompiler): +@@ -249,12 +249,12 @@ class UnixCCompiler(CCompiler): # use it anyway. Since distutils has always passed in # -Wl whenever gcc was used in the past it is probably # safest to keep doing so. @@ -63,5 +63,5 @@ index 84a4217..12a9f77 100644 # No idea how --enable-new-dtags would be passed on to # ld if this system was using GNU ld. Don't know if a -- -2.20.1 +2.28.0 diff --git a/recipe/patches/0014-Fix-cross-compilation-on-Debian-based-distros.patch b/recipe/patches/0015-Fix-cross-compilation-on-Debian-based-distros.patch similarity index 77% rename from recipe/patches/0014-Fix-cross-compilation-on-Debian-based-distros.patch rename to recipe/patches/0015-Fix-cross-compilation-on-Debian-based-distros.patch index b9081b471..5aa90a7fd 100644 --- a/recipe/patches/0014-Fix-cross-compilation-on-Debian-based-distros.patch +++ b/recipe/patches/0015-Fix-cross-compilation-on-Debian-based-distros.patch @@ -1,14 +1,14 @@ -From 4f953751cf0b93d359f693d0819681fcf600df81 Mon Sep 17 00:00:00 2001 +From 7e6e83c4b46b1a2d28d2291cc2e9378e85685203 Mon Sep 17 00:00:00 2001 From: Ray Donnelly Date: Sun, 26 Aug 2018 17:10:08 +0100 -Subject: [PATCH 14/22] Fix cross-compilation on Debian-based distros +Subject: [PATCH 15/31] Fix cross-compilation on Debian-based distros --- setup.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/setup.py b/setup.py -index 021d5d1..59d412d 100644 +index 021d5d142e..59d412da8f 100644 --- a/setup.py +++ b/setup.py @@ -654,7 +654,8 @@ class PyBuildExt(build_ext): @@ -22,5 +22,5 @@ index 021d5d1..59d412d 100644 def init_inc_lib_dirs(self): -- -2.20.1 +2.28.0 diff --git a/recipe/patches/0015-Disable-registry-lookup-unless-CONDA_PY_ALLOW_REG_PA.patch b/recipe/patches/0016-Disable-registry-lookup-unless-CONDA_PY_ALLOW_REG_PA.patch similarity index 87% rename from recipe/patches/0015-Disable-registry-lookup-unless-CONDA_PY_ALLOW_REG_PA.patch rename to recipe/patches/0016-Disable-registry-lookup-unless-CONDA_PY_ALLOW_REG_PA.patch index 15fd4c6e9..e1d30f41f 100644 --- a/recipe/patches/0015-Disable-registry-lookup-unless-CONDA_PY_ALLOW_REG_PA.patch +++ b/recipe/patches/0016-Disable-registry-lookup-unless-CONDA_PY_ALLOW_REG_PA.patch @@ -1,7 +1,7 @@ -From 11729724cd7ce5322ccf1d123e7f57d44c01ca95 Mon Sep 17 00:00:00 2001 +From 111249a5747939ca5b93b9f73c7523885cdf5199 Mon Sep 17 00:00:00 2001 From: Ray Donnelly Date: Sat, 27 Oct 2018 18:48:30 +0100 -Subject: [PATCH 15/22] Disable registry lookup unless CONDA_PY_ALLOW_REG_PATHS +Subject: [PATCH 16/31] Disable registry lookup unless CONDA_PY_ALLOW_REG_PATHS is not 0 --- @@ -9,7 +9,7 @@ Subject: [PATCH 15/22] Disable registry lookup unless CONDA_PY_ALLOW_REG_PATHS 1 file changed, 12 insertions(+), 2 deletions(-) diff --git a/PC/getpathp.c b/PC/getpathp.c -index cf20b9f..cbef237 100644 +index 8969fb554a..4a9e47ae45 100644 --- a/PC/getpathp.c +++ b/PC/getpathp.c @@ -822,9 +822,19 @@ calculate_module_search_path(PyCalculatePath *calculate, @@ -35,5 +35,5 @@ index cf20b9f..cbef237 100644 anything better to use! */ int skipdefault = (calculate->pythonpath_env != NULL || -- -2.20.1 +2.28.0 diff --git a/recipe/patches/0016-Unvendor-openssl.patch b/recipe/patches/0017-Unvendor-openssl.patch similarity index 90% rename from recipe/patches/0016-Unvendor-openssl.patch rename to recipe/patches/0017-Unvendor-openssl.patch index b60dc8f4d..077e3925c 100644 --- a/recipe/patches/0016-Unvendor-openssl.patch +++ b/recipe/patches/0017-Unvendor-openssl.patch @@ -1,7 +1,7 @@ -From f4eb2b6a0f9068e5665f0663cbf89f134af14f88 Mon Sep 17 00:00:00 2001 +From e9b1b01210f1433e09f14244038139b8cc94ac32 Mon Sep 17 00:00:00 2001 From: Nehal J Wani Date: Sat, 24 Nov 2018 20:38:02 -0600 -Subject: [PATCH 16/22] Unvendor openssl +Subject: [PATCH 17/31] Unvendor openssl --- PCbuild/_ssl.vcxproj | 3 --- @@ -13,7 +13,7 @@ Subject: [PATCH 16/22] Unvendor openssl 6 files changed, 10 insertions(+), 10 deletions(-) diff --git a/PCbuild/_ssl.vcxproj b/PCbuild/_ssl.vcxproj -index 7a514cf..37668e3 100644 +index 4907f49b66..b2c23d5e8c 100644 --- a/PCbuild/_ssl.vcxproj +++ b/PCbuild/_ssl.vcxproj @@ -99,9 +99,6 @@ @@ -27,7 +27,7 @@ index 7a514cf..37668e3 100644 diff --git a/PCbuild/_ssl.vcxproj.filters b/PCbuild/_ssl.vcxproj.filters -index dfb8b6a..4328fd6 100644 +index bd46b60984..1384aeff1f 100644 --- a/PCbuild/_ssl.vcxproj.filters +++ b/PCbuild/_ssl.vcxproj.filters @@ -9,9 +9,6 @@ @@ -41,7 +41,7 @@ index dfb8b6a..4328fd6 100644 diff --git a/PCbuild/openssl.props b/PCbuild/openssl.props -index b43c674..f2800b5 100644 +index a7e16793c7..af1350cae7 100644 --- a/PCbuild/openssl.props +++ b/PCbuild/openssl.props @@ -5,7 +5,7 @@ @@ -54,7 +54,7 @@ index b43c674..f2800b5 100644 diff --git a/PCbuild/python.props b/PCbuild/python.props -index 112b9f0..b4a757a 100644 +index 5f4926efa2..9c2838b162 100644 --- a/PCbuild/python.props +++ b/PCbuild/python.props @@ -62,9 +62,9 @@ @@ -71,7 +71,7 @@ index 112b9f0..b4a757a 100644 $(ExternalsDir)\zlib-1.2.11\ diff --git a/PCbuild/python.vcxproj b/PCbuild/python.vcxproj -index a689222..0899220 100644 +index 2094420a8d..ffb2673018 100644 --- a/PCbuild/python.vcxproj +++ b/PCbuild/python.vcxproj @@ -105,6 +105,9 @@ @@ -85,7 +85,7 @@ index a689222..0899220 100644 diff --git a/PCbuild/pythonw.vcxproj b/PCbuild/pythonw.vcxproj -index 871d250..0abd32b 100644 +index e7216dec3a..ab572d2020 100644 --- a/PCbuild/pythonw.vcxproj +++ b/PCbuild/pythonw.vcxproj @@ -97,6 +97,9 @@ @@ -98,6 +98,6 @@ index 871d250..0abd32b 100644 --- -2.20.1 - +-- +2.28.0 + diff --git a/recipe/patches/0017-Unvendor-sqlite3.patch b/recipe/patches/0018-Unvendor-sqlite3.patch similarity index 91% rename from recipe/patches/0017-Unvendor-sqlite3.patch rename to recipe/patches/0018-Unvendor-sqlite3.patch index 3c37d9356..e686d84e8 100644 --- a/recipe/patches/0017-Unvendor-sqlite3.patch +++ b/recipe/patches/0018-Unvendor-sqlite3.patch @@ -1,7 +1,7 @@ -From c0f9f4c2a95741f31339ba6a1c86256c6b540f09 Mon Sep 17 00:00:00 2001 +From 6205eba73608ebf2a8c7b53a6b7f8955ee75ba11 Mon Sep 17 00:00:00 2001 From: Nehal J Wani Date: Mon, 10 Dec 2018 12:22:37 -0600 -Subject: [PATCH 17/22] Unvendor sqlite3 +Subject: [PATCH 18/31] Unvendor sqlite3 --- PCbuild/_sqlite3.vcxproj | 9 ++++----- @@ -11,7 +11,7 @@ Subject: [PATCH 17/22] Unvendor sqlite3 4 files changed, 11 insertions(+), 14 deletions(-) diff --git a/PCbuild/_sqlite3.vcxproj b/PCbuild/_sqlite3.vcxproj -index 61df796..414a369 100644 +index 7e0062692b..3e7b2262e8 100644 --- a/PCbuild/_sqlite3.vcxproj +++ b/PCbuild/_sqlite3.vcxproj @@ -93,9 +93,12 @@ @@ -40,7 +40,7 @@ index 61df796..414a369 100644 diff --git a/PCbuild/pcbuild.sln b/PCbuild/pcbuild.sln -index 477a107..37f1867 100644 +index 6dc0139bc4..2f58d8ab24 100644 --- a/PCbuild/pcbuild.sln +++ b/PCbuild/pcbuild.sln @@ -57,8 +57,6 @@ Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "bdist_wininst", "..\PC\bdis @@ -53,20 +53,20 @@ index 477a107..37f1867 100644 EndProject Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "python3dll", "python3dll.vcxproj", "{885D4898-D08D-4091-9C40-C700CFE3FC5A}" diff --git a/PCbuild/python.props b/PCbuild/python.props -index b4a757a..caa3be4 100644 +index 9c2838b162..2360417748 100644 --- a/PCbuild/python.props +++ b/PCbuild/python.props @@ -56,7 +56,7 @@ $(EXTERNALS_DIR) $([System.IO.Path]::GetFullPath(`$(PySourcePath)externals`)) $(ExternalsDir)\ -- $(ExternalsDir)sqlite-3.31.1.0\ +- $(ExternalsDir)sqlite-3.32.3.0\ + $(SQLITE3_DIR)\ $(ExternalsDir)bzip2-1.0.6\ $(ExternalsDir)xz-5.2.2\ $(ExternalsDir)libffi\ diff --git a/PCbuild/sqlite3.vcxproj b/PCbuild/sqlite3.vcxproj -index 1a82a65..497071a 100644 +index 90b4d3108f..6deeafd422 100644 --- a/PCbuild/sqlite3.vcxproj +++ b/PCbuild/sqlite3.vcxproj @@ -88,12 +88,12 @@ @@ -88,6 +88,6 @@ index 1a82a65..497071a 100644 --- -2.20.1 - +-- +2.28.0 + diff --git a/recipe/patches/0018-venv-Revert-a-change-from-https-github.com-python-cp.patch b/recipe/patches/0019-venv-Revert-a-change-from-https-github.com-python-cp.patch similarity index 91% rename from recipe/patches/0018-venv-Revert-a-change-from-https-github.com-python-cp.patch rename to recipe/patches/0019-venv-Revert-a-change-from-https-github.com-python-cp.patch index 5b2df36ad..a4fd050aa 100644 --- a/recipe/patches/0018-venv-Revert-a-change-from-https-github.com-python-cp.patch +++ b/recipe/patches/0019-venv-Revert-a-change-from-https-github.com-python-cp.patch @@ -1,7 +1,7 @@ -From f0d869c89ae24f287d7232a7db63ad8fa6c5d882 Mon Sep 17 00:00:00 2001 +From 08a84c262cc5e9eb240f8bc78fc86925f6267d8f Mon Sep 17 00:00:00 2001 From: Ray Donnelly Date: Wed, 2 Jan 2019 21:38:48 +0000 -Subject: [PATCH 18/22] venv: Revert a change from +Subject: [PATCH 19/31] venv: Revert a change from https://github.com/python/cpython/commit/1c3de541e64f75046b20cdd27bada1557e550bcd https://bugs.python.org/issue35644 @@ -13,7 +13,7 @@ Also, on Anaconda Distribution, python.exe lives in sys.prefix. 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/Lib/venv/__init__.py b/Lib/venv/__init__.py -index caa7285..1a37080 100644 +index caa7285b8c..1a370800ff 100644 --- a/Lib/venv/__init__.py +++ b/Lib/venv/__init__.py @@ -211,7 +211,12 @@ class EnvBuilder: @@ -42,5 +42,5 @@ index caa7285..1a37080 100644 os.chmod(path, 0o755) for suffix in ('python', 'python3'): -- -2.20.1 +2.28.0 diff --git a/recipe/patches/0019-Win-Add-back-the-DLLSuffix-used-to-find-the-openssl-.patch b/recipe/patches/0020-Win-Add-back-the-DLLSuffix-used-to-find-the-openssl-.patch similarity index 79% rename from recipe/patches/0019-Win-Add-back-the-DLLSuffix-used-to-find-the-openssl-.patch rename to recipe/patches/0020-Win-Add-back-the-DLLSuffix-used-to-find-the-openssl-.patch index 3f7415a59..89815d785 100644 --- a/recipe/patches/0019-Win-Add-back-the-DLLSuffix-used-to-find-the-openssl-.patch +++ b/recipe/patches/0020-Win-Add-back-the-DLLSuffix-used-to-find-the-openssl-.patch @@ -1,7 +1,7 @@ -From a0cfa8a28af72acb87d04361d23101f0dd9972ee Mon Sep 17 00:00:00 2001 +From 0d6eb78f71ecd79c9d72e4012eea221784488bc4 Mon Sep 17 00:00:00 2001 From: Marius van Niekerk Date: Thu, 31 Oct 2019 16:46:21 -0400 -Subject: [PATCH 19/22] Win: Add back the DLLSuffix used to find the openssl +Subject: [PATCH 20/31] Win: Add back the DLLSuffix used to find the openssl dlls and debug files --- @@ -9,7 +9,7 @@ Subject: [PATCH 19/22] Win: Add back the DLLSuffix used to find the openssl 1 file changed, 1 insertion(+) diff --git a/PCbuild/openssl.props b/PCbuild/openssl.props -index f2800b5..a67cfec 100644 +index af1350cae7..eeb8677517 100644 --- a/PCbuild/openssl.props +++ b/PCbuild/openssl.props @@ -11,6 +11,7 @@ @@ -20,6 +20,6 @@ index f2800b5..a67cfec 100644 <_DLLSuffix Condition="$(Platform) == 'ARM'">$(_DLLSuffix)-arm <_DLLSuffix Condition="$(Platform) == 'ARM64'">$(_DLLSuffix)-arm64 --- -2.20.1 - +-- +2.28.0 + diff --git a/recipe/patches/0020-Use-ranlib-from-env-if-env-variable-is-set.patch b/recipe/patches/0021-Use-ranlib-from-env-if-env-variable-is-set.patch similarity index 78% rename from recipe/patches/0020-Use-ranlib-from-env-if-env-variable-is-set.patch rename to recipe/patches/0021-Use-ranlib-from-env-if-env-variable-is-set.patch index 7797ec66f..5b87e26ab 100644 --- a/recipe/patches/0020-Use-ranlib-from-env-if-env-variable-is-set.patch +++ b/recipe/patches/0021-Use-ranlib-from-env-if-env-variable-is-set.patch @@ -1,14 +1,14 @@ -From d051232264fb5872137a68244c48540e282523c5 Mon Sep 17 00:00:00 2001 +From e842f468342d1f0f37ff0b488f609bfa48058f71 Mon Sep 17 00:00:00 2001 From: Isuru Fernando Date: Sun, 3 Nov 2019 15:09:45 -0600 -Subject: [PATCH 20/22] Use ranlib from env if env variable is set +Subject: [PATCH 21/31] Use ranlib from env if env variable is set --- Lib/distutils/sysconfig.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/Lib/distutils/sysconfig.py b/Lib/distutils/sysconfig.py -index 849f98f..ab9b195 100644 +index 849f98f929..ab9b195756 100644 --- a/Lib/distutils/sysconfig.py +++ b/Lib/distutils/sysconfig.py @@ -234,6 +234,9 @@ def customize_compiler(compiler): @@ -22,5 +22,5 @@ index 849f98f..ab9b195 100644 -- -2.20.1 +2.28.0 diff --git a/recipe/patches/0021-roll-back-2e33ecd-for-py_compile.main.patch b/recipe/patches/0021-roll-back-2e33ecd-for-py_compile.main.patch deleted file mode 100644 index 7919849b4..000000000 --- a/recipe/patches/0021-roll-back-2e33ecd-for-py_compile.main.patch +++ /dev/null @@ -1,41 +0,0 @@ -From 4dade435e7bb8fb52e804e13d7e147fac492c743 Mon Sep 17 00:00:00 2001 -From: Duncan Macleod -Date: Mon, 11 Nov 2019 14:30:40 +0000 -Subject: [PATCH 21/22] roll-back 2e33ecd for py_compile.main - ---- - Lib/py_compile.py | 9 +++------ - 1 file changed, 3 insertions(+), 6 deletions(-) - -diff --git a/Lib/py_compile.py b/Lib/py_compile.py -index 2173689..a81f493 100644 ---- a/Lib/py_compile.py -+++ b/Lib/py_compile.py -@@ -197,12 +197,10 @@ def main(args=None): - compile(filename, doraise=True) - except PyCompileError as error: - rv = 1 -- if quiet < 2: -- sys.stderr.write("%s\n" % error.msg) -+ sys.stderr.write("%s\n" % error.msg) - except OSError as error: - rv = 1 -- if quiet < 2: -- sys.stderr.write("%s\n" % error) -+ sys.stderr.write("%s\n" % error) - else: - for filename in args: - try: -@@ -210,8 +208,7 @@ def main(args=None): - except PyCompileError as error: - # return value to indicate at least one failure - rv = 1 -- if quiet < 2: -- sys.stderr.write("%s\n" % error.msg) -+ sys.stderr.write("%s\n" % error.msg) - return rv - - if __name__ == "__main__": --- -2.20.1 - diff --git a/recipe/patches/0022-Add-CondaEcosystemModifyDllSearchPath.patch b/recipe/patches/0022-Add-CondaEcosystemModifyDllSearchPath.patch index 23ec09df2..6e5f8faab 100644 --- a/recipe/patches/0022-Add-CondaEcosystemModifyDllSearchPath.patch +++ b/recipe/patches/0022-Add-CondaEcosystemModifyDllSearchPath.patch @@ -1,7 +1,7 @@ -From 45076be3111fa0c00b8e868bdb7a4224edf8c6b0 Mon Sep 17 00:00:00 2001 +From 6f933f42503a70a9b7481d4ee0d19ac5657a4f30 Mon Sep 17 00:00:00 2001 From: Ray Donnelly Date: Tue, 24 Dec 2019 18:37:17 +0100 -Subject: [PATCH 22/22] Add CondaEcosystemModifyDllSearchPath() +Subject: [PATCH 22/31] Add CondaEcosystemModifyDllSearchPath() This changes the DLL search order so that C:\Windows\System32 does not get searched in before entries in PATH. @@ -15,7 +15,7 @@ Updated a bit to include other directories. 2 files changed, 389 insertions(+), 2 deletions(-) diff --git a/Modules/main.c b/Modules/main.c -index 5150587..6e75e54 100644 +index 5150587a75..6e75e54dfe 100644 --- a/Modules/main.c +++ b/Modules/main.c @@ -20,6 +20,10 @@ @@ -428,7 +428,7 @@ index 5150587..6e75e54 100644 if (_PyStatus_IS_EXIT(status)) { pymain_free(); diff --git a/Python/dynload_win.c b/Python/dynload_win.c -index 4896c6d..cf5cb5c 100644 +index 4896c6dc8c..cf5cb5cf78 100644 --- a/Python/dynload_win.c +++ b/Python/dynload_win.c @@ -199,10 +199,13 @@ dl_funcptr _PyImport_FindSharedFuncptrWindows(const char *prefix, @@ -448,5 +448,5 @@ index 4896c6d..cf5cb5c 100644 #if HAVE_SXS _Py_DeactivateActCtx(cookie); -- -2.20.1 +2.28.0 diff --git a/recipe/patches/0026-Revert-part-of-https-bugs.python.org-issue33895-http.patch b/recipe/patches/0023-Revert-part-of-https-bugs.python.org-issue33895-http.patch similarity index 90% rename from recipe/patches/0026-Revert-part-of-https-bugs.python.org-issue33895-http.patch rename to recipe/patches/0023-Revert-part-of-https-bugs.python.org-issue33895-http.patch index 61a243e3a..c48d7dfb6 100644 --- a/recipe/patches/0026-Revert-part-of-https-bugs.python.org-issue33895-http.patch +++ b/recipe/patches/0023-Revert-part-of-https-bugs.python.org-issue33895-http.patch @@ -1,7 +1,7 @@ -From 24b3965a20114878dd6c31b07f4386074aa97fb4 Mon Sep 17 00:00:00 2001 +From 4b64f013c9d9e3445deb2ebde6958ece3c54e040 Mon Sep 17 00:00:00 2001 From: Ray Donnelly Date: Tue, 18 Feb 2020 17:38:32 +0100 -Subject: [PATCH 26/26] Revert part of https://bugs.python.org/issue33895 +Subject: [PATCH 23/31] Revert part of https://bugs.python.org/issue33895 https://github.com/python/cpython/commit/4860f01ac0f07cdc8fc0cc27c33f5a64e5cfec9f LIEF crashes because Python code gets called from its static initialization code (CreateModule2 gets called, more?) @@ -22,10 +22,10 @@ more debuggable which should pay off in future. 1 file changed, 17 insertions(+), 4 deletions(-) diff --git a/Python/dynload_win.c b/Python/dynload_win.c -index 56d8913455..dd5b200861 100644 +index cf5cb5cf78..9a8ffcf3f9 100644 --- a/Python/dynload_win.c +++ b/Python/dynload_win.c -@@ -190,6 +190,11 @@ dl_funcptr _PyImport_FindSharedFuncptrWindows(const char *prefix, +@@ -188,6 +188,11 @@ dl_funcptr _PyImport_FindSharedFuncptrWindows(const char *prefix, #if HAVE_SXS ULONG_PTR cookie = 0; #endif @@ -37,7 +37,7 @@ index 56d8913455..dd5b200861 100644 /* Don't display a message box when Python can't load a DLL */ old_mode = SetErrorMode(SEM_FAILCRITICALERRORS); -@@ -202,13 +207,21 @@ dl_funcptr _PyImport_FindSharedFuncptrWindows(const char *prefix, +@@ -200,13 +205,21 @@ dl_funcptr _PyImport_FindSharedFuncptrWindows(const char *prefix, AddDllDirectory function. We add SEARCH_DLL_LOAD_DIR to ensure DLLs adjacent to the PYD are preferred. */ /* This resyncs values in PATH to AddDllDirectory() */ @@ -64,5 +64,5 @@ index 56d8913455..dd5b200861 100644 _Py_DeactivateActCtx(cookie); #endif -- -2.23.0 +2.28.0 diff --git a/recipe/patches/0027-cross-compile-darwin.patch b/recipe/patches/0024-cross-compile-darwin.patch.patch similarity index 72% rename from recipe/patches/0027-cross-compile-darwin.patch rename to recipe/patches/0024-cross-compile-darwin.patch.patch index 3212aaf1d..06fab6b5a 100644 --- a/recipe/patches/0027-cross-compile-darwin.patch +++ b/recipe/patches/0024-cross-compile-darwin.patch.patch @@ -1,15 +1,46 @@ ---- a/configure 2020-08-14 02:59:05.841967550 +0000 -+++ b/configure 2020-08-14 03:02:01.839782466 +0000 -@@ -3312,6 +3312,8 @@ - { $as_echo "$as_me:${as_lineno-$LINENO}: result: \"$MACHDEP\"" >&5 +From 9ecbb4d88857c60adc721e9c50ebb94d8631b858 Mon Sep 17 00:00:00 2001 +From: Filipe Fernandes +Date: Wed, 7 Oct 2020 09:59:09 -0300 +Subject: [PATCH 24/31] cross-compile-darwin.patch + +--- + Lib/platform.py | 7 ++++++- + configure | 8 ++++++-- + setup.py | 2 +- + 3 files changed, 13 insertions(+), 4 deletions(-) + +diff --git a/Lib/platform.py b/Lib/platform.py +index 2df9c1ef92..22e727fce8 100755 +--- a/Lib/platform.py ++++ b/Lib/platform.py +@@ -406,7 +406,12 @@ def win32_ver(release='', version='', csd='', ptype=''): + def _mac_ver_xml(): + fn = '/System/Library/CoreServices/SystemVersion.plist' + if not os.path.exists(fn): +- return None ++ if 'SDKROOT' in os.environ: ++ fn = os.environ['SDKROOT'] + fn ++ if not os.path.exists(fn): ++ return None ++ else: ++ return None + + try: + import plistlib +diff --git a/configure b/configure +index f3979f16be..bd4b994e39 100755 +--- a/configure ++++ b/configure +@@ -3313,6 +3313,8 @@ fi $as_echo "\"$MACHDEP\"" >&6; } + +if test -z "${_PYTHON_HOST_PLATFORM}" +then if test "$cross_compiling" = yes; then case "$host" in *-*-linux*) -@@ -3336,6 +3338,7 @@ +@@ -3337,6 +3339,7 @@ if test "$cross_compiling" = yes; then esac _PYTHON_HOST_PLATFORM="$MACHDEP${_host_cpu:+-$_host_cpu}" fi @@ -17,7 +48,7 @@ # Some systems cannot stand _XOPEN_SOURCE being defined at all; they # disable features if it is defined, without any means to access these -@@ -6172,7 +6175,7 @@ +@@ -6173,7 +6176,7 @@ fi if test "$cross_compiling" = yes; then case "$READELF" in readelf|:) @@ -26,7 +57,7 @@ ;; esac fi -@@ -9244,7 +9247,7 @@ +@@ -9245,7 +9248,7 @@ rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ conftest.$ac_objext conftest.beam conftest.$ac_ext fi @@ -35,7 +66,7 @@ if test "${ac_osx_32bit}" = "yes"; then case `/usr/bin/arch` in i386) -@@ -9271,6 +9274,7 @@ +@@ -9272,6 +9275,7 @@ fi esac fi @@ -43,26 +74,8 @@ LIBTOOL_CRUFT=$LIBTOOL_CRUFT" -lSystem -lSystemStubs -arch_only ${MACOSX_DEFAULT_ARCH}" LIBTOOL_CRUFT=$LIBTOOL_CRUFT' -install_name $(PYTHONFRAMEWORKINSTALLDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)' -diff --git a/Lib/platform.py b/Lib/platform.py -index 994d892c5e..11d0b50921 100755 ---- a/Lib/platform.py -+++ b/Lib/platform.py -@@ -406,7 +406,12 @@ def win32_ver(release='', version='', csd='', ptype=''): - def _mac_ver_xml(): - fn = '/System/Library/CoreServices/SystemVersion.plist' - if not os.path.exists(fn): -- return None -+ if 'SDKROOT' in os.environ: -+ fn = os.environ['SDKROOT'] + fn -+ if not os.path.exists(fn): -+ return None -+ else: -+ return None - - try: - import plistlib diff --git a/setup.py b/setup.py -index 59d412da8f..85e1d5dd1a 100644 +index 59d412da8f..e3c97a6466 100644 --- a/setup.py +++ b/setup.py @@ -42,7 +42,7 @@ CROSS_COMPILING = ("_PYTHON_HOST_PLATFORM" in os.environ) @@ -74,3 +87,6 @@ index 59d412da8f..85e1d5dd1a 100644 AIX = (HOST_PLATFORM.startswith('aix')) VXWORKS = ('vxworks' in HOST_PLATFORM) +-- +2.28.0 + diff --git a/recipe/patches/gh21114.patch b/recipe/patches/0025-BPO-41101-Support-arm64-in-Mac-Tools-pythonw.patch similarity index 84% rename from recipe/patches/gh21114.patch rename to recipe/patches/0025-BPO-41101-Support-arm64-in-Mac-Tools-pythonw.patch index d0e918827..b34ed4d8a 100644 --- a/recipe/patches/gh21114.patch +++ b/recipe/patches/0025-BPO-41101-Support-arm64-in-Mac-Tools-pythonw.patch @@ -1,7 +1,7 @@ -From 2add6fb11b0eddf459c2e79ec86376a8adb00cfc Mon Sep 17 00:00:00 2001 +From e572ced24d46b4ca70310ee15eb3120ac5225f18 Mon Sep 17 00:00:00 2001 From: Ronald Oussoren Date: Wed, 24 Jun 2020 14:22:16 +0200 -Subject: [PATCH] BPO-41101: Support "arm64" in Mac/Tools/pythonw +Subject: [PATCH 25/31] BPO-41101: Support "arm64" in Mac/Tools/pythonw --- Mac/Tools/pythonw.c | 6 ++++++ @@ -10,7 +10,7 @@ Subject: [PATCH] BPO-41101: Support "arm64" in Mac/Tools/pythonw create mode 100644 Misc/NEWS.d/next/macOS/2020-06-24-14-21-17.bpo-41101.z9hCsP.rst diff --git a/Mac/Tools/pythonw.c b/Mac/Tools/pythonw.c -index 1d2db383f943c..21e79665442b6 100644 +index c8bd3ba8d6..ae4c262129 100644 --- a/Mac/Tools/pythonw.c +++ b/Mac/Tools/pythonw.c @@ -119,10 +119,16 @@ setup_spawnattr(posix_spawnattr_t* spawnattr) @@ -32,9 +32,12 @@ index 1d2db383f943c..21e79665442b6 100644 if (posix_spawnattr_setbinpref_np(spawnattr, count, diff --git a/Misc/NEWS.d/next/macOS/2020-06-24-14-21-17.bpo-41101.z9hCsP.rst b/Misc/NEWS.d/next/macOS/2020-06-24-14-21-17.bpo-41101.z9hCsP.rst new file mode 100644 -index 0000000000000..f66863db00c06 +index 0000000000..f66863db00 --- /dev/null +++ b/Misc/NEWS.d/next/macOS/2020-06-24-14-21-17.bpo-41101.z9hCsP.rst @@ -0,0 +1,2 @@ +Support the new "arm64" architecture for macOS in the pythonw executable in +framework builds. +-- +2.28.0 + diff --git a/recipe/patches/0026-fix-_decimal-for-arm64-Mac-OS.patch b/recipe/patches/0026-fix-_decimal-for-arm64-Mac-OS.patch new file mode 100644 index 000000000..eef96c1e2 --- /dev/null +++ b/recipe/patches/0026-fix-_decimal-for-arm64-Mac-OS.patch @@ -0,0 +1,27 @@ +From cd8f1cf2d3399265e6d254d162e4d5dab00dbfae Mon Sep 17 00:00:00 2001 +From: Lawrence D'Anna +Date: Mon, 29 Jun 2020 16:05:44 -0700 +Subject: [PATCH 26/31] fix _decimal for arm64 Mac OS + +add __arm64__ to the allowable Mac OS arches in mpdecimal.h +--- + Modules/_decimal/libmpdec/mpdecimal.h | 3 +++ + 1 file changed, 3 insertions(+) + +diff --git a/Modules/_decimal/libmpdec/mpdecimal.h b/Modules/_decimal/libmpdec/mpdecimal.h +index a67dd9bc12..3e9c8185c3 100644 +--- a/Modules/_decimal/libmpdec/mpdecimal.h ++++ b/Modules/_decimal/libmpdec/mpdecimal.h +@@ -135,6 +135,9 @@ const char *mpd_version(void); + #elif defined(__x86_64__) + #define CONFIG_64 + #define ASM ++ #elif defined(__arm64__) ++ #define CONFIG_64 ++ #define ANSI + #else + #error "unknown architecture for universal build." + #endif +-- +2.28.0 + diff --git a/recipe/patches/0027-Added-by-blurb_it.patch b/recipe/patches/0027-Added-by-blurb_it.patch new file mode 100644 index 000000000..9a1688eef --- /dev/null +++ b/recipe/patches/0027-Added-by-blurb_it.patch @@ -0,0 +1,25 @@ +From 320f6ec38e3620aef8c91ca5c77bc291c3029ead Mon Sep 17 00:00:00 2001 +From: "blurb-it[bot]" <43283697+blurb-it[bot]@users.noreply.github.com> +Date: Tue, 30 Jun 2020 04:44:30 +0000 +Subject: [PATCH 27/31] =?UTF-8?q?=F0=9F=93=9C=F0=9F=A4=96=20Added=20by=20b?= + =?UTF-8?q?lurb=5Fit.?= +MIME-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit + +--- + .../Core and Builtins/2020-06-30-04-44-29.bpo-41100.PJwA6F.rst | 1 + + 1 file changed, 1 insertion(+) + create mode 100644 Misc/NEWS.d/next/Core and Builtins/2020-06-30-04-44-29.bpo-41100.PJwA6F.rst + +diff --git a/Misc/NEWS.d/next/Core and Builtins/2020-06-30-04-44-29.bpo-41100.PJwA6F.rst b/Misc/NEWS.d/next/Core and Builtins/2020-06-30-04-44-29.bpo-41100.PJwA6F.rst +new file mode 100644 +index 0000000000..d6176d69f0 +--- /dev/null ++++ b/Misc/NEWS.d/next/Core and Builtins/2020-06-30-04-44-29.bpo-41100.PJwA6F.rst +@@ -0,0 +1 @@ ++add arm64 to the allowable Mac OS arches in mpdecimal.h +\ No newline at end of file +-- +2.28.0 + diff --git a/recipe/patches/0028-ctypes-check-_dyld_shared_cache_contains_path-in-fin.patch b/recipe/patches/0028-ctypes-check-_dyld_shared_cache_contains_path-in-fin.patch new file mode 100644 index 000000000..3666b0b8d --- /dev/null +++ b/recipe/patches/0028-ctypes-check-_dyld_shared_cache_contains_path-in-fin.patch @@ -0,0 +1,122 @@ +From 3f4c559bb58c06024b6559216f1137485747b3b5 Mon Sep 17 00:00:00 2001 +From: Lawrence D'Anna +Date: Tue, 30 Jun 2020 10:37:20 -0700 +Subject: [PATCH 28/31] ctypes: check _dyld_shared_cache_contains_path in + find_library + +System libraries in Mac OS 11 may be present only in the shared cache, +with the actual mach-o file not present in the corresponding location +on the filesystem. ctypes.util.find_library should check the +shared cache in order to behave consistently across Mac OS 10.15 +and earlier and Mac OS 11.0 and later. +--- + Lib/ctypes/macholib/dyld.py | 12 ++++++ + .../2020-06-30-18-24-28.bpo-41100._QkcD_.rst | 1 + + Modules/_ctypes/callproc.c | 38 +++++++++++++++++++ + 3 files changed, 51 insertions(+) + create mode 100644 Misc/NEWS.d/next/Core and Builtins/2020-06-30-18-24-28.bpo-41100._QkcD_.rst + +diff --git a/Lib/ctypes/macholib/dyld.py b/Lib/ctypes/macholib/dyld.py +index 9ab447c0a1..bf0e8e8dee 100644 +--- a/Lib/ctypes/macholib/dyld.py ++++ b/Lib/ctypes/macholib/dyld.py +@@ -7,6 +7,12 @@ from ctypes.macholib.framework import framework_info + from ctypes.macholib.dylib import dylib_info + from itertools import * + ++try: ++ from _ctypes import _dyld_shared_cache_contains_path ++except ImportError: ++ def _dyld_shared_cache_contains_path(*args): ++ raise NotImplementedError ++ + __all__ = [ + 'dyld_find', 'framework_find', + 'framework_info', 'dylib_info', +@@ -128,6 +134,12 @@ def dyld_find(name, executable_path=None, env=None): + ), env): + if os.path.isfile(path): + return path ++ try: ++ if _dyld_shared_cache_contains_path(path): ++ return path ++ except NotImplementedError: ++ pass ++ + raise ValueError("dylib %s could not be found" % (name,)) + + def framework_find(fn, executable_path=None, env=None): +diff --git a/Misc/NEWS.d/next/Core and Builtins/2020-06-30-18-24-28.bpo-41100._QkcD_.rst b/Misc/NEWS.d/next/Core and Builtins/2020-06-30-18-24-28.bpo-41100._QkcD_.rst +new file mode 100644 +index 0000000000..dbb732432c +--- /dev/null ++++ b/Misc/NEWS.d/next/Core and Builtins/2020-06-30-18-24-28.bpo-41100._QkcD_.rst +@@ -0,0 +1 @@ ++ctypes: Mac OS 11: check for system libraries in the shared cache +\ No newline at end of file +diff --git a/Modules/_ctypes/callproc.c b/Modules/_ctypes/callproc.c +index a9b8675cd9..a7a99fff25 100644 +--- a/Modules/_ctypes/callproc.c ++++ b/Modules/_ctypes/callproc.c +@@ -64,6 +64,10 @@ + #include "ctypes_dlfcn.h" + #endif + ++#ifdef __APPLE__ ++extern bool _dyld_shared_cache_contains_path(const char* path) __attribute__((weak_import)); ++#endif ++ + #ifdef MS_WIN32 + #include + #endif +@@ -1399,6 +1403,37 @@ copy_com_pointer(PyObject *self, PyObject *args) + } + #else + ++#ifdef __APPLE__ ++static PyObject *py_dyld_shared_cache_contains_path(PyObject *self, PyObject *args) ++{ ++ PyObject *name, *name2; ++ char *name_str; ++ ++ if (_dyld_shared_cache_contains_path == NULL) { ++ PyErr_SetString(PyExc_NotImplementedError, "_dyld_shared_cache_contains_path symbol is missing"); ++ return NULL; ++ } ++ ++ if (!PyArg_ParseTuple(args, "O", &name)) ++ return NULL; ++ ++ if (name == Py_None) ++ Py_RETURN_FALSE; ++ ++ if (PyUnicode_FSConverter(name, &name2) == 0) ++ return NULL; ++ if (PyBytes_Check(name2)) ++ name_str = PyBytes_AS_STRING(name2); ++ else ++ name_str = PyByteArray_AS_STRING(name2); ++ ++ if(_dyld_shared_cache_contains_path(name_str)) ++ Py_RETURN_TRUE; ++ else ++ Py_RETURN_FALSE; ++} ++#endif ++ + static PyObject *py_dl_open(PyObject *self, PyObject *args) + { + PyObject *name, *name2; +@@ -1910,6 +1945,9 @@ PyMethodDef _ctypes_module_methods[] = { + "dlopen(name, flag={RTLD_GLOBAL|RTLD_LOCAL}) open a shared library"}, + {"dlclose", py_dl_close, METH_VARARGS, "dlclose a library"}, + {"dlsym", py_dl_sym, METH_VARARGS, "find symbol in shared library"}, ++#endif ++#ifdef __APPLE__ ++ {"_dyld_shared_cache_contains_path", py_dyld_shared_cache_contains_path, METH_VARARGS, "check if path is in the shared cache"}, + #endif + {"alignment", align_func, METH_O, alignment_doc}, + {"sizeof", sizeof_func, METH_O, sizeof_doc}, +-- +2.28.0 + diff --git a/recipe/patches/0029-fix-test_macholib-for-Mac-OS-11.patch b/recipe/patches/0029-fix-test_macholib-for-Mac-OS-11.patch new file mode 100644 index 000000000..8b0b4956e --- /dev/null +++ b/recipe/patches/0029-fix-test_macholib-for-Mac-OS-11.patch @@ -0,0 +1,45 @@ +From 785b382602efd54f313e0b245799aba9ff0ae07f Mon Sep 17 00:00:00 2001 +From: Lawrence D'Anna +Date: Fri, 17 Jul 2020 16:24:07 -0700 +Subject: [PATCH 29/31] fix test_macholib for Mac OS 11 + +--- + Lib/ctypes/test/test_macholib.py | 15 ++++++++++----- + 1 file changed, 10 insertions(+), 5 deletions(-) + +diff --git a/Lib/ctypes/test/test_macholib.py b/Lib/ctypes/test/test_macholib.py +index 6b3526951a..ed04479abd 100644 +--- a/Lib/ctypes/test/test_macholib.py ++++ b/Lib/ctypes/test/test_macholib.py +@@ -46,18 +46,23 @@ class MachOTest(unittest.TestCase): + @unittest.skipUnless(sys.platform == "darwin", 'OSX-specific test') + def test_find(self): + +- self.assertEqual(find_lib('pthread'), +- '/usr/lib/libSystem.B.dylib') ++ # On Mac OS 11, system dylibs are only present in the shared cache, ++ # so symlinks like libpthread.dylib -> libSystem.B.dylib will not ++ # be resolved by dyld_find ++ ++ self.assertIn(find_lib('pthread'), ++ ('/usr/lib/libSystem.B.dylib', '/usr/lib/libpthread.dylib')) + + result = find_lib('z') + # Issue #21093: dyld default search path includes $HOME/lib and + # /usr/local/lib before /usr/lib, which caused test failures if + # a local copy of libz exists in one of them. Now ignore the head + # of the path. +- self.assertRegex(result, r".*/lib/libz\..*.*\.dylib") ++ self.assertRegex(result, r".*/lib/libz.*\.dylib") + +- self.assertEqual(find_lib('IOKit'), +- '/System/Library/Frameworks/IOKit.framework/Versions/A/IOKit') ++ self.assertIn(find_lib('IOKit'), ++ ('/System/Library/Frameworks/IOKit.framework/Versions/A/IOKit', ++ '/System/Library/Frameworks/IOKit.framework/IOKit')) + + if __name__ == "__main__": + unittest.main() +-- +2.28.0 + diff --git a/recipe/patches/0030-Xcode-12-Beta-4-declares-_dyld_shared_cache_contains.patch b/recipe/patches/0030-Xcode-12-Beta-4-declares-_dyld_shared_cache_contains.patch new file mode 100644 index 000000000..a8d03f205 --- /dev/null +++ b/recipe/patches/0030-Xcode-12-Beta-4-declares-_dyld_shared_cache_contains.patch @@ -0,0 +1,145 @@ +From c44b6c384633ca51fd3b7ad888de063dc383c89a Mon Sep 17 00:00:00 2001 +From: Lawrence D'Anna +Date: Wed, 5 Aug 2020 15:20:36 -0700 +Subject: [PATCH 30/31] Xcode 12 Beta 4 declares + _dyld_shared_cache_contains_path + +--- + Modules/_ctypes/callproc.c | 49 +++++++++++++++++++------------------- + configure | 9 +++++++ + configure.ac | 4 ++++ + pyconfig.h.in | 3 +++ + 4 files changed, 40 insertions(+), 25 deletions(-) + +diff --git a/Modules/_ctypes/callproc.c b/Modules/_ctypes/callproc.c +index a7a99fff25..4a296c8b84 100644 +--- a/Modules/_ctypes/callproc.c ++++ b/Modules/_ctypes/callproc.c +@@ -64,8 +64,8 @@ + #include "ctypes_dlfcn.h" + #endif + +-#ifdef __APPLE__ +-extern bool _dyld_shared_cache_contains_path(const char* path) __attribute__((weak_import)); ++#if __APPLE__ && HAVE_DYLD_SHARED_CACHE_CONTAINS_PATH ++#include + #endif + + #ifdef MS_WIN32 +@@ -1403,34 +1403,33 @@ copy_com_pointer(PyObject *self, PyObject *args) + } + #else + +-#ifdef __APPLE__ ++#if __APPLE__ && HAVE_DYLD_SHARED_CACHE_CONTAINS_PATH + static PyObject *py_dyld_shared_cache_contains_path(PyObject *self, PyObject *args) + { +- PyObject *name, *name2; +- char *name_str; +- +- if (_dyld_shared_cache_contains_path == NULL) { +- PyErr_SetString(PyExc_NotImplementedError, "_dyld_shared_cache_contains_path symbol is missing"); +- return NULL; +- } ++ if (__builtin_available(macos 11, ios 14, watchos 7, tvos 14, *)) { ++ PyObject *name, *name2; ++ char *name_str; ++ if (!PyArg_ParseTuple(args, "O", &name)) ++ return NULL; + +- if (!PyArg_ParseTuple(args, "O", &name)) +- return NULL; ++ if (name == Py_None) ++ Py_RETURN_FALSE; + +- if (name == Py_None) +- Py_RETURN_FALSE; ++ if (PyUnicode_FSConverter(name, &name2) == 0) ++ return NULL; ++ if (PyBytes_Check(name2)) ++ name_str = PyBytes_AS_STRING(name2); ++ else ++ name_str = PyByteArray_AS_STRING(name2); + +- if (PyUnicode_FSConverter(name, &name2) == 0) ++ if(_dyld_shared_cache_contains_path(name_str)) ++ Py_RETURN_TRUE; ++ else ++ Py_RETURN_FALSE; ++ } else { ++ PyErr_SetString(PyExc_NotImplementedError, "_dyld_shared_cache_contains_path symbol is missing"); + return NULL; +- if (PyBytes_Check(name2)) +- name_str = PyBytes_AS_STRING(name2); +- else +- name_str = PyByteArray_AS_STRING(name2); +- +- if(_dyld_shared_cache_contains_path(name_str)) +- Py_RETURN_TRUE; +- else +- Py_RETURN_FALSE; ++ } + } + #endif + +@@ -1946,7 +1945,7 @@ PyMethodDef _ctypes_module_methods[] = { + {"dlclose", py_dl_close, METH_VARARGS, "dlclose a library"}, + {"dlsym", py_dl_sym, METH_VARARGS, "find symbol in shared library"}, + #endif +-#ifdef __APPLE__ ++#if __APPLE__ && HAVE_DYLD_SHARED_CACHE_CONTAINS_PATH + {"_dyld_shared_cache_contains_path", py_dyld_shared_cache_contains_path, METH_VARARGS, "check if path is in the shared cache"}, + #endif + {"alignment", align_func, METH_O, alignment_doc}, +diff --git a/configure b/configure +index bd4b994e39..23e81243ef 100755 +--- a/configure ++++ b/configure +@@ -11454,6 +11454,15 @@ fi + done + + ++ac_fn_c_check_decl "$LINENO" "_dyld_shared_cache_contains_path" "ac_cv_have_decl__dyld_shared_cache_contains_path" "#include ++" ++if test "x$ac_cv_have_decl__dyld_shared_cache_contains_path" = xyes; then : ++ ++$as_echo "#define HAVE_DYLD_SHARED_CACHE_CONTAINS_PATH 1" >>confdefs.h ++ ++fi ++ ++ + # DYNLOADFILE specifies which dynload_*.o file we will use for dynamic + # loading of modules. + +diff --git a/configure.ac b/configure.ac +index 7c688668c1..99deb8c0f7 100644 +--- a/configure.ac ++++ b/configure.ac +@@ -3513,6 +3513,10 @@ DLINCLDIR=. + # platforms, such as AIX, have dlopen(), but don't want to use it. + AC_CHECK_FUNCS(dlopen) + ++AC_CHECK_DECL(_dyld_shared_cache_contains_path, ++ AC_DEFINE(HAVE_DYLD_SHARED_CACHE_CONTAINS_PATH, 1, Define if you have the '_dyld_shared_cache_contains_path' function), ++ [], [#include ]) ++ + # DYNLOADFILE specifies which dynload_*.o file we will use for dynamic + # loading of modules. + AC_SUBST(DYNLOADFILE) +diff --git a/pyconfig.h.in b/pyconfig.h.in +index 4263a712c3..96a74eff55 100644 +--- a/pyconfig.h.in ++++ b/pyconfig.h.in +@@ -281,6 +281,9 @@ + /* Define to 1 if you have the `dup3' function. */ + #undef HAVE_DUP3 + ++/* Define if you have the '_dyld_shared_cache_contains_path' function */ ++#undef HAVE_DYLD_SHARED_CACHE_CONTAINS_PATH ++ + /* Defined when any dynamic module loading is enabled. */ + #undef HAVE_DYNAMIC_LOADING + +-- +2.28.0 + diff --git a/recipe/patches/gh21564.patch b/recipe/patches/0031-gh21564.patch.patch similarity index 96% rename from recipe/patches/gh21564.patch rename to recipe/patches/0031-gh21564.patch.patch index 49a8fec96..13e08e509 100644 --- a/recipe/patches/gh21564.patch +++ b/recipe/patches/0031-gh21564.patch.patch @@ -1,3 +1,26 @@ +From 8311bce4ef2ecf5e53938ab3770e89f88a232e92 Mon Sep 17 00:00:00 2001 +From: Filipe Fernandes +Date: Wed, 7 Oct 2020 10:03:36 -0300 +Subject: [PATCH 31/31] gh21564.patch + +--- + Lib/_osx_support.py | 2 + + Lib/ctypes/macholib/dyld.py | 5 + + Lib/distutils/tests/test_build_ext.py | 2 +- + Lib/test/test_bytes.py | 1 + + Lib/test/test_platform.py | 2 +- + Lib/test/test_unicode.py | 2 + + Mac/BuildScript/build-installer.py | 47 +++++++- + Mac/Tools/pythonw.c | 6 +- + Modules/_ctypes/callbacks.c | 39 +++++-- + Modules/_ctypes/callproc.c | 149 ++++++++++++++++++-------- + Modules/_ctypes/ctypes.h | 8 ++ + Modules/_ctypes/malloc_closure.c | 15 ++- + configure | 16 ++- + configure.ac | 16 ++- + setup.py | 131 +++++++++++++--------- + 15 files changed, 320 insertions(+), 121 deletions(-) + diff --git a/Lib/_osx_support.py b/Lib/_osx_support.py index e9efce7d7e..8ed1eeac85 100644 --- a/Lib/_osx_support.py @@ -699,7 +722,7 @@ index 99deb8c0f7..32856826fd 100644 esac diff --git a/setup.py b/setup.py -index 59d412da8f..b4569e54c3 100644 +index e3c97a6466..d4abd7b05d 100644 --- a/setup.py +++ b/setup.py @@ -179,6 +179,35 @@ def macosx_sdk_root(): @@ -893,3 +916,6 @@ index 59d412da8f..b4569e54c3 100644 ext.libraries.append(ffi_lib) self.use_system_libffi = True +-- +2.28.0 + diff --git a/recipe/patches/gh21228.patch b/recipe/patches/gh21228.patch deleted file mode 100644 index 7e7f469ac..000000000 --- a/recipe/patches/gh21228.patch +++ /dev/null @@ -1,47 +0,0 @@ -From 79d170ebfa523f4a4f104d8041ad880215c5d5fa Mon Sep 17 00:00:00 2001 -From: Lawrence D'Anna -Date: Mon, 29 Jun 2020 16:05:44 -0700 -Subject: [PATCH 1/2] fix _decimal for arm64 Mac OS - -add __arm64__ to the allowable Mac OS arches in mpdecimal.h ---- - Modules/_decimal/libmpdec/mpdecimal.h | 3 +++ - 1 file changed, 3 insertions(+) - -diff --git a/Modules/_decimal/libmpdec/mpdecimal.h b/Modules/_decimal/libmpdec/mpdecimal.h -index 108b76efa8594..35ce429f60124 100644 ---- a/Modules/_decimal/libmpdec/mpdecimal.h -+++ b/Modules/_decimal/libmpdec/mpdecimal.h -@@ -127,6 +127,9 @@ const char *mpd_version(void); - #elif defined(__x86_64__) - #define CONFIG_64 - #define ASM -+ #elif defined(__arm64__) -+ #define CONFIG_64 -+ #define ANSI - #else - #error "unknown architecture for universal build." - #endif - -From af7520590e6c72d3bb2b2438e5eb2b947d7a7372 Mon Sep 17 00:00:00 2001 -From: "blurb-it[bot]" <43283697+blurb-it[bot]@users.noreply.github.com> -Date: Tue, 30 Jun 2020 04:44:30 +0000 -Subject: [PATCH 2/2] =?UTF-8?q?=F0=9F=93=9C=F0=9F=A4=96=20Added=20by=20blu?= - =?UTF-8?q?rb=5Fit.?= -MIME-Version: 1.0 -Content-Type: text/plain; charset=UTF-8 -Content-Transfer-Encoding: 8bit - ---- - .../Core and Builtins/2020-06-30-04-44-29.bpo-41100.PJwA6F.rst | 1 + - 1 file changed, 1 insertion(+) - create mode 100644 Misc/NEWS.d/next/Core and Builtins/2020-06-30-04-44-29.bpo-41100.PJwA6F.rst - -diff --git a/Misc/NEWS.d/next/Core and Builtins/2020-06-30-04-44-29.bpo-41100.PJwA6F.rst b/Misc/NEWS.d/next/Core and Builtins/2020-06-30-04-44-29.bpo-41100.PJwA6F.rst -new file mode 100644 -index 0000000000000..d6176d69f0eb0 ---- /dev/null -+++ b/Misc/NEWS.d/next/Core and Builtins/2020-06-30-04-44-29.bpo-41100.PJwA6F.rst -@@ -0,0 +1 @@ -+add arm64 to the allowable Mac OS arches in mpdecimal.h -\ No newline at end of file diff --git a/recipe/patches/gh21241.patch b/recipe/patches/gh21241.patch deleted file mode 100644 index fe467194d..000000000 --- a/recipe/patches/gh21241.patch +++ /dev/null @@ -1,304 +0,0 @@ -From 311f8c301d8b6d3aef7156631f487eccc73c6ef7 Mon Sep 17 00:00:00 2001 -From: Lawrence D'Anna -Date: Tue, 30 Jun 2020 10:37:20 -0700 -Subject: [PATCH 1/3] ctypes: check _dyld_shared_cache_contains_path in - find_library - -System libraries in Mac OS 11 may be present only in the shared cache, -with the actual mach-o file not present in the corresponding location -on the filesystem. ctypes.util.find_library should check the -shared cache in order to behave consistently across Mac OS 10.15 -and earlier and Mac OS 11.0 and later. ---- - Lib/ctypes/macholib/dyld.py | 12 ++++++ - .../2020-06-30-18-24-28.bpo-41100._QkcD_.rst | 1 + - Modules/_ctypes/callproc.c | 38 +++++++++++++++++++ - 3 files changed, 51 insertions(+) - create mode 100644 Misc/NEWS.d/next/Core and Builtins/2020-06-30-18-24-28.bpo-41100._QkcD_.rst - -diff --git a/Lib/ctypes/macholib/dyld.py b/Lib/ctypes/macholib/dyld.py -index 9d86b058765a3..0cc04648db75d 100644 ---- a/Lib/ctypes/macholib/dyld.py -+++ b/Lib/ctypes/macholib/dyld.py -@@ -7,6 +7,12 @@ - from ctypes.macholib.dylib import dylib_info - from itertools import * - -+try: -+ from _ctypes import _dyld_shared_cache_contains_path -+except ImportError: -+ def _dyld_shared_cache_contains_path(*args): -+ raise NotImplementedError -+ - __all__ = [ - 'dyld_find', 'framework_find', - 'framework_info', 'dylib_info', -@@ -124,6 +130,12 @@ def dyld_find(name, executable_path=None, env=None): - ), env): - if os.path.isfile(path): - return path -+ try: -+ if _dyld_shared_cache_contains_path(path): -+ return path -+ except NotImplementedError: -+ pass -+ - raise ValueError("dylib %s could not be found" % (name,)) - - def framework_find(fn, executable_path=None, env=None): -diff --git a/Misc/NEWS.d/next/Core and Builtins/2020-06-30-18-24-28.bpo-41100._QkcD_.rst b/Misc/NEWS.d/next/Core and Builtins/2020-06-30-18-24-28.bpo-41100._QkcD_.rst -new file mode 100644 -index 0000000000000..dbb732432c079 ---- /dev/null -+++ b/Misc/NEWS.d/next/Core and Builtins/2020-06-30-18-24-28.bpo-41100._QkcD_.rst -@@ -0,0 +1 @@ -+ctypes: Mac OS 11: check for system libraries in the shared cache -\ No newline at end of file -diff --git a/Modules/_ctypes/callproc.c b/Modules/_ctypes/callproc.c -index 6030cc3d43670..572498715f500 100644 ---- a/Modules/_ctypes/callproc.c -+++ b/Modules/_ctypes/callproc.c -@@ -64,6 +64,10 @@ - #include "ctypes_dlfcn.h" - #endif - -+#ifdef __APPLE__ -+extern bool _dyld_shared_cache_contains_path(const char* path) __attribute__((weak_import)); -+#endif -+ - #ifdef MS_WIN32 - #include - #endif -@@ -1398,6 +1402,37 @@ copy_com_pointer(PyObject *self, PyObject *args) - } - #else - -+#ifdef __APPLE__ -+static PyObject *py_dyld_shared_cache_contains_path(PyObject *self, PyObject *args) -+{ -+ PyObject *name, *name2; -+ char *name_str; -+ -+ if (_dyld_shared_cache_contains_path == NULL) { -+ PyErr_SetString(PyExc_NotImplementedError, "_dyld_shared_cache_contains_path symbol is missing"); -+ return NULL; -+ } -+ -+ if (!PyArg_ParseTuple(args, "O", &name)) -+ return NULL; -+ -+ if (name == Py_None) -+ Py_RETURN_FALSE; -+ -+ if (PyUnicode_FSConverter(name, &name2) == 0) -+ return NULL; -+ if (PyBytes_Check(name2)) -+ name_str = PyBytes_AS_STRING(name2); -+ else -+ name_str = PyByteArray_AS_STRING(name2); -+ -+ if(_dyld_shared_cache_contains_path(name_str)) -+ Py_RETURN_TRUE; -+ else -+ Py_RETURN_FALSE; -+} -+#endif -+ - static PyObject *py_dl_open(PyObject *self, PyObject *args) - { - PyObject *name, *name2; -@@ -1908,6 +1943,9 @@ PyMethodDef _ctypes_module_methods[] = { - "dlopen(name, flag={RTLD_GLOBAL|RTLD_LOCAL}) open a shared library"}, - {"dlclose", py_dl_close, METH_VARARGS, "dlclose a library"}, - {"dlsym", py_dl_sym, METH_VARARGS, "find symbol in shared library"}, -+#endif -+#ifdef __APPLE__ -+ {"_dyld_shared_cache_contains_path", py_dyld_shared_cache_contains_path, METH_VARARGS, "check if path is in the shared cache"}, - #endif - {"alignment", align_func, METH_O, alignment_doc}, - {"sizeof", sizeof_func, METH_O, sizeof_doc}, - -From 6b2988773a53b91d655a6843ea4522f6de0dbbad Mon Sep 17 00:00:00 2001 -From: Lawrence D'Anna -Date: Fri, 17 Jul 2020 16:24:07 -0700 -Subject: [PATCH 2/3] fix test_macholib for Mac OS 11 - ---- - Lib/ctypes/test/test_macholib.py | 15 ++++++++++----- - 1 file changed, 10 insertions(+), 5 deletions(-) - -diff --git a/Lib/ctypes/test/test_macholib.py b/Lib/ctypes/test/test_macholib.py -index 6b3526951acfa..ed04479abd091 100644 ---- a/Lib/ctypes/test/test_macholib.py -+++ b/Lib/ctypes/test/test_macholib.py -@@ -46,18 +46,23 @@ class MachOTest(unittest.TestCase): - @unittest.skipUnless(sys.platform == "darwin", 'OSX-specific test') - def test_find(self): - -- self.assertEqual(find_lib('pthread'), -- '/usr/lib/libSystem.B.dylib') -+ # On Mac OS 11, system dylibs are only present in the shared cache, -+ # so symlinks like libpthread.dylib -> libSystem.B.dylib will not -+ # be resolved by dyld_find -+ -+ self.assertIn(find_lib('pthread'), -+ ('/usr/lib/libSystem.B.dylib', '/usr/lib/libpthread.dylib')) - - result = find_lib('z') - # Issue #21093: dyld default search path includes $HOME/lib and - # /usr/local/lib before /usr/lib, which caused test failures if - # a local copy of libz exists in one of them. Now ignore the head - # of the path. -- self.assertRegex(result, r".*/lib/libz\..*.*\.dylib") -+ self.assertRegex(result, r".*/lib/libz.*\.dylib") - -- self.assertEqual(find_lib('IOKit'), -- '/System/Library/Frameworks/IOKit.framework/Versions/A/IOKit') -+ self.assertIn(find_lib('IOKit'), -+ ('/System/Library/Frameworks/IOKit.framework/Versions/A/IOKit', -+ '/System/Library/Frameworks/IOKit.framework/IOKit')) - - if __name__ == "__main__": - unittest.main() - -From b76ec34daf6e5023b6afb0c6f52ec5e1e5c14884 Mon Sep 17 00:00:00 2001 -From: Lawrence D'Anna -Date: Wed, 5 Aug 2020 15:20:36 -0700 -Subject: [PATCH 3/3] Xcode 12 Beta 4 declares _dyld_shared_cache_contains_path - ---- - Modules/_ctypes/callproc.c | 49 +++++++++++++++++++------------------- - configure | 9 +++++++ - configure.ac | 4 ++++ - pyconfig.h.in | 3 +++ - 4 files changed, 40 insertions(+), 25 deletions(-) - -diff --git a/Modules/_ctypes/callproc.c b/Modules/_ctypes/callproc.c -index 572498715f500..f8007505ed310 100644 ---- a/Modules/_ctypes/callproc.c -+++ b/Modules/_ctypes/callproc.c -@@ -64,8 +64,8 @@ - #include "ctypes_dlfcn.h" - #endif - --#ifdef __APPLE__ --extern bool _dyld_shared_cache_contains_path(const char* path) __attribute__((weak_import)); -+#if __APPLE__ && HAVE_DYLD_SHARED_CACHE_CONTAINS_PATH -+#include - #endif - - #ifdef MS_WIN32 -@@ -1402,34 +1402,33 @@ copy_com_pointer(PyObject *self, PyObject *args) - } - #else - --#ifdef __APPLE__ -+#if __APPLE__ && HAVE_DYLD_SHARED_CACHE_CONTAINS_PATH - static PyObject *py_dyld_shared_cache_contains_path(PyObject *self, PyObject *args) - { -- PyObject *name, *name2; -- char *name_str; -- -- if (_dyld_shared_cache_contains_path == NULL) { -- PyErr_SetString(PyExc_NotImplementedError, "_dyld_shared_cache_contains_path symbol is missing"); -- return NULL; -- } -+ if (__builtin_available(macos 11, ios 14, watchos 7, tvos 14, *)) { -+ PyObject *name, *name2; -+ char *name_str; -+ if (!PyArg_ParseTuple(args, "O", &name)) -+ return NULL; - -- if (!PyArg_ParseTuple(args, "O", &name)) -- return NULL; -+ if (name == Py_None) -+ Py_RETURN_FALSE; - -- if (name == Py_None) -- Py_RETURN_FALSE; -+ if (PyUnicode_FSConverter(name, &name2) == 0) -+ return NULL; -+ if (PyBytes_Check(name2)) -+ name_str = PyBytes_AS_STRING(name2); -+ else -+ name_str = PyByteArray_AS_STRING(name2); - -- if (PyUnicode_FSConverter(name, &name2) == 0) -+ if(_dyld_shared_cache_contains_path(name_str)) -+ Py_RETURN_TRUE; -+ else -+ Py_RETURN_FALSE; -+ } else { -+ PyErr_SetString(PyExc_NotImplementedError, "_dyld_shared_cache_contains_path symbol is missing"); - return NULL; -- if (PyBytes_Check(name2)) -- name_str = PyBytes_AS_STRING(name2); -- else -- name_str = PyByteArray_AS_STRING(name2); -- -- if(_dyld_shared_cache_contains_path(name_str)) -- Py_RETURN_TRUE; -- else -- Py_RETURN_FALSE; -+ } - } - #endif - -@@ -1944,7 +1943,7 @@ PyMethodDef _ctypes_module_methods[] = { - {"dlclose", py_dl_close, METH_VARARGS, "dlclose a library"}, - {"dlsym", py_dl_sym, METH_VARARGS, "find symbol in shared library"}, - #endif --#ifdef __APPLE__ -+#if __APPLE__ && HAVE_DYLD_SHARED_CACHE_CONTAINS_PATH - {"_dyld_shared_cache_contains_path", py_dyld_shared_cache_contains_path, METH_VARARGS, "check if path is in the shared cache"}, - #endif - {"alignment", align_func, METH_O, alignment_doc}, -diff --git a/configure b/configure -index 5024860ca4395..0ecd1a1d66c79 100755 ---- a/configure -+++ b/configure -@@ -11601,6 +11601,15 @@ fi - done - - -+ac_fn_c_check_decl "$LINENO" "_dyld_shared_cache_contains_path" "ac_cv_have_decl__dyld_shared_cache_contains_path" "#include -+" -+if test "x$ac_cv_have_decl__dyld_shared_cache_contains_path" = xyes; then : -+ -+$as_echo "#define HAVE_DYLD_SHARED_CACHE_CONTAINS_PATH 1" >>confdefs.h -+ -+fi -+ -+ - # DYNLOADFILE specifies which dynload_*.o file we will use for dynamic - # loading of modules. - -diff --git a/configure.ac b/configure.ac -index 5a3e340aa3e72..bf7250d0085f6 100644 ---- a/configure.ac -+++ b/configure.ac -@@ -3603,6 +3603,10 @@ DLINCLDIR=. - # platforms, such as AIX, have dlopen(), but don't want to use it. - AC_CHECK_FUNCS(dlopen) - -+AC_CHECK_DECL(_dyld_shared_cache_contains_path, -+ AC_DEFINE(HAVE_DYLD_SHARED_CACHE_CONTAINS_PATH, 1, Define if you have the '_dyld_shared_cache_contains_path' function), -+ [], [#include ]) -+ - # DYNLOADFILE specifies which dynload_*.o file we will use for dynamic - # loading of modules. - AC_SUBST(DYNLOADFILE) -diff --git a/pyconfig.h.in b/pyconfig.h.in -index bc906a869b623..53ce2738dabb6 100644 ---- a/pyconfig.h.in -+++ b/pyconfig.h.in -@@ -284,6 +284,9 @@ - /* Define to 1 if you have the `dup3' function. */ - #undef HAVE_DUP3 - -+/* Define if you have the '_dyld_shared_cache_contains_path' function */ -+#undef HAVE_DYLD_SHARED_CACHE_CONTAINS_PATH -+ - /* Defined when any dynamic module loading is enabled. */ - #undef HAVE_DYNAMIC_LOADING -