Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(212)

Unified Diff: components/cronet/ios/BUILD.gn

Issue 2115583002: GN Rule to build Cronet Dynamic Framework for iOS. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Don't use @loader_path. Created 4 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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}}",
]
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698