[Python-checkins] r42299 - sandbox/trunk/setuptools/setuptools/command/easy_install.py

phillip.eby python-checkins at python.org
Fri Feb 10 02:25:21 CET 2006


Author: phillip.eby
Date: Fri Feb 10 02:25:20 2006
New Revision: 42299

Modified:
   sandbox/trunk/setuptools/setuptools/command/easy_install.py
Log:
Tweak site_dirs detection so that distros with weird layouts (e.g.
/usr/lib64 patches on 64-bit Fedora) will have a better chance of
working "out of the box".


Modified: sandbox/trunk/setuptools/setuptools/command/easy_install.py
==============================================================================
--- sandbox/trunk/setuptools/setuptools/command/easy_install.py	(original)
+++ sandbox/trunk/setuptools/setuptools/command/easy_install.py	Fri Feb 10 02:25:20 2006
@@ -934,12 +934,12 @@
                                          sys.version[:3],
                                          'site-packages'))
 
+         site_lib = get_python_lib(prefix=prefix or None)
+         if site_lib not in sitedirs: sitedirs.append(site_lib)        
+
     sitedirs = filter(os.path.isdir, sitedirs)
     sitedirs = map(normalize_path, sitedirs)
-    return sitedirs or [normalize_path(get_python_lib())] # ensure at least one
-
-
-
+    return sitedirs     # ensure at least one
 
 def expand_paths(inputs):
     """Yield sys.path directories that might contain "old-style" packages"""


More information about the Python-checkins mailing list