Commit 4fb8fc25 authored by Peter Wen's avatar Peter Wen Committed by Commit Bot

Android Studio: Run `gn gen` if necessary

Specifically when passing in targets manually. The `--all` flag (on by
default) already takes care of this case.

Bug: 620034
Change-Id: Ie5c679c6cf9b75e36415d2868f7fff46e9e81ad1
Reviewed-on: https://chromium-review.googlesource.com/1089121
Commit-Queue: Peter Wen <wnwen@chromium.org>
Commit-Queue: Eric Stevenson <estevenson@chromium.org>
Reviewed-by: default avatarEric Stevenson <estevenson@chromium.org>
Cr-Commit-Position: refs/heads/master@{#564979}
parent 13d087e7
...@@ -876,6 +876,9 @@ def main(): ...@@ -876,6 +876,9 @@ def main():
assert not args.native_targets, 'Native editing requires --all.' assert not args.native_targets, 'Native editing requires --all.'
targets = [re.sub(r'_test_apk$', '_test_apk__apk', t) targets = [re.sub(r'_test_apk$', '_test_apk__apk', t)
for t in targets_from_args] for t in targets_from_args]
# Necessary after "gn clean"
if not os.path.exists(os.path.join(output_dir, 'build_vars.txt')):
_RunGnGen(output_dir)
build_vars = _ReadPropertiesFile(os.path.join(output_dir, 'build_vars.txt')) build_vars = _ReadPropertiesFile(os.path.join(output_dir, 'build_vars.txt'))
jinja_processor = jinja_template.JinjaProcessor(_FILE_DIR) jinja_processor = jinja_template.JinjaProcessor(_FILE_DIR)
......
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