| Index: components/cronet/ios/BUILD.gn
|
| diff --git a/components/cronet/ios/BUILD.gn b/components/cronet/ios/BUILD.gn
|
| index ac1dfe0620298748e245c9330e3e21cebd106045..43cd95f0ac15243fed64e63585b684684847e211 100644
|
| --- a/components/cronet/ios/BUILD.gn
|
| +++ b/components/cronet/ios/BUILD.gn
|
| @@ -71,6 +71,52 @@ tweak_info_plist("tweak_cronet_plist") {
|
| info_plist = "Info.plist"
|
| }
|
|
|
| +_deps = [
|
| + ":cronet_version_header",
|
| + ":generate_accept_languages",
|
| + "//base:base",
|
| + "//components/grpc_support",
|
| + "//components/metrics:metrics",
|
| + "//components/metrics/proto:proto",
|
| + "//components/prefs:prefs",
|
| + "//ios/net:net",
|
| + "//ios/web:user_agent",
|
| + "//net",
|
| + "//url",
|
| +]
|
| +
|
| +static_library("cronet_static") {
|
| + deps = _deps
|
| +
|
| + visibility = [ ":*" ]
|
| +
|
| + include_dirs = [ "//components/grpc_support/include" ]
|
| +
|
| + public_deps = [
|
| + "//components/grpc_support",
|
| + ]
|
| +
|
| + public_headers = [
|
| + "Cronet.h",
|
| + "cronet_c_for_grpc.h",
|
| + ]
|
| + public_headers += grpc_public_headers
|
| +
|
| + sources = [
|
| + "../histogram_manager.cc",
|
| + "../histogram_manager.h",
|
| + "../stale_host_resolver.cc",
|
| + "../stale_host_resolver.h",
|
| + "../url_request_context_config.cc",
|
| + "../url_request_context_config.h",
|
| + "Cronet.h",
|
| + "Cronet.mm",
|
| + "cronet_c_for_grpc.h",
|
| + "cronet_environment.h",
|
| + "cronet_environment.mm",
|
| + ]
|
| +}
|
| +
|
| ios_framework_bundle("cronet_framework") {
|
| output_name = "Cronet"
|
| info_plist_target = ":tweak_cronet_plist"
|
| @@ -135,6 +181,51 @@ action("generate_accept_languages") {
|
| ]
|
| }
|
|
|
| +# A static library which contains all dependencies of :cronet_static.
|
| +static_library("deps_complete") {
|
| + visibility = [ ":*" ]
|
| + complete_static_lib = true
|
| + deps = _deps
|
| +}
|
| +
|
| +config("cronet_config") {
|
| + libs = [
|
| + "$target_out_dir/libcronet.a",
|
| + "UIKit.Framework",
|
| + "CFNetwork.framework",
|
| + "MobileCoreServices.framework",
|
| + "Security.framework",
|
| + "SystemConfiguration.framework",
|
| + "resolv",
|
| + ]
|
| +}
|
| +
|
| +action("lib_cronet") {
|
| + script = "//components/cronet/tools/hide_symbols.py"
|
| + deps = [
|
| + ":cronet_static",
|
| + ":deps_complete",
|
| + ]
|
| + outputs = [
|
| + "$target_out_dir/libcronet.a",
|
| + "$target_out_dir/libcronet.o",
|
| + ]
|
| + args = [
|
| + "--input_libs",
|
| + rebase_path("$target_out_dir/libcronet_static.a", root_build_dir),
|
| + "--deps_lib",
|
| + rebase_path("$target_out_dir/libdeps_complete.a", root_build_dir),
|
| + "--output_obj",
|
| + rebase_path("$target_out_dir/libcronet.o", root_build_dir),
|
| + "--output_lib",
|
| + rebase_path("$target_out_dir/libcronet.a", root_build_dir),
|
| + "--current_cpu",
|
| + current_cpu,
|
| + ]
|
| +
|
| + public_configs = [ ":cronet_config" ]
|
| +}
|
| +
|
| if (additional_toolchains == [] || current_toolchain == default_toolchain) {
|
| _package_dir = "$root_out_dir/cronet"
|
|
|
| @@ -161,6 +252,7 @@ if (additional_toolchains == [] || current_toolchain == default_toolchain) {
|
| copy("cronet_package_copy") {
|
| sources = [
|
| "$root_out_dir/Cronet.framework",
|
| + "$target_out_dir/libcronet.a",
|
| "//AUTHORS",
|
| "//chrome/VERSION",
|
| ]
|
| @@ -170,6 +262,7 @@ if (additional_toolchains == [] || current_toolchain == default_toolchain) {
|
|
|
| deps = [
|
| ":cronet_framework",
|
| + ":lib_cronet",
|
| ]
|
| }
|
|
|
| @@ -210,6 +303,7 @@ if (additional_toolchains == [] || current_toolchain == default_toolchain) {
|
| ":cronet_dsym_archive",
|
| ":cronet_package_copy",
|
| ":generate_license",
|
| + "//components/cronet/ios/sample:cronet_sample",
|
| ]
|
| }
|
| }
|
|
|