Index: build/toolchain/toolchain.gni |
diff --git a/build/toolchain/toolchain.gni b/build/toolchain/toolchain.gni |
index ca4bc2a7790e67dec020285ce78ede46f02bbdeb..4e49678ab920a3f69e03899038b947a3ef62526b 100644 |
--- a/build/toolchain/toolchain.gni |
+++ b/build/toolchain/toolchain.gni |
@@ -49,9 +49,15 @@ declare_args() { |
use_system_xcode = "" |
} |
-if ((is_mac || is_ios) && use_system_xcode == "") { |
- _result = getenv("FORCE_MAC_TOOLCHAIN") |
- use_system_xcode = _result == "" |
+if (use_system_xcode == "") { |
+ if (target_os == "mac") { |
+ _result = |
+ exec_script("//build/mac/should_use_hermetic_xcode.py", [], "value") |
+ use_system_xcode = _result == 0 |
+ } |
+ if (target_os == "ios") { |
+ use_system_xcode = true |
+ } |
} |
# The path to the hermetic install of Xcode. Only relevant when |