diff options
author | cjhopman <cjhopman@chromium.org> | 2014-09-23 17:52:56 -0700 |
---|---|---|
committer | Commit bot <commit-bot@chromium.org> | 2014-09-24 00:53:11 +0000 |
commit | 2fd48fd14b188a0b854f9c5910b9f40b5576291f (patch) | |
tree | 4082eb5d58cf03aa528b69abad5151cde40b3ffd /content/shell | |
parent | f3e00b33be7782d91d1b8dc01e361299a9e656cf (diff) | |
download | chromium_src-2fd48fd14b188a0b854f9c5910b9f40b5576291f.zip chromium_src-2fd48fd14b188a0b854f9c5910b9f40b5576291f.tar.gz chromium_src-2fd48fd14b188a0b854f9c5910b9f40b5576291f.tar.bz2 |
Make content_shell_apk build completely
This fixes configuration of various targets (mostly adding some missing
files for is_android builds).
Adds a target setting up the content_shell_apk assets directory.
Uncomments the previously non-working dependencies from
libcontent_shell_content_view.
Adds forwarding of testonly in all of the android templates.
TBR=mark@
BUG=359249
Review URL: https://codereview.chromium.org/569923003
Cr-Commit-Position: refs/heads/master@{#296319}
Diffstat (limited to 'content/shell')
-rw-r--r-- | content/shell/BUILD.gn | 10 | ||||
-rw-r--r-- | content/shell/android/BUILD.gn | 46 |
2 files changed, 37 insertions, 19 deletions
diff --git a/content/shell/BUILD.gn b/content/shell/BUILD.gn index 082b2af..44c338a 100644 --- a/content/shell/BUILD.gn +++ b/content/shell/BUILD.gn @@ -431,13 +431,9 @@ repack("pak") { "//ui/strings", ] - if (is_android) { - output = "$root_out_dir/content_shell/assets/content_shell.pak" - } else { - sources += [ "$root_gen_dir/webkit/devtools_resources.pak" ] - deps += [ "//content/browser/devtools:resources" ] - output = "$root_out_dir/content_shell.pak" - } + sources += [ "$root_gen_dir/webkit/devtools_resources.pak" ] + deps += [ "//content/browser/devtools:resources" ] + output = "$root_out_dir/content_shell.pak" } # TODO(GYP): Figure out what this should be on android diff --git a/content/shell/android/BUILD.gn b/content/shell/android/BUILD.gn index 47b3d61..611bc02 100644 --- a/content/shell/android/BUILD.gn +++ b/content/shell/android/BUILD.gn @@ -4,6 +4,7 @@ import("//build/config/android/config.gni") import("//build/config/android/rules.gni") +import("//third_party/icu/config.gni") generate_jni("content_shell_jni_headers") { jni_package = "content/shell" @@ -16,17 +17,18 @@ generate_jni("content_shell_jni_headers") { } shared_library("libcontent_shell_content_view") { - # TODO(GYP,cjhopman): enable these when content_shell builds + testonly = true deps = [ ":content_shell_jni_headers", -#"//content/shell:content_shell", -#"//content/shell:content_shell_pak", + "//content/shell:content_shell_lib", + "//content/shell:pak", + "//components/crash/browser", "//skia", "//media/base/android", ] sources = [ -#"shell_library_loader.cc", -#"shell_library_loader.h", + "shell_library_loader.cc", + "shell_library_loader.h", ] if (is_android_webview_build) { ldflags = [ @@ -36,11 +38,13 @@ shared_library("libcontent_shell_content_view") { } android_resources("content_shell_java_resources") { + testonly = true resource_dirs = [ "java/res" ] custom_package = "org.chromium.content_shell" } android_library("content_shell_java") { + testonly = true deps = [ "//base:base_java", "//content/public/android:content_java", @@ -53,6 +57,7 @@ android_library("content_shell_java") { } android_resources("content_shell_apk_resources") { + testonly = true resource_dirs = [ "shell_apk/res" ] deps = [ ":content_shell_java_resources" @@ -61,6 +66,7 @@ android_resources("content_shell_apk_resources") { } android_library("content_shell_apk_java") { + testonly = true deps = [ ":content_shell_apk_resources", ":content_shell_java", @@ -73,7 +79,23 @@ android_library("content_shell_apk_java") { DEPRECATED_java_in_dir = "shell_apk/src" } +content_shell_assets_dir = "$root_build_dir/content_shell/assets" +copy_ex("copy_content_shell_assets") { + clear_dir = true + dest = content_shell_assets_dir + sources = [ + "$root_out_dir/content_shell.pak" + ] + + if (icu_use_data_file) { + sources += [ + "$root_build_dir/icudtl.dat" + ] + } +} + android_apk("content_shell_apk") { + testonly = true datadeps = [ # "//tools/android/forwarder", ] @@ -82,9 +104,9 @@ android_apk("content_shell_apk") { ":content_shell_java", ":content_shell_apk_java", ":libcontent_shell_content_view", + ":copy_content_shell_assets", "//base:base_java", "//content/public/android:content_java", - "//content/public/android:content_java_resources", "//media/base/android:media_java", "//net/android:net_java", #"//third_party/mesa:osmesa_in_lib_dir", @@ -95,22 +117,18 @@ android_apk("content_shell_apk") { native_libs = [ "$root_build_dir/lib.stripped/libcontent_shell_content_view.so" ] - asset_location = "$root_build_dir/content_shell/assets" + asset_location = content_shell_assets_dir # TODO(GYP) - #'additional_input_paths': ['<(PRODUCT_DIR)/content_shell/assets/content_shell.pak'], #'extra_native_libs': ['<(SHARED_LIB_DIR)/libosmesa.so'], - if (false && icu_use_data_file_flag) { - # TODO(GYP) - } - if (is_android_webview_build) { # TODO(GYP) } } android_library("content_shell_test_java") { + testonly = true deps = [ ":content_shell_java", ":content_shell_apk_java", @@ -124,11 +142,15 @@ android_library("content_shell_test_java") { } android_apk("content_shell_test_apk") { + testonly = true deps = [ "//content/public/android:content_javatests", "//base:base_javatests", "//net/android:net_javatests", ] + datadeps = [ + ":content_shell_apk", + ] apk_name = "ContentShellTest" android_manifest = "javatests/AndroidManifest.xml" } |