| 91 | return 0 if all(code == 0 for code in codes) else 1 |
| 92 | |
| 93 | def get_default_out_dir(args): |
| 94 | default_out_dir = os.path.join('out', args.config) |
| 95 | if not args.is_win: |
| 96 | # POSIX platforms only have one out dir. |
| 97 | return default_out_dir |
| 98 | # On Windows depending on the args of GYP and configure script, the out dir |
| 99 | # could be 'out/Release', 'out/Debug' or just 'Release' or 'Debug'. |
| 100 | if os.path.exists(default_out_dir): |
| 101 | return default_out_dir |
| 102 | if os.path.exists(args.config): |
| 103 | return args.config |
| 104 | raise RuntimeError('Cannot find out dir, did you run build?') |
| 105 | |
| 106 | def main(): |
| 107 | if sys.platform == 'cygwin': |