Skip to content

Commit 24536e3

Browse files
authored
Warn that go is required on PATH (#38)
1 parent 55f4d2c commit 24536e3

File tree

1 file changed

+11
-0
lines changed

1 file changed

+11
-0
lines changed

tool/update-boringssl.py

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -271,15 +271,26 @@ def mkdirp(path):
271271

272272

273273
def main():
274+
if shutil.which('go') is None:
275+
print('Could not find "go" on $PATH')
276+
return 1
277+
if shutil.which('git') is None:
278+
print('Could not find "git" on $PATH')
279+
return 1
280+
if shutil.which('perl') is None:
281+
print('Could not find "perl" on $PATH')
282+
return 1
274283
try:
275284
print('Updating third_party/boringssl/')
276285
tmp = tempfile.mkdtemp(prefix='update-boringssl-')
277286
cleanup()
278287
git_clone(tmp)
279288
generate(tmp)
280289
print('Updated to BoringSSL revision: ' + BORINGSSL_REVISION)
290+
return 0
281291
finally:
282292
shutil.rmtree(tmp)
293+
return 1
283294

284295

285296
if __name__ == '__main__':

0 commit comments

Comments
 (0)