[Scons-users] dependency question

Dirk Bächle tshortik at gmx.de
Wed Jan 20 16:11:55 EST 2016


Hi Joshua,

On 20.01.2016 20:46, Joshua Schmiedlin wrote:
> Hello,
>
> I've used scons for about 10 years now, but am starting a new project with it and have run into something I'm not sure how to fix.
>
> I've setup my environment and exported it to several SConscript files, which are building a mixture of c and c++ code.  The issue
> I'm running into is that 1-3 files get rebuilt everytime, even though no changes have been made to them (i'm using the default md5
> decider).  In any case when I run with --debug=explain i get the following:
>
> *scons: rebuilding `build/x86/thirdparty/mbedtls-2.2.1/library/asn1parse.o' because:
>             `thirdparty/mbedtls-2.2.1/library/asn1parse.c' is no longer a dependency
>             `/usr/bin/clang' is no longer a dependency
>             `thirdparty/mbedtls-2.2.1/library/asn1parse.c' is a new dependency
>

this kind of error message ("foo is no longer a dependency", followed by "foo is a new dependency") hint at a problem with the order 
of the single dependencies. The content probably didn't change, but SCons finds the single files (=children) in a different order 
than in the previous run. This is enough to trigger a rebuild...
For the example above, it could be that in the second run (different $PATH setting, "/usr/bin" on a drive which goes into sleep 
mode, ...) the executable "/usr/bin/clang" isn't found in the system.
I hope this gives you (and others) a pointer in the right direction.

You could also try to set the environment variable

   env['IMPLICIT_COMMAND_DEPENDENCIES'] = False

and check whether this makes the errors go away.


Best regards,

Dirk



More information about the Scons-users mailing list