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("//build/buildflag_header.gni") | 5 import("//build/buildflag_header.gni") |
6 import("//build/config/chrome_build.gni") | 6 import("//build/config/chrome_build.gni") |
7 import("//build/config/compiler/compiler.gni") | 7 import("//build/config/compiler/compiler.gni") |
8 import("//build/config/features.gni") | 8 import("//build/config/features.gni") |
9 import("//build/config/locales.gni") | 9 import("//build/config/locales.gni") |
10 import("//build/config/sanitizers/sanitizers.gni") | 10 import("//build/config/sanitizers/sanitizers.gni") |
11 import("//build/config/ui.gni") | 11 import("//build/config/ui.gni") |
12 import("//build/config/win/console_app.gni") | 12 import("//build/config/win/console_app.gni") |
13 import("//build/config/win/manifest.gni") | 13 import("//build/config/win/manifest.gni") |
14 import("//chrome/chrome_repack_locales.gni") | 14 import("//chrome/chrome_repack_locales.gni") |
15 import("//chrome/common/features.gni") | 15 import("//chrome/common/features.gni") |
16 import("//chrome/version.gni") | 16 import("//chrome/version.gni") |
17 import("//ui/base/ui_features.gni") | 17 import("//ui/base/ui_features.gni") |
18 import("//v8/gni/v8.gni") | 18 import("//v8/gni/v8.gni") |
19 | 19 |
| 20 if (is_android && enable_resource_whitelist_generation) { |
| 21 android_resource_whitelist = "$target_gen_dir/resource_whitelist.txt" |
| 22 } |
| 23 |
20 if (is_android) { | 24 if (is_android) { |
21 import("//build/config/android/rules.gni") | 25 import("//build/config/android/rules.gni") |
22 } else if (is_mac) { | 26 } else if (is_mac) { |
23 import("//build/compiled_action.gni") | 27 import("//build/compiled_action.gni") |
24 import("//build/config/mac/rules.gni") | 28 import("//build/config/mac/rules.gni") |
25 import("//build/config/mac/symbols.gni") | 29 import("//build/config/mac/symbols.gni") |
26 import("//build/mac/tweak_info_plist.gni") | 30 import("//build/mac/tweak_info_plist.gni") |
27 import("//build/util/branding.gni") | 31 import("//build/util/branding.gni") |
28 import("//build/util/version.gni") | 32 import("//build/util/version.gni") |
29 import("//build_overrides/v8.gni") | 33 import("//build_overrides/v8.gni") |
(...skipping 1446 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1476 } | 1480 } |
1477 | 1481 |
1478 # GYP outputs the file in the gen/repack directory. On non-Mac/iOS platforms | 1482 # GYP outputs the file in the gen/repack directory. On non-Mac/iOS platforms |
1479 # it them copies it. This skipes the copy step and writes it to the final | 1483 # it them copies it. This skipes the copy step and writes it to the final |
1480 # location. | 1484 # location. |
1481 if (is_mac || is_ios) { | 1485 if (is_mac || is_ios) { |
1482 output = "$root_gen_dir/repack/resources.pak" | 1486 output = "$root_gen_dir/repack/resources.pak" |
1483 } else { | 1487 } else { |
1484 output = "$root_out_dir/resources.pak" | 1488 output = "$root_out_dir/resources.pak" |
1485 } | 1489 } |
| 1490 |
| 1491 if (is_android && enable_resource_whitelist_generation) { |
| 1492 repack_whitelist = android_resource_whitelist |
| 1493 deps += [ "//chrome:resource_whitelist" ] |
| 1494 } |
1486 } | 1495 } |
1487 | 1496 |
1488 # GYP version: chrome/chrome_resources.gyp:browser_tests_pak | 1497 # GYP version: chrome/chrome_resources.gyp:browser_tests_pak |
1489 repack("browser_tests_pak") { | 1498 repack("browser_tests_pak") { |
1490 sources = [ | 1499 sources = [ |
1491 "$root_gen_dir/chrome/options_test_resources.pak", | 1500 "$root_gen_dir/chrome/options_test_resources.pak", |
1492 "$root_gen_dir/chrome/webui_test_resources.pak", | 1501 "$root_gen_dir/chrome/webui_test_resources.pak", |
1493 ] | 1502 ] |
1494 output = "$root_out_dir/browser_tests.pak" | 1503 output = "$root_out_dir/browser_tests.pak" |
1495 deps = [ | 1504 deps = [ |
(...skipping 94 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1590 if (enable_extensions) { | 1599 if (enable_extensions) { |
1591 sources += [ "$root_gen_dir/extensions/extensions_browser_resources_${perc
ent}_percent.pak" ] | 1600 sources += [ "$root_gen_dir/extensions/extensions_browser_resources_${perc
ent}_percent.pak" ] |
1592 deps += [ "//extensions:extensions_browser_resources" ] | 1601 deps += [ "//extensions:extensions_browser_resources" ] |
1593 } | 1602 } |
1594 if (enable_app_list) { | 1603 if (enable_app_list) { |
1595 sources += [ "$root_gen_dir/ui/app_list/resources/app_list_resources_${per
cent}_percent.pak" ] | 1604 sources += [ "$root_gen_dir/ui/app_list/resources/app_list_resources_${per
cent}_percent.pak" ] |
1596 deps += [ "//ui/app_list/resources" ] | 1605 deps += [ "//ui/app_list/resources" ] |
1597 } | 1606 } |
1598 | 1607 |
1599 output = repack_output_file | 1608 output = repack_output_file |
| 1609 |
| 1610 if (is_android && enable_resource_whitelist_generation) { |
| 1611 repack_whitelist = android_resource_whitelist |
| 1612 deps += [ "//chrome:resource_whitelist" ] |
| 1613 } |
1600 } | 1614 } |
1601 | 1615 |
1602 copy(copy_name) { | 1616 copy(copy_name) { |
1603 visibility = [ ":*" ] | 1617 visibility = [ ":*" ] |
1604 deps = [ | 1618 deps = [ |
1605 ":$repack_name", | 1619 ":$repack_name", |
1606 ] | 1620 ] |
1607 sources = [ | 1621 sources = [ |
1608 repack_output_file, | 1622 repack_output_file, |
1609 ] | 1623 ] |
(...skipping 147 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1757 "//chrome/common", | 1771 "//chrome/common", |
1758 "//chrome/gpu", | 1772 "//chrome/gpu", |
1759 "//chrome/renderer", | 1773 "//chrome/renderer", |
1760 "//chrome/utility", | 1774 "//chrome/utility", |
1761 "//components/safe_browsing_db:safe_browsing_db_mobile", | 1775 "//components/safe_browsing_db:safe_browsing_db_mobile", |
1762 "//content/public/app:both", | 1776 "//content/public/app:both", |
1763 ] | 1777 ] |
1764 } | 1778 } |
1765 } | 1779 } |
1766 | 1780 |
| 1781 if (is_android && enable_resource_whitelist_generation) { |
| 1782 action("resource_whitelist") { |
| 1783 deps = [ |
| 1784 "//chrome/android:chrome", |
| 1785 ] |
| 1786 script = "//tools/resources/generate_resource_whitelist.py" |
| 1787 |
| 1788 _infile = "$root_out_dir/libchrome.cr.so.whitelist" |
| 1789 inputs = [ |
| 1790 _infile, |
| 1791 ] |
| 1792 |
| 1793 _outfile = android_resource_whitelist |
| 1794 outputs = [ |
| 1795 _outfile, |
| 1796 ] |
| 1797 |
| 1798 args = [ |
| 1799 "-i", |
| 1800 rebase_path(_infile, root_build_dir), |
| 1801 "-o", |
| 1802 rebase_path(_outfile, root_build_dir), |
| 1803 "--out-dir=.", |
| 1804 ] |
| 1805 } |
| 1806 } |
| 1807 |
1767 if (is_linux) { | 1808 if (is_linux) { |
1768 action("manpage") { | 1809 action("manpage") { |
1769 if (is_chrome_branded) { | 1810 if (is_chrome_branded) { |
1770 name = "Google Chrome" | 1811 name = "Google Chrome" |
1771 filename = "google-chrome" | 1812 filename = "google-chrome" |
1772 confdir = "google-chrome" | 1813 confdir = "google-chrome" |
1773 } else { | 1814 } else { |
1774 name = "Chromium" | 1815 name = "Chromium" |
1775 filename = "chromium-browser" | 1816 filename = "chromium-browser" |
1776 confdir = "chromium" | 1817 confdir = "chromium" |
(...skipping 63 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1840 "//chrome/app/theme/$branding_path_component/product_logo_48.png", | 1881 "//chrome/app/theme/$branding_path_component/product_logo_48.png", |
1841 "//chrome/tools/build/linux/chrome-wrapper", | 1882 "//chrome/tools/build/linux/chrome-wrapper", |
1842 "//third_party/xdg-utils/scripts/xdg-mime", | 1883 "//third_party/xdg-utils/scripts/xdg-mime", |
1843 "//third_party/xdg-utils/scripts/xdg-settings", | 1884 "//third_party/xdg-utils/scripts/xdg-settings", |
1844 ] | 1885 ] |
1845 outputs = [ | 1886 outputs = [ |
1846 "$root_out_dir/{{source_file_part}}", | 1887 "$root_out_dir/{{source_file_part}}", |
1847 ] | 1888 ] |
1848 } | 1889 } |
1849 } | 1890 } |
OLD | NEW |