Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

gyp: fix XCode CLT version detection on Catalina #44

Merged
merged 3 commits into from
Jun 5, 2020
Merged
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 7 additions & 0 deletions pylib/gyp/xcode_emulation.py
Original file line number Diff line number Diff line change
Expand Up @@ -1541,6 +1541,13 @@ def CLTVersion():
except GypError:
continue

regex = re.compile(r'Command Line Tools for Xcode\s+(?P<version>\S+)')
try:
output = GetStdout(['/usr/sbin/softwareupdate', '--history'])
return re.search(regex, output).groupdict()['version']
cclauss marked this conversation as resolved.
Show resolved Hide resolved
except GypError:
return None


def GetStdoutQuiet(cmdlist):
"""Returns the content of standard output returned by invoking |cmdlist|.
Expand Down