Changeset 298


Ignore:
Timestamp:
10/09/08 11:56:20 (6 years ago)
Author:
xi
Message:

Fixed the distutils script to run when installed using easy_install and Pyrex is available.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • pyyaml/trunk/setup.py

    r295 r298  
    5050 
    5151 
     52import sys, os.path 
     53 
    5254from distutils import log 
    5355from distutils.core import setup, Command 
     
    5860from distutils.errors import CompileError, LinkError, DistutilsPlatformError 
    5961 
     62if 'setuptools.extension' in sys.modules: 
     63    _Extension = sys.modules['setuptools.extension']._Extension 
     64    sys.modules['distutils.core'].Extension = _Extension 
     65    sys.modules['distutils.extension'].Extension = _Extension 
     66    sys.modules['distutils.command.build_ext'].Extension = _Extension 
     67 
    6068try: 
    6169    from Pyrex.Distutils import Extension as _Extension 
     
    6573    with_pyrex = False 
    6674 
    67 import sys, os.path 
    6875 
    6976 
Note: See TracChangeset for help on using the changeset viewer.