From ca675d3ec565477b2e3bae8b0709a412d029fa21 Mon Sep 17 00:00:00 2001 From: cjhopman Date: Thu, 23 Oct 2014 20:50:45 -0700 Subject: GN: Some small changes to support chrome android internal stuff This actually hooks up (i.e. passes from invoker) several variables controlling apk creation (version name, version code, use_relocation_packer, use_chromium_linker, unzip_libraries_from_apk). Adds support for overriding some configuration in the private repo. Adds support for public_configs in grit_rule.gni. Adds some junit targets (these are built as android libraries currently instead of host libraries, but that just means we do a bit extra work that we don't really need). BUG=359249 Review URL: https://codereview.chromium.org/659703002 Cr-Commit-Position: refs/heads/master@{#301039} --- build/config/android/config.gni | 20 ++++++++++++++++---- 1 file changed, 16 insertions(+), 4 deletions(-) (limited to 'build/config/android/config.gni') diff --git a/build/config/android/config.gni b/build/config/android/config.gni index 50cf8ba..e602083 100644 --- a/build/config/android/config.gni +++ b/build/config/android/config.gni @@ -5,12 +5,25 @@ # This file contains common system config stuff for the Android build. if (is_android) { + has_chrome_android_internal = exec_script("//build/dir_exists.py", + [ rebase_path("//clank", root_build_dir) ], + "string") == "True" + + if (has_chrome_android_internal) { + import("//clank/config.gni") + } else { + default_android_sdk_root = "//third_party/android_tools/sdk" + default_android_sdk_version = "21" + default_android_sdk_build_tools_version = "21.0.0" + } + declare_args() { # Absolute directory containing the Android source code. android_src = "" - android_sdk_root = "//third_party/android_tools/sdk" - android_sdk_version = "21" + android_sdk_root = default_android_sdk_root + android_sdk_version = default_android_sdk_version + android_sdk_build_tools_version = default_android_sdk_build_tools_version # This is set when building the Android WebView inside the Android build # system, using the 'android' gyp backend. The WebView code is still built @@ -32,7 +45,6 @@ if (is_android) { "You must specify android_src for an Android WebView build.") } - # Host stuff ----------------------------------------------------------------- # Defines the name the Android build gives to the current host CPU @@ -68,7 +80,7 @@ if (is_android) { android_sdk = "${android_sdk_root}/platforms/android-${android_sdk_version}" android_sdk_tools = "${android_sdk_root}/tools" - android_sdk_build_tools = "${android_sdk_root}/build-tools/21.0.0" + android_sdk_build_tools = "${android_sdk_root}/build-tools/$android_sdk_build_tools_version" # Path to the SDK's android.jar android_sdk_jar = "$android_sdk/android.jar" -- cgit v1.1