[Python-Dev] [Python-checkins] commit of r41880 - python/trunk/Python/Python-ast.c

Donovan Baarda abo at minkirri.apana.org.au
Tue Jan 3 13:13:23 CET 2006


On Mon, 2006-01-02 at 15:16 -0800, Neal Norwitz wrote:
> On 1/2/06, Barry Warsaw <barry at python.org> wrote:
> > I think we have a fundamental problem with Python-ast.c and
> > Python-ast.h.  These files should not be both auto-generated and checked
> > into Subversion.
> 
> I agree with the problem statement.
> 
> > The general rule should be that no file that is ever generated can be
> > checked into Subversion.  Probably the right approach is to check in a
> > template file that will not get removed by a distclean, and modify the
> > build process to generate Python-ast.* from those template files.
> 
> I'm not sure about your proposed solution, though.
> 
> There's a bootstrapping issue.  Python-ast.[ch] are generated by a
> python 2.2+ script.  /f created a bug report if only 2.1 is available.
> 
> The Python-ast.[ch] should probably not be removed by distclean.  This
> is similar to configure.  Would that make you happy?  What else would
> improve the current situation?
> 
> If you go the template route, you would just copy the files. That
> doesn't seem to gain anything.

The solution I use is to never have anything auto-generated in CVS/SVN,
but have "make dist" generate and include anything needed for
bootstrapping in the distribution tarball (or whatever). Doing "make
distclean" should delete enough to bring you back to a freshly extracted
distribution tarball, and "make maintainer-clean" should delete all
auto-generated files to bring you back to a clean CVS/SVN checkout.

I tend to include quite a few generated files in the distribution
tarball that are not in CVS/RCS. Things like ChangeList (generated by
cvs2cl), all the autotools autogen'ed files, generated datafiles, etc.

This way your source distributions don't have any bootstrap problems,
but you also don't have any auto-generated files in CVS/SVN and the
problems they create. It does however mean that a fresh CVS/SVN checkout
does have additional build requirements above and beyond building from a
source distribution.

-- 
Donovan Baarda <abo at minkirri.apana.org.au>
http://minkirri.apana.org.au/~abo/



More information about the Python-Dev mailing list