[Distutils] data_files and sdist

Paul Prescod paul at prescod.net
Mon Feb 23 12:06:43 EST 2004


M.-A. Lemburg wrote:

> ...
> 
> Maybe because setup.py does not reference all the files that
> are needed by a project ?! E.g. think of a C library with
> dozens of header files and auxiliary files that only the
> C lib's Makefile knows about. distutils wouldn't have a chance
> to find these automagically. Another example is files that
> are not part of the installed software, but only included for
> reference, e.g. README files, hints, install guides, etc.

Distutils does not know about these files only because I do not have a 
way to tell it about them. Imagine:

setup(...,
	extra_source_files=["README". "install.txt", glob.glob("include/*.h"]...)

>> Because I think that MANIFEST is a bad idea, I delete it every time I 
>> build and let Pyrex generate another. This brings me to my low-level 
>> question.
>>
>> Pyrex generates a MANIFEST according to rules described here:
>>
>>  * http://www.python.org/doc/current/dist/source-dist.html
>>
>> These rules do not include data_files. My original question was "why 
>> not?"
> 
> 
> Why not write a MANIFEST.in that includes everything you
> need ?

That's how I'll solve my problem in the short term but I'm asking a 
design question. distutils generates MANIFEST files. The algorithm for 
generating them is well-documented. Those MANIFEST files leave out 
data_files? Why?

  Paul Prescod





More information about the Distutils-SIG mailing list