| # Copyright 2020 The Chromium OS Authors. All rights reserved. |
| # Use of this source code is governed by a BSD-style license that can be |
| # found in the LICENSE file. |
| |
| # This is needed because gn raises error when toolchain is not set. |
| import("//build/util/android.gni") |
| set_default_toolchain("//build/toolchain:android") |
| |
| android_sdk_path = getenv("ANDROID_SDK") |
| if (android_sdk_path == "") { |
| android_sdk_path = "/opt/android-sdk" |
| } |
| |
| android_build_tools = getenv("ANDROID_BUILD_TOOLS") |
| if (android_build_tools == "") { |
| android_build_tools = "${android_sdk_path}/build-tools/android-S" |
| } |
| |
| # Targets can override this value with "compile_sdk_version". |
| android_platform = getenv("ANDROID_PLATFORM") |
| if (android_platform == "") { |
| android_platform = "${android_sdk_path}/platforms/android-S/android.jar" |
| } |
| |
| android_key_env = getenv("ANDROID_KEY_ENV") |
| if (android_key_env == "") { |
| android_key_env = "test" |
| } |
| |
| android_cert = "//certs" |