]>
Commit | Line | Data |
---|---|---|
f0db7b91 ER |
1 | fix error reporting: |
2 | ||
3 | ... | |
4 | File "chromium/scripts/generate_gyp.py", line 757, in GetIncludedSources | |
5 | exit('Failed to find file', include_file_path) | |
6 | TypeError: __call__() takes at most 2 arguments (3 given) | |
7 | ||
af2c0365 ER |
8 | --- chromium-browser-47.0.2526.58/third_party/ffmpeg/chromium/scripts/generate_gyp.py~ 2015-11-15 00:56:33.000000000 +0200 |
9 | +++ chromium-browser-47.0.2526.58/third_party/ffmpeg/chromium/scripts/generate_gyp.py 2015-11-15 10:57:18.342220254 +0200 | |
f0db7b91 ER |
10 | @@ -149,6 +150,9 @@ |
11 | # Mac doesn't have any platform specific files, so just use linux and win. | |
12 | SUPPORTED_PLATFORMS = ['linux', 'win'] | |
13 | ||
14 | +def die(error): | |
15 | + print >> sys.stderr, error | |
16 | + sys.exit(1) | |
17 | ||
18 | def NormalizeFilename(name): | |
19 | """ Removes leading path separators in an attempt to normalize paths.""" | |
af2c0365 | 20 | @@ -850,7 +850,7 @@ |
f0db7b91 ER |
21 | elif include_file_path in IGNORED_INCLUDE_FILES: |
22 | continue | |
23 | else: | |
af2c0365 ER |
24 | - exit('Failed to find file ' + include_file_path) |
25 | + die('Failed to find file ' + include_file_path) | |
f0db7b91 ER |
26 | |
27 | # At this point we've found the file. Check if its in our ignore list which | |
28 | # means that the list should be updated to no longer mention this file. | |
29 | @@ -772,7 +776,7 @@ | |
30 | licensecheck_path = os.path.abspath(os.path.join( | |
31 | source_root, 'third_party', 'devscripts', 'licensecheck.pl')); | |
32 | if not os.path.exists(licensecheck_path): | |
33 | - exit('Could not find licensecheck.pl: ' + str(licensecheck_path)) | |
34 | + die('Could not find licensecheck.pl: ' + str(licensecheck_path)) | |
35 | ||
36 | check_process = subprocess.Popen([licensecheck_path, | |
37 | '-l', '100', | |
38 | @@ -838,7 +842,7 @@ | |
39 | ||
40 | # Sanity check: source set should not have any renames prior to this step. | |
41 | if RENAME_PREFIX in basename: | |
42 | - exit('Found unexpected renamed file in SourceSet: %s' % basename) | |
43 | + die('Found unexpected renamed file in SourceSet: %s' % basename) | |
44 | ||
45 | # Craft a new unique basename from the path of the colliding file | |
46 | if basename in known_basenames: | |
47 | @@ -896,7 +900,7 @@ | |
48 | sets = CreatePairwiseDisjointSets(sets) | |
49 | ||
50 | if not sets: | |
51 | - exit('ERROR: failed to find any source sets. ' + | |
52 | + die('ERROR: failed to find any source sets. ' + | |
53 | 'Are build_dir (%s) and/or source_dir (%s) options correct?' % | |
54 | (options.build_dir, options.source_dir)) | |
55 | ||
af2c0365 | 56 | @@ -1017,7 +1017,7 @@ |
f0db7b91 | 57 | |
af2c0365 | 58 | if not CheckLicensesForStaticLinking(sources_to_check, source_dir, |
f0db7b91 | 59 | options.print_licenses): |
af2c0365 | 60 | - exit('GENERATE FAILED: invalid licenses detected.') |
f0db7b91 ER |
61 | + die('GENERATE FAILED: invalid licenses detected.') |
62 | print 'License checks passed.' | |
af2c0365 | 63 | UpdateCredits(sources_to_check, source_dir) |
f0db7b91 | 64 |