Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code | Sign in
(4)

Unified Diff: Lib/distutils/sysconfig.py

Issue 10639: reindent.py converts newlines to platform default
Patch Set: Created 8 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Please Sign in to add in-line comments.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « Lib/distutils/spawn.py ('k') | Lib/distutils/tests/test_build_ext.py » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
--- a/Lib/distutils/sysconfig.py Tue Jul 26 09:37:46 2011 +0300
+++ b/Lib/distutils/sysconfig.py Mon Jul 25 09:47:18 2011 -0400
@@ -419,6 +419,21 @@
raise DistutilsPlatformError(my_msg)
+ # On MacOSX we need to check the setting of the environment variable
+ # MACOSX_DEPLOYMENT_TARGET: configure bases some choices on it so
+ # it needs to be compatible.
+ # If it isn't set we set it to the configure-time value
+ if sys.platform == 'darwin' and 'MACOSX_DEPLOYMENT_TARGET' in g:
+ cfg_target = g['MACOSX_DEPLOYMENT_TARGET']
+ cur_target = os.getenv('MACOSX_DEPLOYMENT_TARGET', '')
+ if cur_target == '':
+ cur_target = cfg_target
+ os.environ['MACOSX_DEPLOYMENT_TARGET'] = cfg_target
+ elif [int(x) for x in cfg_target.split('.')] > [int(x) for x in cur_target.split('.')]:
+ my_msg = ('$MACOSX_DEPLOYMENT_TARGET mismatch: now "%s" but "%s" during configure'
+ % (cur_target, cfg_target))
+ raise DistutilsPlatformError(my_msg)
+
# On AIX, there are wrong paths to the linker scripts in the Makefile
# -- these paths are relative to the Python source, but when installed
# the scripts are in another directory.
« no previous file with comments | « Lib/distutils/spawn.py ('k') | Lib/distutils/tests/test_build_ext.py » ('j') | no next file with comments »

RSS Feeds Recent Issues | This issue
This is Rietveld 894c83f36cb7+