aboutsummaryrefslogtreecommitdiffstats
path: root/bootstrap.py
diff options
context:
space:
mode:
authortarek <none@none>2009-07-23 12:41:43 +0200
committertarek <none@none>2009-07-23 12:41:43 +0200
commitb39058a69286b47b7ec63b1be4d50c225f1d30d1 (patch)
treee298ac2d70ed4b84570127df14981ba7419ab3f7 /bootstrap.py
parent8e59ae90b1dcfb8cab7255509b2d13bfc96a516e (diff)
downloadexternal_python_setuptools-b39058a69286b47b7ec63b1be4d50c225f1d30d1.tar.gz
external_python_setuptools-b39058a69286b47b7ec63b1be4d50c225f1d30d1.tar.bz2
external_python_setuptools-b39058a69286b47b7ec63b1be4d50c225f1d30d1.zip
shorcut to avoid unecessary work when located in a non-isolated environment
--HG-- branch : distribute extra : rebase_source : 6b093a48e2647923cf36d1dd7ea74def0a961dc6
Diffstat (limited to 'bootstrap.py')
-rw-r--r--bootstrap.py9
1 files changed, 5 insertions, 4 deletions
diff --git a/bootstrap.py b/bootstrap.py
index 9908429b..40505c55 100644
--- a/bootstrap.py
+++ b/bootstrap.py
@@ -181,7 +181,7 @@ def _rename_path(path):
def _remove_flat_installation(placeholder):
if not os.path.isdir(placeholder):
- log.warn('Unkown installation')
+ log.warn('Unkown installation at %s' % placeholder)
return False
found = False
for file in os.listdir(placeholder):
@@ -295,9 +295,10 @@ def main(argv, version=DEFAULT_VERSION):
import setuptools
if not hasattr(setuptools, '_distribute'):
placeholder = os.path.split(os.path.dirname(setuptools.__file__))[0]
- res = _remove_flat_installation(placeholder)
- if res:
- _relaunch()
+ if not placeholder.endswith('.egg'):
+ res = _remove_flat_installation(placeholder)
+ if res:
+ _relaunch()
print >> sys.stderr, (
"The patch didn't work, Setuptools is still active.\n"
"Possible reason: your have a system-wide setuptools installed "