[Python-Dev] Why are generated files in the repository?

Thomas Wouters thomas at python.org
Sun Jan 25 10:55:11 CET 2015


On Sun, Jan 25, 2015 at 5:05 AM, Neil Girdhar <mistersheik at gmail.com> wrote:

> But you can remove Python/graminit.c and "make clean && make" works, right?
>

If you can write to the directory, yes. Except if you build in a way that
you can't run pgen on the host system, like in a cross build (this may have
been fixed with the last few rounds of cross build fixes) or when
instrumenting Python. Checking these files in trades very minor "committer
pain" (tossing merge conflicts and regenerating the files) for equally
minor pain in the much more diverse group of people compiling CPython.


>
> On Sat, Jan 24, 2015 at 11:00 PM, Nick Coghlan <ncoghlan at gmail.com> wrote:
>
>>
>> On 25 Jan 2015 01:09, "Benjamin Peterson" <benjamin at python.org> wrote:
>> >
>> >
>> >
>> > On Sat, Jan 24, 2015, at 03:00, Nick Coghlan wrote:
>> > > On 20 January 2015 at 10:53, Benjamin Peterson <benjamin at python.org>
>> > > wrote:
>> > > >
>> > > >
>> > > > On Mon, Jan 19, 2015, at 19:40, Neil Girdhar wrote:
>> > > >> I was also wondering why files like Python/graminit.c are in the
>> > > >> respository?  They generate spurious merge conflicts.
>> > > >
>> > > > Convenience mostly.
>> > >
>> > > It also gets us a round a couple of bootstrapping problems, where
>> > > generating some of those files requires a working Python interpreter,
>> > > which you may not have if you just cloned the source tree or unpacked
>> > > the tarball.
>> >
>> > We could distribute the generated files in tarballs as part of the
>> > release process.
>>
>> It's far more developer friendly to aim to have builds from a source
>> check-out "just work" if we can. That's pretty much where we are today
>> (getting external dependencies for the optional parts on *nix can still be
>> a bit fiddly - it may be worth maintaining instructions for at least apt
>> and yum in the developer guide that cover that)
>>
>> Cheers,
>> Nick.
>>
>
>
> _______________________________________________
> Python-Dev mailing list
> Python-Dev at python.org
> https://mail.python.org/mailman/listinfo/python-dev
> Unsubscribe:
> https://mail.python.org/mailman/options/python-dev/thomas%40python.org
>
>


-- 
Thomas Wouters <thomas at python.org>

Hi! I'm an email virus! Think twice before sending your email to help me
spread!
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/python-dev/attachments/20150125/958c9d93/attachment-0001.html>


More information about the Python-Dev mailing list