diff --git a/ports/python2/008-bz2d.patch b/ports/python2/008-bz2d.patch new file mode 100644 index 00000000000000..88ec7405e01aa1 --- /dev/null +++ b/ports/python2/008-bz2d.patch @@ -0,0 +1,19 @@ +diff --git a/setup.py b/setup.py +index f764223..d6a58e4 100644 +--- a/setup.py ++++ b/setup.py +@@ -1506,6 +1506,14 @@ class PyBuildExt(build_ext): + exts.append( Extension('bz2', ['bz2module.c'], + libraries = ['bz2'], + extra_link_args = bz2_extra_link_args) ) ++ elif (self.compiler.find_library_file(lib_dirs, 'bz2d')): ++ if host_platform == "darwin": ++ bz2_extra_link_args = ('-Wl,-search_paths_first',) ++ else: ++ bz2_extra_link_args = () ++ exts.append( Extension('bz2', ['bz2module.c'], ++ libraries=['bz2d'], ++ extra_link_args = bz2_extra_link_args) ) + else: + missing.append('bz2') + diff --git a/ports/python2/portfile.cmake b/ports/python2/portfile.cmake index 7d0d9a527426b6..227ffed4115918 100644 --- a/ports/python2/portfile.cmake +++ b/ports/python2/portfile.cmake @@ -35,6 +35,10 @@ if (VCPKG_TARGET_IS_WINDOWS) list(APPEND _PYTHON_PATCHES ${CMAKE_CURRENT_LIST_DIR}/007-fix-build-path.patch ) +else() + list(APPEND _PYTHON_PATCHES + ${CMAKE_CURRENT_LIST_DIR}/008-bz2d.patch + ) endif() diff --git a/ports/python2/vcpkg.json b/ports/python2/vcpkg.json index 6be1869d01f999..abe470eb5b662d 100644 --- a/ports/python2/vcpkg.json +++ b/ports/python2/vcpkg.json @@ -1,7 +1,7 @@ { "name": "python2", "version": "2.7.18", - "port-version": 3, + "port-version": 4, "description": "The Python programming language as an embeddable library", "homepage": "https://www.python.org", "license": "Python-2.0" diff --git a/versions/baseline.json b/versions/baseline.json index 01e87268226dd7..d7b6fa1c27a8c6 100644 --- a/versions/baseline.json +++ b/versions/baseline.json @@ -5578,7 +5578,7 @@ }, "python2": { "baseline": "2.7.18", - "port-version": 3 + "port-version": 4 }, "python3": { "baseline": "3.10.2", diff --git a/versions/p-/python2.json b/versions/p-/python2.json index cbb06c836db015..60a67697bd4fee 100644 --- a/versions/p-/python2.json +++ b/versions/p-/python2.json @@ -1,5 +1,10 @@ { "versions": [ + { + "git-tree": "355e949adaecb1603d0cdc3d690101e49ad9fb13", + "version": "2.7.18", + "port-version": 4 + }, { "git-tree": "2a9fb7f96d762e213e9901452492aee00f6fe049", "version": "2.7.18",