[Scons-users] Generating header from cpp file causes cycle
tshortik at gmx.de
Tue Mar 21 04:27:15 EDT 2017
Jean-Baptiste explained the underlying problem nicely. There is nothing you've done wrong...neither is it a bug in SCons.
It just happens to be one of those builds where you have to tell your build system more explicitly what you want.
Based on your Makefile, I'd suggest to break the dep cycle by setting the CPPPATH variable empty, such that no implicit header dependencies can get found. Then you add an explicit dependency of your final program (or the intermediate object ) to the generated "test.h" via the env.Depends() method.
This should then give you the same behaviour as your Makefile does. Since this can get cumbersome pretty fast, you probably want to wrap these steps in a pseudo-Builder.
Hope this helps and best regards,
Sent from my Android with K-9 Mail.
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the Scons-users