diff options
author | bradnelson@google.com <bradnelson@google.com@0039d316-1c4b-4281-b951-d872f2087c98> | 2008-10-30 00:31:29 +0000 |
---|---|---|
committer | bradnelson@google.com <bradnelson@google.com@0039d316-1c4b-4281-b951-d872f2087c98> | 2008-10-30 00:31:29 +0000 |
commit | 282e2f7d5da27717e6fe05abd482237db0019e01 (patch) | |
tree | 6cc7563bc98506f67c1a0b2fc2b6113cdd1c9dfe /third_party/scons/scons-local/SCons/Subst.py | |
parent | c91a523e35cbbf233f82ae17a340b92459da5103 (diff) | |
download | chromium_src-282e2f7d5da27717e6fe05abd482237db0019e01.zip chromium_src-282e2f7d5da27717e6fe05abd482237db0019e01.tar.gz chromium_src-282e2f7d5da27717e6fe05abd482237db0019e01.tar.bz2 |
Moving to scons 1.1.0
Review URL: http://codereview.chromium.org/8900
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@4197 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'third_party/scons/scons-local/SCons/Subst.py')
-rw-r--r-- | third_party/scons/scons-local/SCons/Subst.py | 15 |
1 files changed, 12 insertions, 3 deletions
diff --git a/third_party/scons/scons-local/SCons/Subst.py b/third_party/scons/scons-local/SCons/Subst.py index d6dac31..df3942f 100644 --- a/third_party/scons/scons-local/SCons/Subst.py +++ b/third_party/scons/scons-local/SCons/Subst.py @@ -27,7 +27,7 @@ SCons string substitution. # WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. # -__revision__ = "src/engine/SCons/Subst.py 3424 2008/09/15 11:22:20 scons" +__revision__ = "src/engine/SCons/Subst.py 3603 2008/10/10 05:46:45 scons" import re import string @@ -270,7 +270,13 @@ def subst_dict(target, source): dict = {} if target: - tnl = NLWrapper(target, lambda x: x.get_subst_proxy()) + def get_tgt_subst_proxy(thing): + try: + subst_proxy = thing.get_subst_proxy() + except AttributeError: + subst_proxy = thing # probably a string, just return it + return subst_proxy + tnl = NLWrapper(target, get_tgt_subst_proxy) dict['TARGETS'] = Targets_or_Sources(tnl) dict['TARGET'] = Target_or_Source(tnl) else: @@ -285,7 +291,10 @@ def subst_dict(target, source): pass else: node = rfile() - return node.get_subst_proxy() + try: + return node.get_subst_proxy() + except AttributeError: + return node # probably a String, just return it snl = NLWrapper(source, get_src_subst_proxy) dict['SOURCES'] = Targets_or_Sources(snl) dict['SOURCE'] = Target_or_Source(snl) |