Index: components/cronet/ios/BUILD.gn |
diff --git a/components/cronet/ios/BUILD.gn b/components/cronet/ios/BUILD.gn |
index 19ff7514cf2e3ed18404b4541d512bd9370e9519..aba2806498ad56de2bc966b69d822522de39caee 100644 |
--- a/components/cronet/ios/BUILD.gn |
+++ b/components/cronet/ios/BUILD.gn |
@@ -4,6 +4,7 @@ |
import("//build/buildflag_header.gni") |
import("//build/config/ios/rules.gni") |
+import("//build/mac/tweak_info_plist.gni") |
import("//build/util/version.gni") |
import("//chrome/version.gni") |
import("//testing/test.gni") |
@@ -53,17 +54,30 @@ source_set("cronet_sources") { |
} |
} |
+# Tweak |info_plist| with current version and revision. |
+tweak_info_plist("cronet_framework_plist") { |
+ info_plist = "Info.plist" |
+ args = [ "--bundle_id=CRNT" ] |
sdefresne
2016/07/01 12:50:11
The "Info.plist" file already contains the followi
mef
2016/07/01 14:10:08
Done. I've kept it because omitting args triggers
|
+} |
+ |
+# Compile plist into |output_name|. |
+ios_info_plist("cronet_info_plist") { |
+ executable_name = "Cronet" |
+ |
+ output_name = "$root_out_dir/Cronet.framework/Info.plist" |
sdefresne
2016/07/01 12:50:11
I think this goes against how create_bundle/bundle
mef
2016/07/01 14:10:08
tweak_info_plist also puts correct version and rev
|
+ info_plist_target = ":cronet_framework_plist" |
+} |
+ |
ios_framework_bundle("cronet_framework") { |
output_name = "Cronet" |
deps = [ |
+ ":cronet_info_plist", |
":cronet_sources", |
"//base", |
"//net:net", |
] |
- info_plist = "Info.plist" |
- |
libs = [ "UIKit.Framework" ] |
public_headers = [ |
@@ -75,6 +89,17 @@ ios_framework_bundle("cronet_framework") { |
"Cronet.h", |
"Cronet.mm", |
] |
+ |
+ configs -= [ "//build/config/compiler:default_symbols" ] |
+ configs += [ "//build/config/compiler:symbols" ] |
+ |
+ ldflags = [] |
+ |
+ # For release version generate a separate dSYM. |
+ if (!is_debug) { |
+ ldflags += [ "-Wcrl,strip,-x" ] |
+ ldflags += [ "-Wcrl,dsym," + rebase_path(root_out_dir) ] |
+ } |
} |
bundle_data("cronet_test_bundle_data") { |
@@ -153,6 +178,9 @@ copy("cronet_package_copy") { |
"//components/cronet/ios/Cronet.h", |
"//components/cronet/ios/cronet_c_for_grpc.h", |
] |
+ if (!is_debug) { |
+ # sources += [ "$root_out_dir/Cronet.dSYM" ] |
+ } |
outputs = [ |
"$_package_dir/{{source_file_part}}", |
] |