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

Unified Diff: build/config/ios/rules.gni

Issue 2452593004: Correct iOS GN hermetic support. (Closed)
Patch Set: Changes for sdefresne Created 4 years, 2 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 | « build/config/ios/ios_sdk.gni ('k') | build/toolchain/mac/linker_driver.py » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: build/config/ios/rules.gni
diff --git a/build/config/ios/rules.gni b/build/config/ios/rules.gni
index ada465a9bd56623e880e116671fb6910d9bbfdbd..cf2548f1bfbc2999dd45695702ee483237faf819 100644
--- a/build/config/ios/rules.gni
+++ b/build/config/ios/rules.gni
@@ -5,6 +5,7 @@
import("//build/config/ios/ios_sdk.gni")
import("//build/config/mac/base_rules.gni")
import("//build/config/mac/symbols.gni")
+import("//build/toolchain/toolchain.gni")
# Invokes lipo on multiple arch-specific binaries to create a fat binary.
#
@@ -75,13 +76,20 @@ template("lipo_binary") {
deps += [ "$_arch_binary_target($_toolchain)" ]
}
- args = [
- "xcrun",
- "lipo",
- "-create",
- "-output",
- rebase_path("$target_out_dir/$_output_name", root_build_dir),
- ] + rebase_path(inputs, root_build_dir)
+ args = []
+ if (!use_system_xcode) {
+ args += [
+ "--developer_dir",
+ hermetic_xcode_path,
+ ]
+ }
+ args += [
+ "xcrun",
+ "lipo",
+ "-create",
+ "-output",
+ rebase_path("$target_out_dir/$_output_name", root_build_dir),
+ ] + rebase_path(inputs, root_build_dir)
if (enable_dsyms) {
_dsyms_output_dir = "$root_out_dir/$_output_name.dSYM"
@@ -234,7 +242,14 @@ template("create_signed_bundle") {
}
}
- code_signing_args = [
+ code_signing_args = []
+ if (!use_system_xcode) {
+ code_signing_args += [
+ "--developer_dir",
+ hermetic_xcode_path,
+ ]
+ }
+ code_signing_args += [
"code-sign-bundle",
"-t=" + ios_sdk_name,
"-i=" + ios_code_signing_identity,
@@ -544,11 +559,19 @@ template("ios_app_bundle") {
outputs = [
_generate_entitlements_output,
]
- args = [
- "generate-entitlements",
- "-e=" + rebase_path(_entitlements_path, root_build_dir),
- "-p=" + rebase_path(_info_plist_path, root_build_dir),
- ] + rebase_path(outputs, root_build_dir)
+
+ args = []
+ if (!use_system_xcode) {
+ args += [
+ "--developer_dir",
+ hermetic_xcode_path,
+ ]
+ }
+ args += [
+ "generate-entitlements",
+ "-e=" + rebase_path(_entitlements_path, root_build_dir),
+ "-p=" + rebase_path(_info_plist_path, root_build_dir),
+ ] + rebase_path(outputs, root_build_dir)
}
}
« no previous file with comments | « build/config/ios/ios_sdk.gni ('k') | build/toolchain/mac/linker_driver.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698