aboutsummaryrefslogtreecommitdiffstats
path: root/setuptools/command/sdist.py
diff options
context:
space:
mode:
authorJason R. Coombs <jaraco@jaraco.com>2012-09-05 20:03:16 -0400
committerJason R. Coombs <jaraco@jaraco.com>2012-09-05 20:03:16 -0400
commit27f432716d6624ca043ac428a70b6aaf5e0d537b (patch)
treed80693c8b618e7a8e6d12a3c73b51dec869df5ef /setuptools/command/sdist.py
parent9ebbe014df37c19976a5a9cb0ac2fa228a03144a (diff)
parent6eece1023d4a0d5e7229d33dc53600e8e31d7942 (diff)
downloadexternal_python_setuptools-27f432716d6624ca043ac428a70b6aaf5e0d537b.tar.gz
external_python_setuptools-27f432716d6624ca043ac428a70b6aaf5e0d537b.tar.bz2
external_python_setuptools-27f432716d6624ca043ac428a70b6aaf5e0d537b.zip
Merged in embray/distribute/fix-sdist (pull request #4)
--HG-- branch : distribute extra : rebase_source : edfbe310b187502d98f3fb19e7aa405238a143be
Diffstat (limited to 'setuptools/command/sdist.py')
-rwxr-xr-xsetuptools/command/sdist.py8
1 files changed, 8 insertions, 0 deletions
diff --git a/setuptools/command/sdist.py b/setuptools/command/sdist.py
index 91c4fd1b..a176f635 100755
--- a/setuptools/command/sdist.py
+++ b/setuptools/command/sdist.py
@@ -198,6 +198,14 @@ class sdist(_sdist):
if self.distribution.has_pure_modules():
build_py = self.get_finalized_command('build_py')
self.filelist.extend(build_py.get_source_files())
+ # This functionality is incompatible with include_package_data, and
+ # will in fact create an infinite recursion if include_package_data
+ # is True. Use of include_package_data will imply that
+ # distutils-style automatic handling of package_data is disabled
+ if not self.distribution.include_package_data:
+ for _, src_dir, _, filenames in build_py.data_files:
+ self.filelist.extend([os.path.join(src_dir, filename)
+ for filename in filenames])
if self.distribution.has_ext_modules():
build_ext = self.get_finalized_command('build_ext')