[Scons-users] Question about binfo
Dirk Bächle
tshortik at gmx.de
Thu Feb 25 16:05:56 EST 2016
Hi Tom,
On 25.02.2016 16:55, Tom Tanner (BLOOMBERG/ LONDON) wrote:
> In the Node/__init__.py, in the clear() method, it says this:
>
> # The del_binfo() call here isn't necessary for normal execution,
> # but is for interactive mode, where we might rebuild the same
> # target and need to start from scratch.
> self.del_binfo()
>
> This is causing me some interesting problems. I'm trying to stash the *ENTIRE* command line used to build an object (partly for
> rerunning commands, partly for getting better details of actual command line changes rather than the rather brief summary produced
> currently).
>
> Actually calculating the command line seems to be somewhat expensive (you would not believe the length of one of ours) so I wanted
> to only calculate it on an as needed basis and then stick it in the nodes binfo so it gets saved the the .scons.dblite file.
>
> But that line above stops this working. And I'm not sure I see the point of it. If 'interactive' should repeatedly build an object
> even if nothing has changed, wouldn't it be better to delete the object instead?
>
the basic idea behind this is to save time in the "Interactive mode". All SConstructs/SConscripts get read only once, and from then
on you assume that the underlying graph of file nodes, and their dependencies among each other and to the created build
environments, doesn't change anymore.
This enables you to work with small code-compile cycles in very large codebases, where you fire up "interactive mode" and then
repeatedly build the node (program/lib) you're currently interested in.
For this to work properly, SCons has to keep the Node, but reset all info about whether the Node is up-to-date or not. This is what
is meant by "starting from scratch"...
Hope this explains a few things.
Best regards,
Dirk
More information about the Scons-users
mailing list