Author vstinner
Recipients Chi Hsuan Yen, berker.peksag, brett.cannon, ezio.melotti, josh.r, koobs, martin.panter, ncoghlan, ned.deily, python-dev, vlee, vstinner, willingc, zach.ware
Date 2017-05-02.23:44:13
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1493768654.09.0.934427250887.issue23404@psf.upfronthosting.co.za>
In-reply-to
Content
I rewrote Python (UNIX/BSD) build system to not rebuild generated files based on file modification time: the action is now explicit. This change should not only fix buildbots, but also ease cross-compilation, and more generally make Python build less painful! No more funny error when the system only provides Python 2.6 and so "make touch" doesn't work, whereas "make touch" was the obvious workaround to avoid trying to regenerated files.

The change:
https://github.com/python/cpython/pull/1405

My change adds a global "rebuild-all", but this command is made of multiple subcommands:
    
      - rebuild-ast: Include/Python-ast.h and Python/Python-ast.c
      - rebuild-grammar: Include/graminit.h and Python/graminit.c
      - rebuild-importlib: Python/importlib_external.h and Python/importlib.h
      - rebuild-opcode: Include/opcode.h
      - rebuild-opcode-targets: Python/opcode_targets.h
      - rebuild-typeslots: Objects/typeslots.inc

rebuild-all is not needed if you only want to update AST for example: just run "make rebuild-ast && make".

--

As you may expect, the change is quite big for a very sensitive part of Python: the build system. Do we want to backport such major change?

Another solution for stable branches to to remove the rebuild of generated files from configure and Makefile... Just hope that we will not need it anymore? Not sure if it's a good idea. I expect fixes in importlib, so "rebuild-importlib" will be needed at least.

Even if I don't trust my own work(!), I would suggest to review carefully my change, test it on all buildbots, play with it, and then backport it to 2.7, 3.5 and 3.6.

Note: Windows is not affected by this bug, right?
History
Date User Action Args
2017-05-02 23:44:14vstinnersetrecipients: + vstinner, brett.cannon, ncoghlan, ned.deily, ezio.melotti, python-dev, berker.peksag, martin.panter, zach.ware, koobs, willingc, josh.r, vlee, Chi Hsuan Yen
2017-05-02 23:44:14vstinnersetmessageid: <1493768654.09.0.934427250887.issue23404@psf.upfronthosting.co.za>
2017-05-02 23:44:14vstinnerlinkissue23404 messages
2017-05-02 23:44:13vstinnercreate