summaryrefslogtreecommitdiff
path: root/pkg_resources.py
diff options
context:
space:
mode:
authorPJ Eby <distutils-sig@python.org>2006-09-20 20:57:09 +0000
committerPJ Eby <distutils-sig@python.org>2006-09-20 20:57:09 +0000
commit3f80f94b036dd3030d772db119504fbf7a78bf13 (patch)
tree3a62ea2a86b012f093dbdac1591452bb4903608d /pkg_resources.py
parent3bf8c4fa854d9cbb9af700b3852b1fded03fea54 (diff)
downloadpython-setuptools-git-3f80f94b036dd3030d772db119504fbf7a78bf13.tar.gz
More Python 2.5 compatibility fixes.
--HG-- branch : setuptools-0.6 extra : convert_revision : svn%3A6015fed2-1504-0410-9fe1-9d1591cc4771/sandbox/branches/setuptools-0.6%4051937
Diffstat (limited to 'pkg_resources.py')
-rw-r--r--pkg_resources.py14
1 files changed, 7 insertions, 7 deletions
diff --git a/pkg_resources.py b/pkg_resources.py
index 03f48225..b4b92e87 100644
--- a/pkg_resources.py
+++ b/pkg_resources.py
@@ -1502,13 +1502,13 @@ def get_importer(path_item):
pass
return importer
-
-
-
-
-
-
-
+try:
+ from pkgutil import get_importer, ImpImporter
+except ImportError:
+ pass # Python 2.3 or 2.4, use our own implementation
+else:
+ ImpWrapper = ImpImporter # Python 2.5, use pkgutil's implementation
+ del ImpLoader, ImpImporter