Make building source files fail like Make.
authorstevenknight <stevenknight@fdb21ef1-2011-0410-befe-b5e4ea1792b1>
Sat, 23 Nov 2002 08:12:11 +0000 (08:12 +0000)
committerstevenknight <stevenknight@fdb21ef1-2011-0410-befe-b5e4ea1792b1>
Sat, 23 Nov 2002 08:12:11 +0000 (08:12 +0000)
git-svn-id: http://scons.tigris.org/svn/scons/trunk@503 fdb21ef1-2011-0410-befe-b5e4ea1792b1

src/CHANGES.txt
src/engine/SCons/Script/__init__.py
test/SideEffect.py
test/preserve-source.py

index d74788d594aaceef040f8e368a9a5757d8d69d0f..0c6325fed9d422e6a24d2f38f533eb0f5bb6af6d 100644 (file)
@@ -54,6 +54,8 @@ RELEASE 0.09 -
   - Add separate $SHOBJPREFIX and $SHOBJSUFFIX construction variables
     (by default, the same as $OBJPREFIX and $OBJSUFFIX).
 
+  - Add a Make-like message when asked to build a source file.
+
  From Steven Knight and Anthony Roach:
 
   - Man page:  document the fact that Builder calls return Node objects.
index 3f3ff8d8b521b3a24aea0a1d293a5b700a2a9682..814d147ce85490abc262d715ebba160696866a11 100644 (file)
@@ -105,6 +105,8 @@ class BuildTask(SCons.Taskmaster.Task):
 
     def executed(self):
         SCons.Taskmaster.Task.executed(self)
+        if not self.targets[0].builder and self.top:
+            print "scons: Nothing to be done for `%s'." % str(self.targets[0])
         # print the tree here instead of in execute() because
         # this method is serialized, but execute isn't:
         if print_tree and self.top:
index 6e37420335e2a8a330acd3dd2ace503519a9a58d..6337f6813ae52c19f31bc0ea5d479598280e620c 100644 (file)
@@ -70,6 +70,7 @@ test.write('bar.in', 'bar.in 2 \n')
 test.run(arguments = 'log.txt', stdout=test.wrap_stdout("""\
 copy() < bar.in > bar.out
 copy() < blat.in > blat.out
+scons: Nothing to be done for `log.txt'.
 """))
 
 expect = """\
index b0acdaa0fba0ad28a2a36d99f8c226d9c148c4ed..5eddeec26e5bc09288b950cbc3085c9021d76af7 100644 (file)
@@ -53,7 +53,8 @@ test.run(arguments = '.')
 test.fail_test(test.read('aaa.out') != "aaa.in\n")
 
 #
-test.run(arguments = "aaa.in", stdout = test.wrap_stdout(""))
+test.run(arguments = "aaa.in",
+         stdout = test.wrap_stdout("scons: Nothing to be done for `aaa.in'.\n"))
 
 test.fail_test(not os.path.exists('aaa.in'))