[Scons-users] Rebuild changed targets
Mike S.
rulen1 at gmail.com
Fri Mar 22 14:26:30 EDT 2013
For some reason SCons doesn't regenerate an intermediate target if it's
modified. Am I doing something wrong?
# SConstruct ==========================================
import shutil
def copy_file(env, target, source):
shutil.copy(env.GetBuildPath(source[0]), env.GetBuildPath(target[0]))
env = Environment()
env.Decider('content')
copy_builder = env.Builder( action = copy_file )
copy_builder(env, 'dest1/dummy.txt', 'src/dummy.txt')
copy_builder(env, 'dest2/dummy.txt', 'dest1/dummy.txt')
# ======================================================
$ scons
scons: Reading SConscript files ...
scons: done reading SConscript files.
scons: Building targets ...
copy_file(["dest1\dummy.txt"], ["src\dummy.txt"])
copy_file(["dest2\dummy.txt"], ["dest1\dummy.txt"])
scons: done building targets.
$ echo "abc" >> dest1/dummy.txt
$ scons
scons: Reading SConscript files ...
scons: done reading SConscript files.
scons: Building targets ...
copy_file(["dest2\dummy.txt"], ["dest1\dummy.txt"])
scons: done building targets.
I expected dest1\dummy.txt to be regenerated because it is no longer
consistent with src\dummy.txt
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://four.pairlist.net/pipermail/scons-users/attachments/20130322/69f86458/attachment-0001.html>
More information about the Scons-users
mailing list