[Python-checkins] r86469 - python/branches/py3k-cdecimal/setup.py

stefan.krah python-checkins at python.org
Mon Nov 15 11:55:49 CET 2010


Author: stefan.krah
Date: Mon Nov 15 11:55:48 2010
New Revision: 86469

Log:
Add support for universal build.

Modified:
   python/branches/py3k-cdecimal/setup.py

Modified: python/branches/py3k-cdecimal/setup.py
==============================================================================
--- python/branches/py3k-cdecimal/setup.py	(original)
+++ python/branches/py3k-cdecimal/setup.py	Mon Nov 15 11:55:48 2010
@@ -1767,8 +1767,6 @@
           'cdecimal/io.h',
           'cdecimal/memory.h',
           'cdecimal/mpdecimal.h',
-          'cdecimal/mpdecimal32.h',
-          'cdecimal/mpdecimal64.h',
           'cdecimal/mptypes.h',
           'cdecimal/numbertheory.h',
           'cdecimal/sixstep.h',
@@ -1780,7 +1778,9 @@
         platform = self.get_platform()
         cc = sysconfig.get_config_var('CC')
         sizeof_size_t = sysconfig.get_config_var('SIZEOF_SIZE_T')
-        if sizeof_size_t == 8:
+        if platform == 'darwin':
+            define_macros = [('UNIVERSAL', '1')]
+        elif sizeof_size_t == 8:
             if sysconfig.get_config_var('HAVE_GCC_ASM_FOR_X64'):
                 define_macros = [('CONFIG_64', '1'), ('ASM', '1')]
             elif sysconfig.get_config_var('HAVE_GCC_UINT128_T'):
@@ -1790,8 +1790,7 @@
                 define_macros = [('CONFIG_64', '1'), ('ANSI', '1')]
         elif sizeof_size_t == 4:
             ppro = sysconfig.get_config_var('HAVE_GCC_ASM_FOR_X87')
-            if ppro and ('gcc' in cc or 'clang' in cc) and \
-               platform != 'darwin':
+            if ppro and ('gcc' in cc or 'clang' in cc):
                 # darwin: problems with global constant in inline asm.
                 # icc >= 11.0 works as well.
                 define_macros = [('CONFIG_32', '1'), ('PPRO', '1'),


More information about the Python-checkins mailing list