Open
Description
This issue was originally created at: 2011-03-28 16:34:01.
This issue was reported by: stever_
.
stever_ said at 2011-03-28 16:34:01
There seems to be an inconsistency in handling options that take values when they're specified without an '='. This seems to be caused by the loop in _main
that assigns anything that doesn't start with '-' or have an '=' in it to COMMAND_LINE_TARGETS
, rather than letting the option parser figure it out properly.
Here's an example SConscript:
import sys
AddOption('--option')
print('option:', GetOption('option'))
print('targets:', COMMAND_LINE_TARGETS)
sys.exit(0)
'''
And here's the problem:
% scons --option=FOO BAR
scons: Reading SConscript files ...
option: FOO
targets: ['BAR']
% scons --option FOO BAR
scons: Reading SConscript files ...
option: FOO
targets: ['FOO', 'BAR']
>ipatrol said this issue blocks #2763 at 2011-05-14 12:29:10.