From efb0071db2ef9b2ef9687e1353724ed18db1ee9b Mon Sep 17 00:00:00 2001 From: Gary Oberbrunner Date: Tue, 1 Mar 2011 01:01:47 +0000 Subject: New debug option --debug=duplicate to debug Variant-dir duplication --- doc/man/scons.1 | 6 ++++++ doc/user/troubleshoot.in | 23 +++++++++++++++++++++++ doc/user/troubleshoot.xml | 22 ++++++++++++++++++++++ src/CHANGES.txt | 4 ++++ src/RELEASE.txt | 2 ++ src/engine/SCons/Node/FS.py | 7 +++++++ src/engine/SCons/Script/Main.py | 2 ++ src/engine/SCons/Script/SConsOptions.py | 2 +- 8 files changed, 67 insertions(+), 1 deletion(-) diff --git a/doc/man/scons.1 b/doc/man/scons.1 index 3fa9e0c..62129ad 100644 --- a/doc/man/scons.1 +++ b/doc/man/scons.1 @@ -601,6 +601,12 @@ have been compiled with optimization files). .TP +--debug=duplicate +Print a line for each unlink/relink (or copy) of a variant file from +its source file. Includes debugging info for unlinking stale variant +files, as well as unlinking old targets before building them. + +.TP --debug=dtree A synonym for the newer .B --tree=derived diff --git a/doc/user/troubleshoot.in b/doc/user/troubleshoot.in index b0e8681..b237cbb 100644 --- a/doc/user/troubleshoot.in +++ b/doc/user/troubleshoot.in @@ -857,8 +857,31 @@ +
+ + Why is a file disappearing? the --debug=duplicate Option + + + + When using the &Duplicate; option to create variant dirs, + sometimes you may find files not getting copied to where you + expect (or not at all), or files mysteriously disappearing. These + are usually because of a misconfiguration of some kind in the + SConstruct/SConscript, but they can be tricky to debug. The + --debug=duplicate option shows each time a variant file is + unlinked and relinked from its source (or copied, depending on + settings), and also shows a message for removing "stale" + variant-dir files that no longer have a corresponding source file. + It also prints a line for each target that's removed just before + building, since that can also be mistaken for the same thing. + + + +
+