Skip to content

Commit

Permalink
Set DEVELOPER_DIR in sizes.py on Mac
Browse files Browse the repository at this point in the history
Otherwise the 'size' command doesn't work unless there's a system xcode around,
which there isn't on newer buildbots.

Bug: 934698
Change-Id: I930ee63b695ab000efa301abc2c169111eb66da3
Reviewed-on: https://chromium-review.googlesource.com/c/1482950
Commit-Queue: Hans Wennborg <hans@chromium.org>
Reviewed-by: Nico Weber <thakis@chromium.org>
Cr-Commit-Position: refs/heads/master@{#634643}
  • Loading branch information
zmodem committed Feb 22, 2019
1 parent 0fe1d24 commit ebb3e9e
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions infra/scripts/legacy/scripts/slave/chromium/sizes.py
Original file line number Diff line number Diff line change
Expand Up @@ -92,6 +92,12 @@ def main_mac(options, args, results_collector):
build_dir = build_directory.GetBuildOutputDirectory(SRC_DIR)
target_dir = os.path.join(build_dir, options.target)

"""Set DEVELOPER_DIR to the hermetic Xcode.app so 'size' will work."""
if not 'DEVELOPER_DIR' in os.environ:
xcode_path = os.path.join(SRC_DIR, 'build', 'mac_files', 'Xcode.app');
if os.path.exists(xcode_path):
os.environ['DEVELOPER_DIR'] = xcode_path

result = 0
# Work with either build type.
base_names = ('Chromium', 'Google Chrome')
Expand Down

0 comments on commit ebb3e9e

Please sign in to comment.