Commit 9fe53a81 authored by Ben Mason's avatar Ben Mason Committed by Commit Bot

android: Allow bundle output path to be specified.

Defaults to "$root_build_dir/apks/" if base_bundle_path is not
specified.

Bug: 863113
Change-Id: Ia41ab38bce589ea95b462ec0ebf705c17ebd91a9
Reviewed-on: https://chromium-review.googlesource.com/1136987
Commit-Queue: Ben Mason <benmason@chromium.org>
Reviewed-by: default avatarDavid Turner <digit@chromium.org>
Reviewed-by: default avataragrieve <agrieve@chromium.org>
Cr-Commit-Position: refs/heads/master@{#575295}
parent 718282e6
......@@ -3429,6 +3429,13 @@ if (enable_java_templates) {
# the same content in its base module, though in a slightly different
# format.
#
# bundle_base_path: Optional. If set, the bundle will be output to this
# directory. Defaults to "$root_build_dir/apks".
#
# bundle_name: Optional. If set, the bundle will be output to the
# filename "${bundle_name}.aab". Also, if generate_apks is true
# "${bundle_name}.apks" will be used. Defaults to "${target_name}".
#
# extra_modules: Optional list of scopes, one per extra module used by
# this bundle. Each scope must have a 'name' field that specifies the
# module name (which cannot be 'base', since this is reserved for the
......@@ -3531,7 +3538,12 @@ if (enable_java_templates) {
_bundle_name = invoker.bundle_name
}
_bundle_path = "$target_gen_dir/$_bundle_name.aab"
_bundle_base_path = "$root_build_dir/apks"
if (defined(invoker.bundle_base_path)) {
_bundle_base_path = invoker.bundle_base_path
}
_bundle_path = "$_bundle_base_path/$_bundle_name.aab"
_rebased_bundle_path = rebase_path(_bundle_path, root_build_dir)
_sign_bundle = defined(invoker.sign_bundle) && invoker.sign_bundle
......@@ -3612,7 +3624,7 @@ if (enable_java_templates) {
_android_aapt2_path = android_sdk_tools_bundle_aapt2
_bundle_apks_target = "${target_name}_apks"
_bundle_apks_path = "$target_gen_dir/$_bundle_name.apks"
_bundle_apks_path = "$_bundle_base_path/$_bundle_name.apks"
# NOTE: Keep this consistent with the imports of app_bundle_to_apks.py
# note that resource_utils.py imports build_utils.py
......
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