[PATCH] distutils: Add MANIFEST.in file to include all files in 'python setup.py sdist'

Thorne, Stephen stephen at thorne.id.au
Wed Jun 1 17:16:54 CDT 2011


On Thu, Jun 2, 2011 at 2:20 AM, Matt Mackall <mpm at selenic.com> wrote:
> On Wed, 2011-06-01 at 17:34 +1000, Stephen Thorne wrote:
>> # HG changeset patch
>> # User Stephen Thorne <stephen at thorne.id.au>
>> # Date 1306913635 -36000
>> # Node ID 273241bc44612434b1c67851dfb2bae437c75e62
>> # Parent  bd34a027f3edad33e71c02def67eb446473b6cf4
>> distutils: Add MANIFEST.in file to include all files in 'python setup.py sdist'
>>
>> When running 'python setup.py sdist' many files were omitted from the resulting
>> tarball that are required for a complete build, including the .h file for the
>> inotify extension.
>
> This is already automated. See 'make MANIFEST'.
>
> Why isn't this instead automated in setup.py? Because distutils is an
> under-documented, poorly maintained, ill-suited.. you get the idea. It's
> primary use to us is supplying compiler options on multiple platforms.

Okay, so I've had a look at the sdist that is created when using the
MANIFEST that is created from 'make MANIFEST', and it omits things
that are required for a successful build, such as mercurial.pure (for
pure python implementations of c modules) and mercurial/util.h (for
successful build of c modules.

I wrote the MANIFEST.in patch to achieve a certain goal: make the
sdist useful for building mercurial, this is required for tools like
bdist_rpm to function correctly.

I have had a play with 'make MANIFEST', and it seems that there is no
difference in the files included in the resulting .tar.gz from an
sdist and a bdist between having the MANIFEST present and having it
absent. What does the 'make MANIFEST' achieve?

Stephen.


More information about the Mercurial-devel mailing list