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/config/ios/ios_sdk.gni") | 5 import("//build/config/ios/ios_sdk.gni") |
6 import("//build/config/mac/base_rules.gni") | 6 import("//build/config/mac/base_rules.gni") |
7 import("//build/config/mac/symbols.gni") | 7 import("//build/config/mac/symbols.gni") |
8 | 8 |
9 # Generates Info.plist files for Mac apps and frameworks. | 9 # Generates Info.plist files for Mac apps and frameworks. |
10 # | 10 # |
(...skipping 776 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
787 visibility = [ ":$_framework_public_config" ] | 787 visibility = [ ":$_framework_public_config" ] |
788 common_flags = [ "-F" + rebase_path("$root_out_dir/.", root_build_dir) ] | 788 common_flags = [ "-F" + rebase_path("$root_out_dir/.", root_build_dir) ] |
789 cflags_objc = common_flags | 789 cflags_objc = common_flags |
790 cflags_objcc = common_flags | 790 cflags_objcc = common_flags |
791 | 791 |
792 # The link settings are inherited from the framework_bundle config. | 792 # The link settings are inherited from the framework_bundle config. |
793 } | 793 } |
794 } | 794 } |
795 } | 795 } |
796 | 796 |
| 797 if (!_is_fat_build || _is_fat_build_main_target) { |
| 798 _info_plist_target = _target_name + "_info_plist" |
| 799 _info_plist_bundle = _target_name + "_info_plist_bundle" |
| 800 ios_info_plist(_info_plist_target) { |
| 801 visibility = [ ":$_info_plist_bundle" ] |
| 802 executable_name = _output_name |
| 803 forward_variables_from(invoker, |
| 804 [ |
| 805 "extra_substitutions", |
| 806 "info_plist", |
| 807 "info_plist_target", |
| 808 ]) |
| 809 } |
| 810 |
| 811 bundle_data(_info_plist_bundle) { |
| 812 visibility = [ ":$_framework_target" ] |
| 813 forward_variables_from(invoker, [ "testonly" ]) |
| 814 sources = get_target_outputs(":$_info_plist_target") |
| 815 outputs = [ |
| 816 "{{bundle_root_dir}}/Info.plist", |
| 817 ] |
| 818 public_deps = [ |
| 819 ":$_info_plist_target", |
| 820 ] |
| 821 } |
| 822 } |
| 823 |
797 framework_bundle(_framework_target) { | 824 framework_bundle(_framework_target) { |
798 forward_variables_from(invoker, | 825 forward_variables_from(invoker, |
799 "*", | 826 "*", |
800 [ | 827 [ |
801 "output_name", | 828 "output_name", |
802 "public_headers", | 829 "public_headers", |
803 "visibility", | 830 "visibility", |
804 ]) | 831 ]) |
805 output_name = _output_name | 832 output_name = _output_name |
806 | 833 |
| 834 if (!_is_fat_build || _is_fat_build_main_target) { |
| 835 if (!defined(bundle_deps)) { |
| 836 bundle_deps = [] |
| 837 } |
| 838 bundle_deps += [ ":$_info_plist_bundle" ] |
| 839 } |
| 840 |
807 if (_has_public_headers) { | 841 if (_has_public_headers) { |
808 if (!defined(public_configs)) { | 842 if (!defined(public_configs)) { |
809 public_configs = [] | 843 public_configs = [] |
810 } | 844 } |
811 public_configs += [ ":$_framework_public_config$_toolchain_suffix" ] | 845 public_configs += [ ":$_framework_public_config$_toolchain_suffix" ] |
812 } | 846 } |
813 | 847 |
814 if (_has_public_headers) { | 848 if (_has_public_headers) { |
815 visibility = [ | 849 visibility = [ |
816 ":$_target_name$_toolchain_suffix", | 850 ":$_target_name$_toolchain_suffix", |
(...skipping 40 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
857 public_deps = [ | 891 public_deps = [ |
858 ":$_framework_target+link$_toolchain_suffix", | 892 ":$_framework_target+link$_toolchain_suffix", |
859 ] | 893 ] |
860 } | 894 } |
861 } | 895 } |
862 } | 896 } |
863 | 897 |
864 set_defaults("ios_framework_bundle") { | 898 set_defaults("ios_framework_bundle") { |
865 configs = default_shared_library_configs | 899 configs = default_shared_library_configs |
866 } | 900 } |
OLD | NEW |