aboutsummaryrefslogtreecommitdiffstats
path: root/setuptools/command/bdist_egg.py
diff options
context:
space:
mode:
authorPJ Eby <distutils-sig@python.org>2006-03-21 19:04:55 +0000
committerPJ Eby <distutils-sig@python.org>2006-03-21 19:04:55 +0000
commit854c175586480056a84ee5e7806becd36e3803f6 (patch)
tree63c1143977057a70998e010b1e0ce628ed0a18fe /setuptools/command/bdist_egg.py
parent85278c01cffd63387e0d1ed89e1299bbf8f1a624 (diff)
downloadexternal_python_setuptools-854c175586480056a84ee5e7806becd36e3803f6.tar.gz
external_python_setuptools-854c175586480056a84ee5e7806becd36e3803f6.tar.bz2
external_python_setuptools-854c175586480056a84ee5e7806becd36e3803f6.zip
Don't generate a loader .py file in .egg file for extensions that aren't
actually built. This prevents problems w/customized setups that make some extensions optional (e.g. scipy.distutils). --HG-- branch : setuptools extra : convert_revision : svn%3A6015fed2-1504-0410-9fe1-9d1591cc4771/sandbox/trunk/setuptools%4043201
Diffstat (limited to 'setuptools/command/bdist_egg.py')
-rw-r--r--setuptools/command/bdist_egg.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/setuptools/command/bdist_egg.py b/setuptools/command/bdist_egg.py
index 2a48362e..d571ac80 100644
--- a/setuptools/command/bdist_egg.py
+++ b/setuptools/command/bdist_egg.py
@@ -307,7 +307,8 @@ class bdist_egg(Command):
fullname = build_cmd.get_ext_fullname(ext.name)
filename = build_cmd.get_ext_filename(fullname)
if not os.path.basename(filename).startswith('dl-'):
- ext_outputs.append(filename)
+ if os.path.exists(os.path.join(self.bdist_dir,filename)):
+ ext_outputs.append(filename)
return all_outputs, ext_outputs
@@ -325,7 +326,6 @@ NATIVE_EXTENSIONS = dict.fromkeys('.dll .so .dylib .pyd'.split())
-
def walk_egg(egg_dir):
"""Walk an unpacked egg's contents, skipping the metadata directory"""
walker = os.walk(egg_dir)