From c4eb24a9073e887c0f65dca33c3eeedf8b5f9aef Mon Sep 17 00:00:00 2001 From: "brucedawson@chromium.org" Date: Sat, 6 Feb 2016 02:24:31 +0000 Subject: [PATCH] Skip installation of UCRT The UCRT is now optional and it failed to install on one builder. Making optional to fix build break If this doesn't fix the break on the waterfall then the switch to VS 2015 will need to be reverted (crrev.com/1598493004). TBR=scottmg@chromium.org BUG=440500 Review URL: https://codereview.chromium.org/1680433002 git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@298634 0039d316-1c4b-4281-b951-d872f2087c98 --- win_toolchain/get_toolchain_if_necessary.py | 31 +-------------------- 1 file changed, 1 insertion(+), 30 deletions(-) diff --git a/win_toolchain/get_toolchain_if_necessary.py b/win_toolchain/get_toolchain_if_necessary.py index 33e057b62..0ac500b16 100755 --- a/win_toolchain/get_toolchain_if_necessary.py +++ b/win_toolchain/get_toolchain_if_necessary.py @@ -354,36 +354,7 @@ def GetInstallerName(): def InstallUniversalCRTIfNeeded(abs_target_dir): - installer_name = GetInstallerName() - if not installer_name: - return - - bitness = platform.architecture()[0] - # When running 64-bit python the x64 DLLs will be in System32 - x64_path = 'System32' if bitness == '64bit' else 'Sysnative' - x64_path = os.path.join(r'C:\Windows', x64_path) - sample_crt_file = os.path.join(x64_path, 'ucrtbase.dll') - - if os.path.exists(sample_crt_file): - # Nothing to do. - return - - print ('%s does not exist - installing Windows 10 Universal C Runtime' % - sample_crt_file) - - installer = os.path.join(abs_target_dir, "installers", installer_name) - command = r'wusa.exe /quiet "%s"' % installer - print 'Running %s' % command - - try: - subprocess.check_call(command) - # Trap OSError instead of WindowsError so pylint will succeed on Linux. - except OSError as e: - if e.winerror == 740: # The requested operation requires elevation - print 'Elevation required. You can manually install this update:' - print ' %s' % installer - return - raise e + return def main():