OLD | NEW |
1 # Copyright 2014 The Chromium Authors. All rights reserved. | 1 # Copyright 2014 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("//base/android/linker/config.gni") | 5 import("//base/android/linker/config.gni") |
6 import("//build/config/android/config.gni") | 6 import("//build/config/android/config.gni") |
7 import("//build/config/android/internal_rules.gni") | 7 import("//build/config/android/internal_rules.gni") |
8 import("//build/toolchain/toolchain.gni") | 8 import("//build/toolchain/toolchain.gni") |
9 import("//third_party/android_platform/config.gni") | 9 import("//third_party/android_platform/config.gni") |
10 import("//tools/grit/grit_rule.gni") | 10 import("//tools/grit/grit_rule.gni") |
(...skipping 1275 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1286 _keystore_path = invoker.keystore_path | 1286 _keystore_path = invoker.keystore_path |
1287 _keystore_name = invoker.keystore_name | 1287 _keystore_name = invoker.keystore_name |
1288 _keystore_password = invoker.keystore_password | 1288 _keystore_password = invoker.keystore_password |
1289 } | 1289 } |
1290 | 1290 |
1291 _srcjar_deps = [] | 1291 _srcjar_deps = [] |
1292 if (defined(invoker.srcjar_deps)) { | 1292 if (defined(invoker.srcjar_deps)) { |
1293 _srcjar_deps += invoker.srcjar_deps | 1293 _srcjar_deps += invoker.srcjar_deps |
1294 } | 1294 } |
1295 | 1295 |
1296 _load_library_from_apk = false | 1296 _use_chromium_linker = |
| 1297 defined(invoker.use_chromium_linker) && invoker.use_chromium_linker && |
| 1298 chromium_linker_supported |
| 1299 _enable_relocation_packing = |
| 1300 defined(invoker.enable_relocation_packing) && |
| 1301 invoker.enable_relocation_packing && _use_chromium_linker |
| 1302 _load_library_from_apk = |
| 1303 defined(invoker.load_library_from_apk) && invoker.load_library_from_apk |
| 1304 |
| 1305 assert(_use_chromium_linker || true) # Mark as used. |
| 1306 assert(_enable_relocation_packing || true) # Mark as used. |
| 1307 |
| 1308 assert( |
| 1309 !_load_library_from_apk || _use_chromium_linker, |
| 1310 "Loading library from the apk requires use" + " of the Chromium linker.") |
1297 | 1311 |
1298 # The dependency that makes the chromium linker, if any is needed. | 1312 # The dependency that makes the chromium linker, if any is needed. |
1299 _chromium_linker_dep = [] | 1313 _native_libs_deps = [] |
1300 | 1314 |
1301 if (defined(invoker.native_libs) && invoker.native_libs != []) { | 1315 if (defined(invoker.native_libs) && invoker.native_libs != []) { |
1302 _use_chromium_linker = false | |
1303 if (defined(invoker.use_chromium_linker)) { | |
1304 _use_chromium_linker = | |
1305 invoker.use_chromium_linker && chromium_linker_supported | |
1306 _chromium_linker_dep = [ "//base/android/linker:chromium_android_linker" ] | |
1307 } | |
1308 | |
1309 if (defined(invoker.load_library_from_apk) && | |
1310 invoker.load_library_from_apk) { | |
1311 _load_library_from_apk = true | |
1312 assert(_use_chromium_linker, | |
1313 "Loading library from the apk requires use" + | |
1314 " of the Chromium linker.") | |
1315 } | |
1316 | |
1317 if (is_component_build) { | 1316 if (is_component_build) { |
1318 _native_libs += [ "$root_shlib_dir/libc++_shared.so" ] | 1317 _native_libs += [ "$root_shlib_dir/libc++_shared.so" ] |
1319 _chromium_linker_dep += [ "//build/android:cpplib_stripped" ] | 1318 _native_libs_deps += [ "//build/android:cpplib_stripped" ] |
1320 } | 1319 } |
1321 | 1320 |
1322 # Allow native_libs to be in the form "foo.so" or "foo.cr.so" | 1321 # Allow native_libs to be in the form "foo.so" or "foo.cr.so" |
1323 _first_ext_removed = | 1322 _first_ext_removed = |
1324 process_file_template(invoker.native_libs, "{{source_name_part}}") | 1323 process_file_template(invoker.native_libs, "{{source_name_part}}") |
1325 _native_libs += process_file_template( | 1324 _native_libs += process_file_template( |
1326 _first_ext_removed, | 1325 _first_ext_removed, |
1327 "$root_shlib_dir/{{source_name_part}}$shlib_extension") | 1326 "$root_shlib_dir/{{source_name_part}}$shlib_extension") |
1328 | 1327 |
1329 # Add in target_cpu so that other architectures are not accidentally | |
1330 # included when switching target_cpu without doing a clean build. | |
1331 _native_libs_dir = gen_dir + "/lib-$target_cpu" | |
1332 | |
1333 if (_use_chromium_linker) { | |
1334 _native_libs += | |
1335 [ "$root_shlib_dir/libchromium_android_linker$shlib_extension" ] | |
1336 } | |
1337 | |
1338 _enable_relocation_packing = false | |
1339 if (_use_chromium_linker && defined(invoker.enable_relocation_packing) && | |
1340 invoker.enable_relocation_packing) { | |
1341 _enable_relocation_packing = true | |
1342 } | |
1343 | |
1344 _native_lib_version_rule = "" | 1328 _native_lib_version_rule = "" |
1345 if (defined(invoker.native_lib_version_rule)) { | 1329 if (defined(invoker.native_lib_version_rule)) { |
1346 _native_lib_version_rule = invoker.native_lib_version_rule | 1330 _native_lib_version_rule = invoker.native_lib_version_rule |
1347 } | 1331 } |
1348 _native_lib_version_arg = "\"\"" | 1332 _native_lib_version_arg = "\"\"" |
1349 if (defined(invoker.native_lib_version_arg)) { | 1333 if (defined(invoker.native_lib_version_arg)) { |
1350 _native_lib_version_arg = invoker.native_lib_version_arg | 1334 _native_lib_version_arg = invoker.native_lib_version_arg |
1351 } | 1335 } |
1352 } | 1336 } |
1353 | 1337 |
(...skipping 26 matching lines...) Expand all Loading... |
1380 write_build_config(build_config_target) { | 1364 write_build_config(build_config_target) { |
1381 forward_variables_from(invoker, [ "apk_under_test" ]) | 1365 forward_variables_from(invoker, [ "apk_under_test" ]) |
1382 type = "android_apk" | 1366 type = "android_apk" |
1383 jar_path = _jar_path | 1367 jar_path = _jar_path |
1384 dex_path = final_dex_path | 1368 dex_path = final_dex_path |
1385 apk_path = _final_apk_path | 1369 apk_path = _final_apk_path |
1386 resources_zip = resources_zip_path | 1370 resources_zip = resources_zip_path |
1387 build_config = _build_config | 1371 build_config = _build_config |
1388 android_manifest = _android_manifest | 1372 android_manifest = _android_manifest |
1389 | 1373 |
1390 deps = _chromium_linker_dep + _android_manifest_deps | 1374 deps = _native_libs_deps + _android_manifest_deps |
1391 if (defined(invoker.deps)) { | 1375 if (defined(invoker.deps)) { |
1392 deps += invoker.deps | 1376 deps += invoker.deps |
1393 } | 1377 } |
1394 | 1378 |
1395 proguard_enabled = _proguard_enabled | 1379 proguard_enabled = _proguard_enabled |
1396 if (_proguard_enabled) { | 1380 if (_proguard_enabled) { |
1397 proguard_info = "$_proguard_jar_path.info" | 1381 proguard_info = "$_proguard_jar_path.info" |
1398 } | 1382 } |
1399 | 1383 |
1400 native_libs = _native_libs | 1384 native_libs = _native_libs |
(...skipping 184 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1585 } | 1569 } |
1586 args = [ "--inputs=@FileArg($_dex_arg_key)" ] | 1570 args = [ "--inputs=@FileArg($_dex_arg_key)" ] |
1587 } | 1571 } |
1588 | 1572 |
1589 if (emma_coverage && !_emma_never_instrument) { | 1573 if (emma_coverage && !_emma_never_instrument) { |
1590 no_locals = true | 1574 no_locals = true |
1591 sources += [ "$android_sdk_root/tools/lib/emma_device.jar" ] | 1575 sources += [ "$android_sdk_root/tools/lib/emma_device.jar" ] |
1592 } | 1576 } |
1593 } | 1577 } |
1594 | 1578 |
1595 if (_native_libs != []) { | 1579 _native_libs_file_arg_dep = ":$build_config_target" |
| 1580 _native_libs_file_arg = "@FileArg($_rebased_build_config:native:libraries)" |
| 1581 |
| 1582 if (_native_libs != [] && _enable_relocation_packing) { |
1596 _prepare_native_target_name = "${_template_name}__prepare_native" | 1583 _prepare_native_target_name = "${_template_name}__prepare_native" |
| 1584 _native_libs_dir = "$gen_dir/packed-libs" |
| 1585 _native_libs_json = "$gen_dir/packed-libs/filelist.json" |
| 1586 _rebased_native_libs_json = rebase_path(_native_libs_json, root_build_dir) |
| 1587 |
| 1588 _native_libs_file_arg_dep = ":$_prepare_native_target_name" |
| 1589 _native_libs_file_arg = "@FileArg($_rebased_native_libs_json:files)" |
| 1590 |
1597 action(_prepare_native_target_name) { | 1591 action(_prepare_native_target_name) { |
1598 forward_variables_from(invoker, | 1592 forward_variables_from(invoker, |
1599 [ | 1593 [ |
1600 "data_deps", | 1594 "deps", |
1601 "public_deps", | 1595 "public_deps", |
1602 ]) | 1596 ]) |
1603 script = "//build/android/gyp/pack_relocations.py" | 1597 script = "//build/android/gyp/pack_relocations.py" |
1604 packed_libraries_dir = "$_native_libs_dir/$android_app_abi" | |
1605 depfile = "$target_gen_dir/$target_name.d" | 1598 depfile = "$target_gen_dir/$target_name.d" |
1606 outputs = [ | 1599 outputs = [ |
1607 depfile, | 1600 depfile, |
| 1601 _native_libs_json, |
1608 ] | 1602 ] |
1609 | 1603 |
1610 inputs = _native_libs | 1604 inputs = _native_libs + [ _build_config ] |
1611 deps = _chromium_linker_dep | |
1612 | 1605 |
1613 inputs += [ _build_config ] | 1606 deps += _native_libs_deps |
1614 deps += [ ":$build_config_target" ] | 1607 deps += [ |
1615 | 1608 ":$build_config_target", |
1616 rebased_gdbserver = rebase_path(android_gdbserver, root_build_dir) | 1609 relocation_packer_target, |
1617 skip_packing_list = [ | |
1618 rebased_gdbserver, | |
1619 "libchromium_android_linker.so", | |
1620 ] | 1610 ] |
1621 | 1611 |
1622 enable_packing_arg = 0 | |
1623 if (_enable_relocation_packing) { | |
1624 enable_packing_arg = 1 | |
1625 deps += [ relocation_packer_target ] | |
1626 } | |
1627 | |
1628 args = [ | 1612 args = [ |
1629 "--depfile", | 1613 "--depfile", |
1630 rebase_path(depfile, root_build_dir), | 1614 rebase_path(depfile, root_build_dir), |
1631 "--enable-packing=$enable_packing_arg", | 1615 "--enable-packing=1", |
1632 "--exclude-packing-list=$skip_packing_list", | |
1633 "--android-pack-relocations", | 1616 "--android-pack-relocations", |
1634 rebase_path(relocation_packer_exe, root_build_dir), | 1617 rebase_path(relocation_packer_exe, root_build_dir), |
1635 "--stripped-libraries-dir", | 1618 "--stripped-libraries-dir", |
1636 rebase_path(root_build_dir, root_build_dir), | 1619 rebase_path(root_build_dir, root_build_dir), |
1637 "--packed-libraries-dir", | 1620 "--packed-libraries-dir", |
1638 rebase_path(packed_libraries_dir, root_build_dir), | 1621 rebase_path(_native_libs_dir, root_build_dir), |
1639 "--libraries=@FileArg(${_rebased_build_config}:native:libraries)", | 1622 "--libraries=@FileArg(${_rebased_build_config}:native:libraries)", |
1640 "--clear-dir", | 1623 "--filelistjson=$_rebased_native_libs_json", |
1641 ] | 1624 ] |
1642 | |
1643 if (defined(invoker.deps)) { | |
1644 deps += invoker.deps | |
1645 } | |
1646 | |
1647 if (is_debug) { | |
1648 inputs += [ android_gdbserver ] | |
1649 args += [ "--libraries=$rebased_gdbserver" ] | |
1650 } | |
1651 } | 1625 } |
1652 } | 1626 } |
1653 | 1627 |
| 1628 _extra_native_libs = [] |
| 1629 _extra_native_libs_deps = [] |
| 1630 if (_native_libs != []) { |
| 1631 if (is_debug) { |
| 1632 _extra_native_libs = [ android_gdbserver ] |
| 1633 } |
| 1634 |
| 1635 if (_use_chromium_linker) { |
| 1636 _extra_native_libs = |
| 1637 [ "$root_shlib_dir/libchromium_android_linker$shlib_extension" ] |
| 1638 _extra_native_libs_deps += |
| 1639 [ "//base/android/linker:chromium_android_linker" ] |
| 1640 } |
| 1641 } |
| 1642 |
1654 _final_deps += [ ":${_template_name}__create" ] | 1643 _final_deps += [ ":${_template_name}__create" ] |
1655 create_apk("${_template_name}__create") { | 1644 create_apk("${_template_name}__create") { |
1656 deps = [] | 1645 deps = [] |
1657 forward_variables_from(invoker, | 1646 forward_variables_from(invoker, |
1658 [ | 1647 [ |
1659 "asset_location", | 1648 "asset_location", |
1660 "deps", | 1649 "deps", |
1661 "extensions_to_not_compress", | 1650 "extensions_to_not_compress", |
1662 "language_splits", | 1651 "language_splits", |
| 1652 "public_deps", |
1663 "shared_resources", | 1653 "shared_resources", |
1664 "write_asset_list", | 1654 "write_asset_list", |
1665 ]) | 1655 ]) |
1666 apk_path = _final_apk_path | 1656 apk_path = _final_apk_path |
1667 android_manifest = _android_manifest | 1657 android_manifest = _android_manifest |
1668 assets_build_config = _build_config | 1658 assets_build_config = _build_config |
1669 resources_zip = _all_resources_zip_path | 1659 resources_zip = _all_resources_zip_path |
1670 dex_path = final_dex_path | 1660 dex_path = final_dex_path |
1671 load_library_from_apk = _load_library_from_apk | 1661 load_library_from_apk = _load_library_from_apk |
1672 create_density_splits = _create_density_splits | 1662 create_density_splits = _create_density_splits |
(...skipping 20 matching lines...) Expand all Loading... |
1693 ] | 1683 ] |
1694 | 1684 |
1695 # This target generates the input file _all_resources_zip_path. | 1685 # This target generates the input file _all_resources_zip_path. |
1696 deps += _android_manifest_deps + [ | 1686 deps += _android_manifest_deps + [ |
1697 ":$build_config_target", | 1687 ":$build_config_target", |
1698 ":$process_resources_target", | 1688 ":$process_resources_target", |
1699 ":$final_dex_target_name", | 1689 ":$final_dex_target_name", |
1700 ] | 1690 ] |
1701 | 1691 |
1702 if (_native_libs != [] && !_create_abi_split) { | 1692 if (_native_libs != [] && !_create_abi_split) { |
1703 native_libs_dir = _native_libs_dir | 1693 deps += _native_libs_deps + _extra_native_libs_deps + |
| 1694 [ _native_libs_file_arg_dep ] |
| 1695 native_libs_filearg = _native_libs_file_arg |
| 1696 native_libs = _extra_native_libs |
1704 | 1697 |
1705 # Placeholders necessary for some older devices. | 1698 # Placeholders necessary for some older devices. |
1706 # http://crbug.com/395038 | 1699 # http://crbug.com/395038 |
1707 forward_variables_from(invoker, [ "native_lib_placeholders" ]) | 1700 forward_variables_from(invoker, [ "native_lib_placeholders" ]) |
1708 | |
1709 deps += [ ":$_prepare_native_target_name" ] | |
1710 } | 1701 } |
1711 } | 1702 } |
1712 | 1703 |
1713 if (_native_libs != [] && _create_abi_split) { | 1704 if (_native_libs != [] && _create_abi_split) { |
1714 _manifest_rule = "${_template_name}__split_manifest_abi_${android_app_abi}" | 1705 _manifest_rule = "${_template_name}__split_manifest_abi_${android_app_abi}" |
1715 generate_split_manifest(_manifest_rule) { | 1706 generate_split_manifest(_manifest_rule) { |
1716 main_manifest = _android_manifest | 1707 main_manifest = _android_manifest |
1717 out_manifest = | 1708 out_manifest = |
1718 "$gen_dir/split-manifests/${android_app_abi}/AndroidManifest.xml" | 1709 "$gen_dir/split-manifests/${android_app_abi}/AndroidManifest.xml" |
1719 split_name = "abi_${android_app_abi}" | 1710 split_name = "abi_${android_app_abi}" |
(...skipping 11 matching lines...) Expand all Loading... |
1731 android_manifest = manifest_outputs[1] | 1722 android_manifest = manifest_outputs[1] |
1732 load_library_from_apk = _load_library_from_apk | 1723 load_library_from_apk = _load_library_from_apk |
1733 | 1724 |
1734 version_code = _version_code | 1725 version_code = _version_code |
1735 version_name = _version_name | 1726 version_name = _version_name |
1736 | 1727 |
1737 keystore_name = _keystore_name | 1728 keystore_name = _keystore_name |
1738 keystore_path = _keystore_path | 1729 keystore_path = _keystore_path |
1739 keystore_password = _keystore_password | 1730 keystore_password = _keystore_password |
1740 | 1731 |
1741 native_libs_dir = _native_libs_dir | |
1742 | |
1743 # Placeholders necessary for some older devices. | 1732 # Placeholders necessary for some older devices. |
1744 # http://crbug.com/395038 | 1733 # http://crbug.com/395038 |
1745 forward_variables_from(invoker, [ "native_lib_placeholders" ]) | 1734 deps = [] |
| 1735 forward_variables_from(invoker, |
| 1736 [ |
| 1737 "deps", |
| 1738 "native_lib_placeholders", |
| 1739 "public_deps", |
| 1740 ]) |
1746 | 1741 |
1747 deps = [ | 1742 incremental_deps = deps + [ ":$_manifest_rule" ] |
1748 ":${_manifest_rule}", | 1743 deps = [] |
1749 ":${_prepare_native_target_name}", | 1744 deps = incremental_deps + _native_libs_deps + _extra_native_libs_deps + |
1750 ] | 1745 [ _native_libs_file_arg_dep ] |
1751 incremental_deps = deps | 1746 native_libs_filearg = _native_libs_file_arg |
| 1747 native_libs = _extra_native_libs |
1752 } | 1748 } |
1753 } | 1749 } |
1754 | 1750 |
1755 _create_incremental_script_rule_name = "${_template_name}__incremental_script" | 1751 _create_incremental_script_rule_name = "${_template_name}__incremental_script" |
1756 action(_create_incremental_script_rule_name) { | 1752 action(_create_incremental_script_rule_name) { |
1757 script = "//build/android/incremental_install/create_install_script.py" | 1753 script = "//build/android/incremental_install/create_install_script.py" |
1758 depfile = "$target_gen_dir/$target_name.d" | 1754 depfile = "$target_gen_dir/$target_name.d" |
1759 deps = [ | 1755 deps = [ |
1760 ":$build_config_target", | 1756 _native_libs_file_arg_dep, |
1761 ] | 1757 ] |
1762 | 1758 |
1763 _generated_script_path = | 1759 _generated_script_path = |
1764 "${root_out_dir}/bin/install_${_template_name}_incremental" | 1760 "${root_out_dir}/bin/install_${_template_name}_incremental" |
1765 outputs = [ | 1761 outputs = [ |
1766 depfile, | 1762 depfile, |
1767 _generated_script_path, | 1763 _generated_script_path, |
1768 ] | 1764 ] |
1769 | 1765 |
1770 _rebased_apk_path_no_ext = | 1766 _rebased_apk_path_no_ext = |
1771 rebase_path(_final_apk_path_no_ext, root_build_dir) | 1767 rebase_path(_final_apk_path_no_ext, root_build_dir) |
1772 _rebased_generated_script_path = | 1768 _rebased_generated_script_path = |
1773 rebase_path(_generated_script_path, root_build_dir) | 1769 rebase_path(_generated_script_path, root_build_dir) |
1774 _rebased_depfile = rebase_path(depfile, root_build_dir) | 1770 _rebased_depfile = rebase_path(depfile, root_build_dir) |
1775 _dex_arg_key = "${_rebased_build_config}:final_dex:dependency_dex_files" | 1771 _dex_arg_key = "${_rebased_build_config}:final_dex:dependency_dex_files" |
1776 args = [ | 1772 args = [ |
1777 "--apk-path=${_rebased_apk_path_no_ext}_incremental.apk", | 1773 "--apk-path=${_rebased_apk_path_no_ext}_incremental.apk", |
1778 "--script-output-path=$_rebased_generated_script_path", | 1774 "--script-output-path=$_rebased_generated_script_path", |
1779 "--dex-file=$_rebased_lib_dex_path", | 1775 "--dex-file=$_rebased_lib_dex_path", |
1780 "--dex-file-list=@FileArg($_dex_arg_key)", | 1776 "--dex-file-list=@FileArg($_dex_arg_key)", |
1781 "--depfile=$_rebased_depfile", | 1777 "--depfile=$_rebased_depfile", |
1782 ] | 1778 ] |
1783 if (_proguard_enabled) { | 1779 if (_proguard_enabled) { |
1784 args += [ "--show-proguard-warning" ] | 1780 args += [ "--show-proguard-warning" ] |
1785 } | 1781 } |
1786 if (defined(_native_libs_dir)) { | 1782 if (defined(_native_libs_file_arg)) { |
1787 _rebased_native_libs_dir = rebase_path(_native_libs_dir, root_build_dir) | 1783 args += [ "--native-libs=$_native_libs_file_arg" ] |
1788 args += [ "--lib-dir=$_rebased_native_libs_dir/$android_app_abi" ] | 1784 } |
| 1785 if (_extra_native_libs != []) { |
| 1786 _rebased_extra_native_libs = |
| 1787 rebase_path(_extra_native_libs, root_build_dir) |
| 1788 args += [ "--native-libs=$_rebased_extra_native_libs" ] |
1789 } | 1789 } |
1790 if (_create_density_splits) { | 1790 if (_create_density_splits) { |
1791 args += [ "--split=${_rebased_apk_path_no_ext}-density-*.apk" ] | 1791 args += [ "--split=${_rebased_apk_path_no_ext}-density-*.apk" ] |
1792 } | 1792 } |
1793 if (_create_language_splits) { | 1793 if (_create_language_splits) { |
1794 args += [ "--split=${_rebased_apk_path_no_ext}-language-*.apk" ] | 1794 args += [ "--split=${_rebased_apk_path_no_ext}-language-*.apk" ] |
1795 } | 1795 } |
1796 } | 1796 } |
1797 | 1797 |
1798 group(target_name) { | 1798 group(target_name) { |
1799 forward_variables_from(invoker, [ "data_deps" ]) | 1799 forward_variables_from(invoker, [ "data_deps" ]) |
1800 public_deps = _final_deps | 1800 public_deps = _final_deps |
1801 } | 1801 } |
1802 group("${target_name}_incremental") { | 1802 group("${target_name}_incremental") { |
1803 data_deps = [] | 1803 data_deps = [] |
1804 forward_variables_from(invoker, [ "data_deps" ]) | 1804 forward_variables_from(invoker, [ "data_deps" ]) |
1805 | 1805 |
1806 # device/commands is used by the installer script to push files via .zip. | 1806 # device/commands is used by the installer script to push files via .zip. |
1807 data_deps += [ "//build/android/pylib/device/commands" ] | 1807 data_deps += [ "//build/android/pylib/device/commands" ] + |
| 1808 _native_libs_deps + _extra_native_libs_deps |
1808 | 1809 |
1809 # Since the _incremental.apk does not include use .so nor .dex from the | 1810 # Since the _incremental.apk does not include use .so nor .dex from the |
1810 # actual target, but instead loads them at runtime, we need to explicitly | 1811 # actual target, but instead loads them at runtime, we need to explicitly |
1811 # depend on them here. | 1812 # depend on them here. |
1812 public_deps = [ | 1813 public_deps = [ |
1813 ":${_create_incremental_script_rule_name}", | 1814 ":${_create_incremental_script_rule_name}", |
1814 ":${_template_name}__create_incremental", | 1815 ":${_template_name}__create_incremental", |
1815 ":${java_target}", | 1816 ":${java_target}", |
1816 ] | 1817 ] |
1817 if (_native_libs != []) { | |
1818 public_deps += [ ":$_prepare_native_target_name" ] | |
1819 } | |
1820 } | 1818 } |
1821 } | 1819 } |
1822 | 1820 |
1823 # Declare an Android instrumentation test apk | 1821 # Declare an Android instrumentation test apk |
1824 # | 1822 # |
1825 # This target creates an Android instrumentation test apk. | 1823 # This target creates an Android instrumentation test apk. |
1826 # | 1824 # |
1827 # Variables | 1825 # Variables |
1828 # android_manifest: Path to AndroidManifest.xml. | 1826 # android_manifest: Path to AndroidManifest.xml. |
1829 # data_deps: List of dependencies needed at runtime. These will be built but | 1827 # data_deps: List of dependencies needed at runtime. These will be built but |
(...skipping 375 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2205 } | 2203 } |
2206 | 2204 |
2207 android_library(target_name) { | 2205 android_library(target_name) { |
2208 java_files = [] | 2206 java_files = [] |
2209 srcjar_deps = [ ":${_template_name}__protoc_java" ] | 2207 srcjar_deps = [ ":${_template_name}__protoc_java" ] |
2210 deps = [ | 2208 deps = [ |
2211 "//third_party/android_protobuf:protobuf_nano_javalib", | 2209 "//third_party/android_protobuf:protobuf_nano_javalib", |
2212 ] | 2210 ] |
2213 } | 2211 } |
2214 } | 2212 } |
OLD | NEW |