[Scons-users] cache not working as expected for a recompile in another directory

William Blevins wblevins001 at gmail.com
Wed Nov 18 09:54:54 EST 2015


It's been a while since I looked through this code, but I might remember
places where you can look.

Node objects contain different descriptors: NodeInfoBase as ninfo (about
the node itself) and a BuildInfoBase binfo (about the build action against
the node).

Look at src/engine/SCons/Node/__init__.py

Keep in mind nodes could also be marked for rebuild for other reasons like
changing dependencies which sometimes happens in baselines which have code
generation and/or heterogeneous code baselines.

V/R,
William



On Wed, Nov 18, 2015 at 11:15 AM, Abt, Johannes <johannes.abt at advantest.com>
wrote:

> Hi,
>
>
> > To build on Tom's comment, *if* I remember correctly, a target signature
> consists of the entire commandline context; thus, A/A.c and B/Ac are
> different nodes even if the files are equivalent.
>
>
> In order to check your claim, I built the "helloworld" example (scons
> documentation) in different directories using "--cache-dir=<shared_dir>".
> In this trivial example, scons compiled (and linked) only once. It reused
> the cached objects.
>
>
> It looks like the build signature ((Is this even the right word for this
> concept in scons?) is independent from the relative path of the source
> files. I guess there is something else (settings? variables?).
>
>
> > If the compile command is the same and the input file is the same, you
> should really be asking yourself why you have two copies of this file.
> Consider making a library or at least a place for shared object files.
>
> The two directories contain different branches of the same project. I
> should have said so earlier, sorry.
>
>
> Does anybody know where I can find the code that calculates the "build
> signatures"?
>
>
> Regards,
>
> Johannes
>
>
> _______________________________________________
> Scons-users mailing list
> Scons-users at scons.org
> https://pairlist4.pair.net/mailman/listinfo/scons-users
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://pairlist4.pair.net/pipermail/scons-users/attachments/20151118/2a716be2/attachment-0001.html>


More information about the Scons-users mailing list