Skip to content

Commit

Permalink
Enable hermetic builds for iOS.
Browse files Browse the repository at this point in the history
BUG=669094

Review-Url: https://codereview.chromium.org/2546613004
Cr-Commit-Position: refs/heads/master@{#437269}
  • Loading branch information
justincohen authored and Commit bot committed Dec 8, 2016
1 parent 4a2d1c8 commit 080de20
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 10 deletions.
9 changes: 7 additions & 2 deletions build/mac/should_use_hermetic_xcode.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,11 @@
# found in the LICENSE file.

"""Prints "1" if Chrome targets should be built with hermetic xcode. Otherwise
prints "0"."""
prints "0".
Usage:
python should_use_hermetic_xcode.py <target_os>
"""

import os
import sys
Expand All @@ -15,7 +19,8 @@ def _IsCorpMachine():


def main():
if os.environ.get('FORCE_MAC_TOOLCHAIN') or _IsCorpMachine():
allow_corp = sys.argv[1] == 'mac' and _IsCorpMachine()
if os.environ.get('FORCE_MAC_TOOLCHAIN') or allow_corp:
return "1"
else:
return "0"
Expand Down
12 changes: 4 additions & 8 deletions build_overrides/build.gni
Original file line number Diff line number Diff line change
Expand Up @@ -46,12 +46,8 @@ declare_args() {
}

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
}
_result = exec_script("//build/mac/should_use_hermetic_xcode.py",
[ target_os ],
"value")
use_system_xcode = _result == 0
}

0 comments on commit 080de20

Please sign in to comment.