| OLD | NEW |
| 1 # Copyright 2015 The Chromium Authors. All rights reserved. | 1 # Copyright 2015 The Chromium Authors. All rights reserved. |
| 2 # Use of this source code is governed by a BSD-style license that can be | 2 # Use of this source code is governed by a BSD-style license that can be |
| 3 # found in the LICENSE file. | 3 # found in the LICENSE file. |
| 4 | 4 |
| 5 import("//build/buildflag_header.gni") | 5 import("//build/buildflag_header.gni") |
| 6 import("//build/config/android/config.gni") | 6 import("//build/config/android/config.gni") |
| 7 import("//build/config/android/rules.gni") | 7 import("//build/config/android/rules.gni") |
| 8 import("//build/util/version.gni") | 8 import("//build/util/version.gni") |
| 9 import("//chrome/version.gni") | 9 import("//chrome/version.gni") |
| 10 import("//testing/test.gni") | 10 import("//testing/test.gni") |
| (...skipping 384 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 395 "//base:base_java", | 395 "//base:base_java", |
| 396 "//third_party/jsr-305:jsr_305_javalib", | 396 "//third_party/jsr-305:jsr_305_javalib", |
| 397 ] | 397 ] |
| 398 | 398 |
| 399 run_findbugs_override = true | 399 run_findbugs_override = true |
| 400 if (!is_java_debug) { | 400 if (!is_java_debug) { |
| 401 proguard_enabled = true | 401 proguard_enabled = true |
| 402 proguard_configs = [ | 402 proguard_configs = [ |
| 403 "proguard.cfg", | 403 "proguard.cfg", |
| 404 "sample/javatests/proguard.cfg", | 404 "sample/javatests/proguard.cfg", |
| 405 "//base/android/base_proguard_config.flags", |
| 405 ] | 406 ] |
| 406 } | 407 } |
| 407 } | 408 } |
| 408 | 409 |
| 409 # cronet_sample_test_apk_resources is identical to | 410 # cronet_sample_test_apk_resources is identical to |
| 410 # cronet_sample_apk_resources. The two have to be different targets because | 411 # cronet_sample_apk_resources. The two have to be different targets because |
| 411 # targets which are common between the "instrumentation test apk" and the | 412 # targets which are common between the "instrumentation test apk" and the |
| 412 # "tested apk" are removed from the "instrumentation test apk". | 413 # "tested apk" are removed from the "instrumentation test apk". |
| 413 android_resources("cronet_sample_test_apk_resources") { | 414 android_resources("cronet_sample_test_apk_resources") { |
| 414 resource_dirs = [ "sample/res" ] | 415 resource_dirs = [ "sample/res" ] |
| (...skipping 295 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 710 ":cronet_perf_test_apk_java", | 711 ":cronet_perf_test_apk_java", |
| 711 ":cronet_test_apk_java", | 712 ":cronet_test_apk_java", |
| 712 "//base:base_java", | 713 "//base:base_java", |
| 713 ] | 714 ] |
| 714 | 715 |
| 715 run_findbugs_override = true | 716 run_findbugs_override = true |
| 716 proguard_enabled = true | 717 proguard_enabled = true |
| 717 proguard_configs = [ | 718 proguard_configs = [ |
| 718 "proguard.cfg", | 719 "proguard.cfg", |
| 719 "test/javaperftests/proguard.cfg", | 720 "test/javaperftests/proguard.cfg", |
| 721 "//base/android/base_proguard_config.flags", |
| 720 ] | 722 ] |
| 721 } | 723 } |
| 722 | 724 |
| 723 test("cronet_unittests") { | 725 test("cronet_unittests") { |
| 724 sources = [ | 726 sources = [ |
| 725 "//components/cronet/android/cert/cert_verifier_cache_serializer_unittest.cc
", | 727 "//components/cronet/android/cert/cert_verifier_cache_serializer_unittest.cc
", |
| 726 "//components/cronet/histogram_manager_unittest.cc", | 728 "//components/cronet/histogram_manager_unittest.cc", |
| 727 "//components/cronet/run_all_unittests.cc", | 729 "//components/cronet/run_all_unittests.cc", |
| 728 "//components/cronet/stale_host_resolver_unittest.cc", | 730 "//components/cronet/stale_host_resolver_unittest.cc", |
| 729 "//components/cronet/url_request_context_config_unittest.cc", | 731 "//components/cronet/url_request_context_config_unittest.cc", |
| (...skipping 164 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 894 ":cronet_javadoc_classpath", | 896 ":cronet_javadoc_classpath", |
| 895 ":jar_cronet_api_source", | 897 ":jar_cronet_api_source", |
| 896 ] | 898 ] |
| 897 } | 899 } |
| 898 | 900 |
| 899 copy("cronet_package_copy") { | 901 copy("cronet_package_copy") { |
| 900 sources = [ | 902 sources = [ |
| 901 "$root_out_dir/lib.java/components/cronet/android/cronet_api.jar", | 903 "$root_out_dir/lib.java/components/cronet/android/cronet_api.jar", |
| 902 "//AUTHORS", | 904 "//AUTHORS", |
| 903 "//chrome/VERSION", | 905 "//chrome/VERSION", |
| 904 "//components/cronet/android/proguard.cfg", | |
| 905 ] | 906 ] |
| 906 outputs = [ | 907 outputs = [ |
| 907 "$_package_dir/{{source_file_part}}", | 908 "$_package_dir/{{source_file_part}}", |
| 908 ] | 909 ] |
| 909 | 910 |
| 910 deps = [ | 911 deps = [ |
| 911 ":cronet_api", | 912 ":cronet_api", |
| 912 ] | 913 ] |
| 913 } | 914 } |
| 914 | 915 |
| 916 action("cronet_combine_proguard_flags") { |
| 917 script = "//components/cronet/tools/generate_proguard_file.py" |
| 918 outputs = [ |
| 919 "$_package_dir/proguard.cfg", |
| 920 ] |
| 921 |
| 922 args = [ |
| 923 "--output-file", |
| 924 rebase_path("$_package_dir/proguard.cfg", root_build_dir), |
| 925 rebase_path("//base/android/base_proguard_config.flags", root_build_dir), |
| 926 rebase_path("//components/cronet/android/proguard.cfg", root_build_dir), |
| 927 ] |
| 928 } |
| 929 |
| 915 copy("cronet_package_copy_native_lib") { | 930 copy("cronet_package_copy_native_lib") { |
| 916 sources = [ | 931 sources = [ |
| 917 "$root_out_dir/libcronet.so", | 932 "$root_out_dir/libcronet.so", |
| 918 ] | 933 ] |
| 919 outputs = [ | 934 outputs = [ |
| 920 "$_package_dir/libs/${android_app_abi}/libcronet.so", | 935 "$_package_dir/libs/${android_app_abi}/libcronet.so", |
| 921 ] | 936 ] |
| 922 deps = [ | 937 deps = [ |
| 923 ":cronet", | 938 ":cronet", |
| 924 ] | 939 ] |
| (...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 956 "//base:base", | 971 "//base:base", |
| 957 ] | 972 ] |
| 958 } | 973 } |
| 959 } | 974 } |
| 960 | 975 |
| 961 group("cronet_package") { | 976 group("cronet_package") { |
| 962 # Enforce that arm_use_neon==false when building for ARMv7 by | 977 # Enforce that arm_use_neon==false when building for ARMv7 by |
| 963 # not including any deps in cronet_package target otherwise. | 978 # not including any deps in cronet_package target otherwise. |
| 964 if (!(target_cpu == "arm" && arm_version == 7) || !arm_use_neon) { | 979 if (!(target_cpu == "arm" && arm_version == 7) || !arm_use_neon) { |
| 965 deps = [ | 980 deps = [ |
| 981 ":cronet_combine_proguard_flags", |
| 966 ":cronet_package_copy", | 982 ":cronet_package_copy", |
| 967 ":cronet_package_copy_native_lib", | 983 ":cronet_package_copy_native_lib", |
| 968 ":cronet_package_copy_native_lib_unstripped", | 984 ":cronet_package_copy_native_lib_unstripped", |
| 969 ":generate_javadoc", | 985 ":generate_javadoc", |
| 970 ":generate_licenses", | 986 ":generate_licenses", |
| 971 ":jar_cronet_api_source", | 987 ":jar_cronet_api_source", |
| 972 ":jar_cronet_other_source", | 988 ":jar_cronet_other_source", |
| 973 ":jar_cronet_sample_source", | 989 ":jar_cronet_sample_source", |
| 974 ":repackage_extracted_jars", | 990 ":repackage_extracted_jars", |
| 975 ] | 991 ] |
| 976 if (current_cpu == "arm" && arm_version == 7) { | 992 if (current_cpu == "arm" && arm_version == 7) { |
| 977 deps += [ ":enforce_no_neon" ] | 993 deps += [ ":enforce_no_neon" ] |
| 978 } | 994 } |
| 979 } | 995 } |
| 980 } | 996 } |
| OLD | NEW |