[Python-checkins] python/dist/src/Lib/distutils sysconfig.py, 1.61, 1.61.2.1

jackjansen at users.sourceforge.net jackjansen at users.sourceforge.net
Fri Jan 7 00:16:17 CET 2005


Update of /cvsroot/python/python/dist/src/Lib/distutils
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv15114/Lib/distutils

Modified Files:
      Tag: release24-maint
	sysconfig.py 
Log Message:
Backported from the trunk:
After discussion on the PythonMac-SIG it was decided that it is better
to make using "-undefined dynamic_lookup" for linking extensions more
automatic on 10.3 and later. So if we're on that platform and
MACOSX_DEPLOYMENT_TARGET is not set we now set it to the current OSX
version during configure. Additionally, distutils will pick up the
configure-time value by default.



Index: sysconfig.py
===================================================================
RCS file: /cvsroot/python/python/dist/src/Lib/distutils/sysconfig.py,v
retrieving revision 1.61
retrieving revision 1.61.2.1
diff -u -d -r1.61 -r1.61.2.1
--- sysconfig.py	13 Oct 2004 15:54:16 -0000	1.61
+++ sysconfig.py	6 Jan 2005 23:16:03 -0000	1.61.2.1
@@ -360,11 +360,13 @@
     # 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.
-    # An alternative would be to force MACOSX_DEPLOYMENT_TARGET to be
-    # the same as during configure.
+    # If it isn't set we set it to the configure-time value
     if sys.platform == 'darwin' and g.has_key('CONFIGURE_MACOSX_DEPLOYMENT_TARGET'):
         cfg_target = g['CONFIGURE_MACOSX_DEPLOYMENT_TARGET']
         cur_target = os.getenv('MACOSX_DEPLOYMENT_TARGET', '')
+        if cur_target == '':
+            cur_target = cfg_target
+            os.putenv('MACOSX_DEPLOYMENT_TARGET', cfg_target)
         if cfg_target != cur_target:
             my_msg = ('$MACOSX_DEPLOYMENT_TARGET mismatch: now "%s" but "%s" during configure'
                 % (cur_target, cfg_target))



More information about the Python-checkins mailing list