protobuf (2.3.0-4) disable-setuptools-download.diff

Summary

 python/ez_setup.py |    7 ++++---
 1 file changed, 4 insertions(+), 3 deletions(-)

    
download this patch

Patch contents

Description: Disable automatic setuptools download
 For Debian builds, we must use the packaged setuptools, and
 if that is not available, fail hard instead of downloading
 and installing from the internet the needed version
Author: Iustin Pop <iustin@debian.org>
Bug-Debian: http://bugs.debian.org/593269
Forwarded: not-needed
Last-Update: 2010-08-18
--- a/python/ez_setup.py
+++ b/python/ez_setup.py
@@ -91,9 +91,10 @@
     """
     was_imported = 'pkg_resources' in sys.modules or 'setuptools' in sys.modules
     def do_download():
-        egg = download_setuptools(version, download_base, to_dir, download_delay)
-        sys.path.insert(0, egg)
-        import setuptools; setuptools.bootstrap_install_from = egg
+        print >>sys.stderr, (
+        "The required version of setuptools (>=%s) is not available, and\n"
+        "can't be installed during Debian package builds.") % version
+        sys.exit(2)
     try:
         import pkg_resources
     except ImportError: