summaryrefslogtreecommitdiffstats
path: root/bin
diff options
context:
space:
mode:
authorSteven Knight <knight@baldmt.com>2010-01-16 15:27:15 (GMT)
committerSteven Knight <knight@baldmt.com>2010-01-16 15:27:15 (GMT)
commitefaa16e2305f89aae46bc55812445e581afaa547 (patch)
tree42c87d444256993c40d4549a5f440200da7c9b2d /bin
parent74bfce90f9b2af841e6291274c066e91f4a32ae7 (diff)
downloadSCons-efaa16e2305f89aae46bc55812445e581afaa547.zip
SCons-efaa16e2305f89aae46bc55812445e581afaa547.tar.gz
SCons-efaa16e2305f89aae46bc55812445e581afaa547.tar.bz2
Fix the Requires() examples by adding a sleep command to the
infrastructure and using it to force the SConstruct file(s) to generate version.c files with new timestamps each run. Fix the description of the example, since the verson.o file does get recompiled each run, but the use of Requires() means the downstream hello executable doesn't get relinked because of it.
Diffstat (limited to 'bin')
-rw-r--r--bin/scons-doc.py4
1 files changed, 4 insertions, 0 deletions
diff --git a/bin/scons-doc.py b/bin/scons-doc.py
index 6ea429b..e385b08 100644
--- a/bin/scons-doc.py
+++ b/bin/scons-doc.py
@@ -490,11 +490,15 @@ def command_ls(args, c, test, dict):
else:
return ls(test.workpath('WORK'))
+def command_sleep(args, c, test, dict):
+ time.sleep(int(args[0]))
+
CommandDict = {
'scons' : command_scons,
'touch' : command_touch,
'edit' : command_edit,
'ls' : command_ls,
+ 'sleep' : command_sleep,
}
def ExecuteCommand(args, c, t, dict):