Commit 9a654c9c authored by jim's avatar jim

Fixed: Bug #96892.

Now use  system setuptools  if it is  available.  This can  also speed
bootstrapping,  since we  don't need  to download  setuptools  in more
cases.


git-svn-id: http://svn.zope.org/repos/main/zc.buildout/trunk@75593 62d5b8a3-27da-0310-9561-8e5933582275
parent 0adf58cf
...@@ -24,12 +24,15 @@ import os, shutil, sys, tempfile, urllib2 ...@@ -24,12 +24,15 @@ import os, shutil, sys, tempfile, urllib2
tmpeggs = tempfile.mkdtemp() tmpeggs = tempfile.mkdtemp()
ez = {} try:
exec urllib2.urlopen('http://peak.telecommunity.com/dist/ez_setup.py' import pkg_resources
except ImportError:
ez = {}
exec urllib2.urlopen('http://peak.telecommunity.com/dist/ez_setup.py'
).read() in ez ).read() in ez
ez['use_setuptools'](to_dir=tmpeggs, download_delay=0) ez['use_setuptools'](to_dir=tmpeggs, download_delay=0)
import pkg_resources import pkg_resources
cmd = 'from setuptools.command.easy_install import main; main()' cmd = 'from setuptools.command.easy_install import main; main()'
if sys.platform == 'win32': if sys.platform == 'win32':
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment