mirror of
https://github.com/python/cpython.git
synced 2025-10-14 02:43:49 +00:00
Issue #23968: Make OS X installer build script aware of renamed platform
directory and sysconfigdata file name. This is a workaround for 3.6.0a4 pending resolution of other #23968 items.
This commit is contained in:
parent
0a891d70de
commit
652bad4f4a
1 changed files with 26 additions and 22 deletions
|
@ -1249,6 +1249,8 @@ def buildPython():
|
|||
LDVERSION = LDVERSION.replace('$(VERSION)', VERSION)
|
||||
LDVERSION = LDVERSION.replace('$(ABIFLAGS)', ABIFLAGS)
|
||||
config_suffix = '-' + LDVERSION
|
||||
if getVersionMajorMinor() >= (3, 6):
|
||||
config_suffix = config_suffix + '-darwin'
|
||||
else:
|
||||
config_suffix = '' # Python 2.x
|
||||
|
||||
|
@ -1274,7 +1276,7 @@ def buildPython():
|
|||
fp.write(data)
|
||||
fp.close()
|
||||
|
||||
# fix _sysconfigdata if it exists
|
||||
# fix _sysconfigdata
|
||||
#
|
||||
# TODO: make this more robust! test_sysconfig_module of
|
||||
# distutils.tests.test_sysconfig.SysconfigTestCase tests that
|
||||
|
@ -1288,8 +1290,10 @@ def buildPython():
|
|||
# _sysconfigdata.py).
|
||||
|
||||
import pprint
|
||||
if getVersionMajorMinor() >= (3, 6):
|
||||
path = os.path.join(path_to_lib, 'plat-darwin', '_sysconfigdata_m.py')
|
||||
else:
|
||||
path = os.path.join(path_to_lib, '_sysconfigdata.py')
|
||||
if os.path.exists(path):
|
||||
fp = open(path, 'r')
|
||||
data = fp.read()
|
||||
fp.close()
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue