Commit f66e5510 authored by Yoshisato Yanagisawa's avatar Yoshisato Yanagisawa Committed by Commit Bot

autoninja: support -j100 and -tclean.

Since ninja uses getopt_long to parse the argument, we need to suppose
-j100 and -tclean.
Please see ReadFlags function in:
https://github.com/ninja-build/ninja/blob/master/src/ninja.cc

Change-Id: If61f05e66be546a591549f6f153cce994c972309
Reviewed-on: https://chromium-review.googlesource.com/c/1335428Reviewed-by: 's avatarTakuto Ikuta <tikuta@chromium.org>
Reviewed-by: 's avatarBruce Dawson <brucedawson@chromium.org>
Commit-Queue: Bruce Dawson <brucedawson@chromium.org>
parent ef71a5f0
......@@ -32,10 +32,13 @@ input_args = sys.argv
if (sys.platform.startswith('win') and len(sys.argv) == 2 and
input_args[1].count(' ') > 0):
input_args = sys.argv[:1] + sys.argv[1].split()
# Ninja uses getopt_long, which allow to intermix non-option arguments.
# To leave non supported parameters untouched, we do not use getopt.
for index, arg in enumerate(input_args[1:]):
if arg == '-j':
if arg.startswith('-j'):
j_specified = True
if arg == '-t':
if arg.startswith('-t'):
t_specified = True
if arg == '-C':
# + 1 to get the next argument and +1 because we trimmed off input_args[0]
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment