Older versions of python 2.7 can raise a WindowsError instead of a subprocess.CalledProcessError when `uname` does not exist
This commit is contained in:
parent
375fa6ef37
commit
ad88d50fba
|
@ -265,7 +265,7 @@ class RustBuild:
|
|||
try:
|
||||
ostype = subprocess.check_output(['uname', '-s']).strip()
|
||||
cputype = subprocess.check_output(['uname', '-m']).strip()
|
||||
except subprocess.CalledProcessError:
|
||||
except (subprocess.CalledProcessError, WindowsError):
|
||||
if sys.platform == 'win32':
|
||||
return 'x86_64-pc-windows-msvc'
|
||||
err = "uname not found"
|
||||
|
|
Loading…
Reference in New Issue