Chromium Code Reviews| OLD | NEW |
|---|---|
| (Empty) | |
| 1 #!/usr/bin/env python | |
| 2 # Copyright 2015 The Chromium Authors. All rights reserved. | |
| 3 # Use of this source code is governed by a BSD-style license that can be | |
| 4 # found in the LICENSE file. | |
| 5 | |
| 6 """Wrap //tools/gn/bin/gyp_flag_compare.py for the bots. | |
| 7 | |
| 8 This script wraps the GN test script in the facade needed for the | |
| 9 'ScriptTest' step class of the chromium recipe_module | |
| 10 (see scripts/slave/recipe_modules/chromium/steps.py in the build repo. | |
| 11 | |
| 12 The script takes N arguments, for the N targets to compare flags for. | |
| 13 """ | |
| 14 | |
| 15 import json | |
| 16 import os | |
| 17 import sys | |
| 18 | |
| 19 | |
| 20 import common | |
| 21 | |
| 22 | |
| 23 def main_run(args): | |
| 24 rc = common.run_command([sys.executable, | |
| 25 os.path.join(common.SRC_DIR, | |
| 26 'tools', 'gn', 'bin', | |
| 27 'gyp_flag_compare.py')] + args.args) | |
|
Dirk Pranke
2015/05/15 01:00:54
gyp_flag_compare.py takes a list of build targets
Paweł Hajdan Jr.
2015/05/15 10:14:07
FWIW I don't see any args being passed to this scr
Dirk Pranke
2015/05/15 15:09:40
Yeah, I didn't add the step at all to the json fil
| |
| 28 | |
| 29 json.dump({ | |
| 30 'valid': True, | |
| 31 'failures': [], | |
|
Paweł Hajdan Jr.
2015/05/15 10:14:07
Do you intend this to always pass? If there are an
Dirk Pranke
2015/05/15 15:09:40
same answer as the other one. eventually we might
| |
| 32 }, args.output) | |
| 33 | |
| 34 return rc | |
| 35 | |
| 36 | |
| 37 def main_compile_targets(args): | |
| 38 json.dump([], args.output) | |
| 39 | |
| 40 | |
| 41 if __name__ == '__main__': | |
| 42 funcs = { | |
| 43 'run': main_run, | |
| 44 'compile_targets': main_compile_targets, | |
| 45 } | |
| 46 sys.exit(common.run_script(sys.argv[1:], funcs)) | |
| OLD | NEW |