Skip to content

Commit feff3f9

Browse files
author
libm
committed
Return non-zero when error to inform ninja of the failure.
1 parent 41b1fbf commit feff3f9

File tree

1 file changed

+7
-7
lines changed

1 file changed

+7
-7
lines changed

tools/package_binaries.py

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -26,11 +26,11 @@
2626
tmp = sys.argv[sys.argv.index('-p') + 1]
2727
if not os.path.isabs(tmp):
2828
print 'the path is not an absolute path.\n'
29-
exit()
29+
exit(-1)
3030

3131
if not os.path.exists(tmp):
3232
print 'the directory does not exist.\n'
33-
exit()
33+
exit(-1)
3434

3535
project_root = tmp
3636

@@ -50,27 +50,27 @@
5050
if platform_name == 'linux' and not os.path.exists(
5151
os.path.join(project_root, 'nw')):
5252
print 'nw file does not exist.\n'
53-
exit()
53+
exit(-1)
5454

5555
if platform_name == 'win' and not os.path.exists(
5656
os.path.join(project_root, 'nw.exe')):
5757
print 'nw file does not exist.\n'
58-
exit()
58+
exit(-1)
5959

6060
if platform_name == 'osx' and not os.path.exists(
6161
os.path.join(project_root, 'node-webkit.app')):
6262
print 'nw file does not exist.\n'
63-
exit()
63+
exit(-1)
6464

6565
if platform_name != 'win' and not os.path.exists(
6666
os.path.join(project_root, 'chromedriver2_server')):
6767
print 'chromedriver2_server file does not exist.\n'
68-
exit()
68+
exit(-1)
6969

7070
if platform_name == 'win' and not os.path.exists(
7171
os.path.join(project_root, 'chromedriver2_server.exe')):
7272
print 'chromedriver2_server file does not exist.\n'
73-
exit()
73+
exit(-1)
7474

7575

7676
required_file_linux = (

0 commit comments

Comments
 (0)