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 383 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
394 "//base:base_java", | 394 "//base:base_java", |
395 "//third_party/jsr-305:jsr_305_javalib", | 395 "//third_party/jsr-305:jsr_305_javalib", |
396 ] | 396 ] |
397 | 397 |
398 run_findbugs_override = true | 398 run_findbugs_override = true |
399 if (!is_java_debug) { | 399 if (!is_java_debug) { |
400 proguard_enabled = true | 400 proguard_enabled = true |
401 proguard_configs = [ | 401 proguard_configs = [ |
402 "proguard.cfg", | 402 "proguard.cfg", |
403 "sample/javatests/proguard.cfg", | 403 "sample/javatests/proguard.cfg", |
| 404 "//base/android/base_proguard_config.flags", |
404 ] | 405 ] |
405 } | 406 } |
406 } | 407 } |
407 | 408 |
408 # cronet_sample_test_apk_resources is identical to | 409 # cronet_sample_test_apk_resources is identical to |
409 # cronet_sample_apk_resources. The two have to be different targets because | 410 # cronet_sample_apk_resources. The two have to be different targets because |
410 # targets which are common between the "instrumentation test apk" and the | 411 # targets which are common between the "instrumentation test apk" and the |
411 # "tested apk" are removed from the "instrumentation test apk". | 412 # "tested apk" are removed from the "instrumentation test apk". |
412 android_resources("cronet_sample_test_apk_resources") { | 413 android_resources("cronet_sample_test_apk_resources") { |
413 resource_dirs = [ "sample/res" ] | 414 resource_dirs = [ "sample/res" ] |
(...skipping 295 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
709 ":cronet_perf_test_apk_java", | 710 ":cronet_perf_test_apk_java", |
710 ":cronet_test_apk_java", | 711 ":cronet_test_apk_java", |
711 "//base:base_java", | 712 "//base:base_java", |
712 ] | 713 ] |
713 | 714 |
714 run_findbugs_override = true | 715 run_findbugs_override = true |
715 proguard_enabled = true | 716 proguard_enabled = true |
716 proguard_configs = [ | 717 proguard_configs = [ |
717 "proguard.cfg", | 718 "proguard.cfg", |
718 "test/javaperftests/proguard.cfg", | 719 "test/javaperftests/proguard.cfg", |
| 720 "//base/android/base_proguard_config.flags", |
719 ] | 721 ] |
720 } | 722 } |
721 | 723 |
722 test("cronet_unittests") { | 724 test("cronet_unittests") { |
723 sources = [ | 725 sources = [ |
724 "//components/cronet/android/cert/cert_verifier_cache_serializer_unittest.cc
", | 726 "//components/cronet/android/cert/cert_verifier_cache_serializer_unittest.cc
", |
725 "//components/cronet/histogram_manager_unittest.cc", | 727 "//components/cronet/histogram_manager_unittest.cc", |
726 "//components/cronet/run_all_unittests.cc", | 728 "//components/cronet/run_all_unittests.cc", |
727 "//components/cronet/url_request_context_config_unittest.cc", | 729 "//components/cronet/url_request_context_config_unittest.cc", |
728 ] | 730 ] |
(...skipping 163 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
892 ":cronet_javadoc_classpath", | 894 ":cronet_javadoc_classpath", |
893 ":jar_cronet_api_source", | 895 ":jar_cronet_api_source", |
894 ] | 896 ] |
895 } | 897 } |
896 | 898 |
897 copy("cronet_package_copy") { | 899 copy("cronet_package_copy") { |
898 sources = [ | 900 sources = [ |
899 "$root_out_dir/lib.java/components/cronet/android/cronet_api.jar", | 901 "$root_out_dir/lib.java/components/cronet/android/cronet_api.jar", |
900 "//AUTHORS", | 902 "//AUTHORS", |
901 "//chrome/VERSION", | 903 "//chrome/VERSION", |
902 "//components/cronet/android/proguard.cfg", | |
903 ] | 904 ] |
904 outputs = [ | 905 outputs = [ |
905 "$_package_dir/{{source_file_part}}", | 906 "$_package_dir/{{source_file_part}}", |
906 ] | 907 ] |
907 | 908 |
908 deps = [ | 909 deps = [ |
909 ":cronet_api", | 910 ":cronet_api", |
910 ] | 911 ] |
911 } | 912 } |
912 | 913 |
| 914 action("cronet_combine_proguard_flags") { |
| 915 script = "//components/cronet/tools/generate_proguard_file.py" |
| 916 outputs = [ |
| 917 "$_package_dir/proguard.cfg", |
| 918 ] |
| 919 |
| 920 args = [ |
| 921 "--output-file", |
| 922 rebase_path("$_package_dir/proguard.cfg", root_build_dir), |
| 923 rebase_path("//base/android/base_proguard_config.flags", root_build_dir), |
| 924 rebase_path("//components/cronet/android/proguard.cfg", root_build_dir), |
| 925 ] |
| 926 } |
| 927 |
913 copy("cronet_package_copy_native_lib") { | 928 copy("cronet_package_copy_native_lib") { |
914 sources = [ | 929 sources = [ |
915 "$root_out_dir/libcronet.so", | 930 "$root_out_dir/libcronet.so", |
916 ] | 931 ] |
917 outputs = [ | 932 outputs = [ |
918 "$_package_dir/libs/${android_app_abi}/libcronet.so", | 933 "$_package_dir/libs/${android_app_abi}/libcronet.so", |
919 ] | 934 ] |
920 deps = [ | 935 deps = [ |
921 ":cronet", | 936 ":cronet", |
922 ] | 937 ] |
923 } | 938 } |
924 | 939 |
925 copy("cronet_package_copy_native_lib_unstripped") { | 940 copy("cronet_package_copy_native_lib_unstripped") { |
926 sources = [ | 941 sources = [ |
927 "$root_out_dir/lib.unstripped/libcronet.so", | 942 "$root_out_dir/lib.unstripped/libcronet.so", |
928 ] | 943 ] |
929 outputs = [ | 944 outputs = [ |
930 "$_package_dir/symbols/${android_app_abi}/libcronet.so", | 945 "$_package_dir/symbols/${android_app_abi}/libcronet.so", |
931 ] | 946 ] |
932 deps = [ | 947 deps = [ |
933 ":cronet", | 948 ":cronet", |
934 ] | 949 ] |
935 } | 950 } |
936 | 951 |
937 group("cronet_package") { | 952 group("cronet_package") { |
938 deps = [ | 953 deps = [ |
| 954 ":cronet_combine_proguard_flags", |
939 ":cronet_package_copy", | 955 ":cronet_package_copy", |
940 ":cronet_package_copy_native_lib", | 956 ":cronet_package_copy_native_lib", |
941 ":cronet_package_copy_native_lib_unstripped", | 957 ":cronet_package_copy_native_lib_unstripped", |
942 ":generate_javadoc", | 958 ":generate_javadoc", |
943 ":generate_licenses", | 959 ":generate_licenses", |
944 ":jar_cronet_api_source", | 960 ":jar_cronet_api_source", |
945 ":jar_cronet_other_source", | 961 ":jar_cronet_other_source", |
946 ":jar_cronet_sample_source", | 962 ":jar_cronet_sample_source", |
947 ":repackage_extracted_jars", | 963 ":repackage_extracted_jars", |
948 ] | 964 ] |
949 } | 965 } |
OLD | NEW |