summaryrefslogtreecommitdiffstats
path: root/src/engine
diff options
context:
space:
mode:
authorSteven Knight <knight@baldmt.com>2004-10-06 04:04:12 (GMT)
committerSteven Knight <knight@baldmt.com>2004-10-06 04:04:12 (GMT)
commitdbc516410656ee3b584c6cd7d9c9d6921882d4b4 (patch)
tree86899649564bf5d47e24fddb9ad0e94ab9f6045b /src/engine
parent81d864dc3633dee1cc30af3e286f95d81956b7a5 (diff)
downloadSCons-dbc516410656ee3b584c6cd7d9c9d6921882d4b4.zip
SCons-dbc516410656ee3b584c6cd7d9c9d6921882d4b4.tar.gz
SCons-dbc516410656ee3b584c6cd7d9c9d6921882d4b4.tar.bz2
Better --debug=explain info when build actions change. (Kevin Quick)
Diffstat (limited to 'src/engine')
-rw-r--r--src/engine/SCons/Node/__init__.py11
1 files changed, 8 insertions, 3 deletions
diff --git a/src/engine/SCons/Node/__init__.py b/src/engine/SCons/Node/__init__.py
index 6e7379c..a4e1266 100644
--- a/src/engine/SCons/Node/__init__.py
+++ b/src/engine/SCons/Node/__init__.py
@@ -899,13 +899,18 @@ class Node:
if len(lines) == 0:
newact, newactsig = self.binfo.bact, self.binfo.bactsig
+ def fmt_with_title(title, strlines):
+ lines = string.split(strlines, '\n')
+ sep = '\n' + ' '*(15 + len(title))
+ return ' '*15 + title + string.join(lines, sep) + '\n'
if old.bactsig != newactsig:
if old.bact == newact:
- lines.append("the contents of the build action changed\n")
+ lines.append("the contents of the build action changed\n" +
+ fmt_with_title('action: ', newact))
else:
lines.append("the build action changed:\n" +
- "%sold: %s\n" % (' '*15, old.bact) +
- "%snew: %s\n" % (' '*15, newact))
+ fmt_with_title('old: ', old.bact) +
+ fmt_with_title('new: ', newact))
if len(lines) == 0:
return "rebuilding `%s' for unknown reasons" % self