import os
import sys

os.environ['NO_SCIPY_IMPORT']='SciPy/setup.py'

def configuration(parent_package='',top_path=None):
      from numpy.distutils.misc_util import Configuration
      config = Configuration(None, parent_package, top_path,
                             maintainer = "SciPy Developers",
                             maintainer_email = "scipy-dev@scipy.org",
                             description = "Scientific Algorithms Library for Python",
                             url = "http://www.scipy.org",
                             license = 'BSD',
                             )
      config.set_options(ignore_setup_xxx_py=True,
                         assume_default_configuration=True,
                         delegate_options_to_subpackages=True,
                         quiet=True)

      config.add_subpackage('Lib')
      config.name = 'scipy' # used in generated file names

      config.add_data_files(('scipy','*.txt'))

      from version import version as version
      config.dict_append(version=version)

      return config

def setup_package():

    from numpy.distutils.core import setup
    from numpy.distutils.misc_util import Configuration

    old_path = os.getcwd()
    local_path = os.path.dirname(os.path.abspath(sys.argv[0]))
    os.chdir(local_path)
    sys.path.insert(0,local_path)
    sys.path.insert(0,os.path.join(local_path,'Lib')) # to retrive version

    try:
        setup( configuration=configuration )
    finally:
        del sys.path[0]
        os.chdir(old_path)

    return

if __name__ == '__main__':
    setup_package()

@@ -236,364 +236,8 @@
 path
-,%0A                             maintainer = %22SciPy Developers%22,%0A                             maintainer_email = %22scipy-dev@scipy.org%22,%0A                             description = %22Scientific Algorithms Library for Python%22,%0A                             url = %22http://www.scipy.org%22,%0A                             license = 'BSD',%0A                             
 )%0A  
@@ -485,68 +485,8 @@
 b')%0A
-      config.name = 'scipy' # used in generated file names%0A%0A
     
@@ -539,88 +539,66 @@
     
-from version import 
+config.get_
 version
- as 
+('Lib/
 version
-%0A      config.dict_append(version=version)
+.py') # sets config.version
 %0A%0A  
@@ -984,14 +984,419 @@
     
-setup(
+from version import version as version%0A        setup(%0A            name = 'scipy',%0A            version = version, # will be overwritten by configuration version%0A            maintainer = %22SciPy Developers%22,%0A            maintainer_email = %22scipy-dev@scipy.org%22,%0A            description = %22Scientific Algorithms Library for Python%22,%0A            url = %22http://www.scipy.org%22,%0A            license = 'BSD',%0A           
  con

Fix pkg information requests.