OLD | NEW |
1 #!/usr/bin/env python | 1 #!/usr/bin/env python |
2 # Copyright 2013 The Chromium Authors. All rights reserved. | 2 # Copyright 2013 The Chromium Authors. All rights reserved. |
3 # Use of this source code is governed by a BSD-style license that can be | 3 # Use of this source code is governed by a BSD-style license that can be |
4 # found in the LICENSE file. | 4 # found in the LICENSE file. |
5 | 5 |
6 """ | 6 """ |
7 This file emits the list of reasons why a particular build needs to be clobbered | 7 This file emits the list of reasons why a particular build needs to be clobbered |
8 (or a list of 'landmines'). | 8 (or a list of 'landmines'). |
9 """ | 9 """ |
10 | 10 |
11 import optparse | |
12 import sys | 11 import sys |
13 | 12 |
14 import landmine_utils | 13 import landmine_utils |
15 | 14 |
16 | 15 |
17 builder = landmine_utils.builder | 16 builder = landmine_utils.builder |
18 distributor = landmine_utils.distributor | 17 distributor = landmine_utils.distributor |
19 gyp_defines = landmine_utils.gyp_defines | 18 gyp_defines = landmine_utils.gyp_defines |
20 gyp_msvs_version = landmine_utils.gyp_msvs_version | 19 gyp_msvs_version = landmine_utils.gyp_msvs_version |
21 platform = landmine_utils.platform | 20 platform = landmine_utils.platform |
22 | 21 |
23 | 22 |
24 def print_landmines(target): | 23 def print_landmines(): |
25 """ | 24 """ |
26 ALL LANDMINES ARE EMITTED FROM HERE. | 25 ALL LANDMINES ARE EMITTED FROM HERE. |
27 target can be one of {'Release', 'Debug', 'Debug_x64', 'Release_x64'}. | |
28 """ | 26 """ |
29 if (distributor() == 'goma' and platform() == 'win32' and | 27 if (distributor() == 'goma' and platform() == 'win32' and |
30 builder() == 'ninja'): | 28 builder() == 'ninja'): |
31 print 'Need to clobber winja goma due to backend cwd cache fix.' | 29 print 'Need to clobber winja goma due to backend cwd cache fix.' |
32 if platform() == 'android': | 30 if platform() == 'android': |
33 print 'Clobber: To delete generated class files (we just use jars now).' | 31 print 'Clobber: To delete generated class files (we just use jars now).' |
34 if platform() == 'win' and builder() == 'ninja': | 32 if platform() == 'win' and builder() == 'ninja': |
35 print 'Compile on cc_unittests fails due to symbols removed in r185063.' | 33 print 'Compile on cc_unittests fails due to symbols removed in r185063.' |
36 if platform() == 'linux' and builder() == 'ninja': | 34 if platform() == 'linux' and builder() == 'ninja': |
37 print 'Builders switching from make to ninja will clobber on this.' | 35 print 'Builders switching from make to ninja will clobber on this.' |
(...skipping 15 matching lines...) Expand all Loading... |
53 print 'Need to clobber everything due to gen file moves in r175513 (Blink)' | 51 print 'Need to clobber everything due to gen file moves in r175513 (Blink)' |
54 if (platform() != 'ios'): | 52 if (platform() != 'ios'): |
55 print 'Clobber to get rid of obselete test plugin after r248358' | 53 print 'Clobber to get rid of obselete test plugin after r248358' |
56 print 'Clobber to rebuild GN files for V8' | 54 print 'Clobber to rebuild GN files for V8' |
57 print 'Need to clobber everything due to build_nexe change in nacl r13424' | 55 print 'Need to clobber everything due to build_nexe change in nacl r13424' |
58 print '[chromium-dev] PSA: clobber build needed for IDR_INSPECTOR_* compil...' | 56 print '[chromium-dev] PSA: clobber build needed for IDR_INSPECTOR_* compil...' |
59 print 'blink_resources.grd changed: crbug.com/400860' | 57 print 'blink_resources.grd changed: crbug.com/400860' |
60 | 58 |
61 | 59 |
62 def main(): | 60 def main(): |
63 parser = optparse.OptionParser() | 61 print_landmines() |
64 parser.add_option('-t', '--target', | |
65 help=='Target for which the landmines have to be emitted') | |
66 | |
67 options, args = parser.parse_args() | |
68 | |
69 if args: | |
70 parser.error('Unknown arguments %s' % args) | |
71 | |
72 print_landmines(options.target) | |
73 return 0 | 62 return 0 |
74 | 63 |
75 | 64 |
76 if __name__ == '__main__': | 65 if __name__ == '__main__': |
77 sys.exit(main()) | 66 sys.exit(main()) |
OLD | NEW |