diff options
author | Pearu Peterson <pearu.peterson@gmail.com> | 2007-07-27 20:48:48 +0000 |
---|---|---|
committer | Pearu Peterson <pearu.peterson@gmail.com> | 2007-07-27 20:48:48 +0000 |
commit | d03073f29f8722df15acf88d9dd860dd69c92bef (patch) | |
tree | df30dc6e8a7aca210b15f9978b85e8445dc7c48f /numpy/distutils/misc_util.py | |
parent | e4cf3417be16ac14aeff908fc344a632fc1b4399 (diff) | |
download | numpy-d03073f29f8722df15acf88d9dd860dd69c92bef.tar.gz |
Try to fix build on AMD64 with MSVC compiler.
Diffstat (limited to 'numpy/distutils/misc_util.py')
-rw-r--r-- | numpy/distutils/misc_util.py | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/numpy/distutils/misc_util.py b/numpy/distutils/misc_util.py index 2e6c94712..911726e26 100644 --- a/numpy/distutils/misc_util.py +++ b/numpy/distutils/misc_util.py @@ -318,6 +318,20 @@ def msvc_runtime_library(): lib = None return lib +def msvc_on_amd64(): + if not (sys.platform=='win32' or os.name=='nt'): + return + from distutils.msvccompiler import get_build_architecture + if get_build_architecture() != 'AMD64': + return + if os.environ.has_key('DISTUTILS_USE_SDK'): + return + # try to avoid _MSVCCompiler__root attribute error + os.environ['DISTUTILS_USE_SDK']=1 + return + +msvc_on_amd64() + ######################### #XXX need support for .C that is also C++ |