fnode = File(u'foo.txt')

def funcact(target, source, env):
    with open(str(target[0]), 'wb') as f:
        f.write(b"funcact\n")
    for i in range(300):
        pass
    return 0

env = Environment()

env.Command(fnode, [], ["echo $TARGET", funcact])
