From: stevenknight Date: Sun, 25 Jan 2004 02:07:36 +0000 (+0000) Subject: Fix ARGUMENTS specifications on the command line that have multiple = in them. ... X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=e2f06e01debc7865a4ad2748043ee478943fa65b;p=scons.git Fix ARGUMENTS specifications on the command line that have multiple = in them. (Zephaniah Hull) git-svn-id: http://scons.tigris.org/svn/scons/trunk@885 fdb21ef1-2011-0410-befe-b5e4ea1792b1 --- diff --git a/src/CHANGES.txt b/src/CHANGES.txt index f03e7bd2..ffcfe919 100644 --- a/src/CHANGES.txt +++ b/src/CHANGES.txt @@ -84,6 +84,10 @@ RELEASE 0.95 - XXX of them from cache, not just the first target, and exec the build command if any of the targets isn't present in the cache. + From Zephaniah Hull: + + - Fix command-line ARGUMENTS with multiple = in them. + From Steven Knight: - Fix EnsureSConsVersion() so it checks against the SCons version, diff --git a/src/engine/SCons/Script/SConscript.py b/src/engine/SCons/Script/SConscript.py index 521429f2..90e1fe17 100644 --- a/src/engine/SCons/Script/SConscript.py +++ b/src/engine/SCons/Script/SConscript.py @@ -86,7 +86,7 @@ sconscript_reading = 0 def _scons_add_args(alist): for arg in alist: - a, b = string.split(arg, '=', 2) + a, b = string.split(arg, '=', 1) Arguments[a] = b def _scons_add_targets(tlist): diff --git a/test/ARGUMENTS.py b/test/ARGUMENTS.py index ab1f806d..69947a66 100644 --- a/test/ARGUMENTS.py +++ b/test/ARGUMENTS.py @@ -37,11 +37,12 @@ for k in keys: foo.close() """) -test.run(arguments='a=1 bz=3 xx=sd .') +test.run(arguments='a=1 bz=3 xx=sd zzz=foo=bar .') test.fail_test(test.read('foo.out') != """a = 1 bz = 3 xx = sd +zzz = foo=bar """) test.pass_test()