Use the system shell to see if we can find a 'gn' binary on $PATH. This solves the error wherein subprocess.call fails ungracefully if the binary doesn't exist.
llvm-svn: 355645
# Find real gn executable.
gn = 'gn'
if subprocess.call([gn, '--version'], stdout=open(os.devnull, 'w'),
- stderr=subprocess.STDOUT) != 0:
+ stderr=subprocess.STDOUT,
+ shell=True) != 0:
# Not on path. See if get.py downloaded a prebuilt binary and run that
# if it's there, or suggest to run get.py if it isn't.
platform = get_platform()