[Scons-users] Need help to improve the incremental build time while using SCons

Gary Granger granger at ucar.edu
Tue Jul 4 15:30:44 EDT 2017


I realize this is an aging thread, but I thought I'd offer one more
idea.  We have a tool to help speed up the edit-compile cycle where
you're trying to get one source file to compile successfully.  When a
compile command fails, the failed compile command is cached, so the next
time scons is run, it short circuits the rest of the SCons setup and
reruns the compile command directly.  If the command succeeds, then a
normal scons build is restarted to continue to the next compile failure,
and otherwise scons exits quickly so the developer can edit the file
some more.  There is an assumption that the only thing the developer is
changing is the source file being compiled, otherwise the full scons
needs to run to check all the dependencies.

Anyway, it seemed like an interesting idea, so we wrote a tool for it. 
You can find it here:

https://github.com/ncareol/eol_scons/blob/master/eol_scons/tools/rerun.py

It would need a little modification to divorce it from the eol_scons
package: the GlobalVariables() method is our own extension but could be
replaced or omitted.

Gary



More information about the Scons-users mailing list