mirror of
https://github.com/python/cpython.git
synced 2025-07-24 03:35:53 +00:00
bpo-42504: fix for MACOSX_DEPLOYMENT_TARGET=11 (GH-23556)
macOS releases numbering has changed as of macOS 11 Big Sur. Previously, major releases were of the form 10.x, 10.x+1, 10.x+2, etc; as of Big Sur, they are now x, x+1, etc, so, for example, 10.15, 10.15.1, ..., 10.15.7, 11, 11.0.1, 11.1, ..., 12, 12.1, etc. Allow Python to build with single-digit deployment target values. Patch provided by FX Coudert.
This commit is contained in:
parent
dedc2cd5f0
commit
5291639e61
5 changed files with 12 additions and 7 deletions
|
@ -54,8 +54,8 @@ def spawn(cmd, search_path=1, verbose=0, dry_run=0):
|
|||
global _cfg_target, _cfg_target_split
|
||||
if _cfg_target is None:
|
||||
from distutils import sysconfig
|
||||
_cfg_target = sysconfig.get_config_var(
|
||||
'MACOSX_DEPLOYMENT_TARGET') or ''
|
||||
_cfg_target = str(sysconfig.get_config_var(
|
||||
'MACOSX_DEPLOYMENT_TARGET') or '')
|
||||
if _cfg_target:
|
||||
_cfg_target_split = [int(x) for x in _cfg_target.split('.')]
|
||||
if _cfg_target:
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue