[email protected] | ec069f7 | 2013-08-21 02:44:58 | [diff] [blame] | 1 | #!/usr/bin/env python |
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 | ||||
4 | # found in the LICENSE file. | ||||
5 | |||||
6 | """ | ||||
7 | This file emits the list of reasons why a particular build needs to be clobbered | ||||
8 | (or a list of 'landmines'). | ||||
9 | """ | ||||
10 | |||||
[email protected] | ec069f7 | 2013-08-21 02:44:58 | [diff] [blame] | 11 | import sys |
12 | |||||
13 | import landmine_utils | ||||
14 | |||||
15 | |||||
Michael Achenbach | d76f98f | 2018-02-16 22:40:01 | [diff] [blame^] | 16 | host_os = landmine_utils.host_os |
[email protected] | ec069f7 | 2013-08-21 02:44:58 | [diff] [blame] | 17 | |
18 | |||||
[email protected] | 9372bec | 2014-08-14 14:03:30 | [diff] [blame] | 19 | def print_landmines(): |
[email protected] | ec069f7 | 2013-08-21 02:44:58 | [diff] [blame] | 20 | """ |
21 | ALL LANDMINES ARE EMITTED FROM HERE. | ||||
[email protected] | ec069f7 | 2013-08-21 02:44:58 | [diff] [blame] | 22 | """ |
thakis | 37066a5 | 2015-03-23 18:57:55 | [diff] [blame] | 23 | # DO NOT add landmines as part of a regular CL. Landmines are a last-effort |
24 | # bandaid fix if a CL that got landed has a build dependency bug and all bots | ||||
25 | # need to be cleaned up. If you're writing a new CL that causes build | ||||
26 | # dependency problems, fix the dependency problems instead of adding a | ||||
27 | # landmine. | ||||
brucedawson | a1ed2e0 | 2017-06-30 01:25:11 | [diff] [blame] | 28 | # |
29 | # Before adding or changing a landmine consider the consequences of doing so. | ||||
30 | # Doing so will wipe out every output directory on every Chrome developer's | ||||
31 | # machine. This can be particularly problematic on Windows where the directory | ||||
32 | # deletion may well fail (locked files, command prompt in the directory, | ||||
33 | # etc.), and generated .sln and .vcxproj files will be deleted. | ||||
34 | # | ||||
35 | # This output directory deletion will be repeated when going back and forth | ||||
36 | # across the change that added the landmine, adding to the cost. There are | ||||
37 | # usually less troublesome alternatives. | ||||
thakis | 37066a5 | 2015-03-23 18:57:55 | [diff] [blame] | 38 | |
Michael Achenbach | d76f98f | 2018-02-16 22:40:01 | [diff] [blame^] | 39 | if host_os() == 'win': |
[email protected] | ec069f7 | 2013-08-21 02:44:58 | [diff] [blame] | 40 | print 'Compile on cc_unittests fails due to symbols removed in r185063.' |
Michael Achenbach | d76f98f | 2018-02-16 22:40:01 | [diff] [blame^] | 41 | if host_os() == 'linux': |
[email protected] | ec069f7 | 2013-08-21 02:44:58 | [diff] [blame] | 42 | print 'Builders switching from make to ninja will clobber on this.' |
Michael Achenbach | d76f98f | 2018-02-16 22:40:01 | [diff] [blame^] | 43 | if host_os() == 'mac': |
[email protected] | ec069f7 | 2013-08-21 02:44:58 | [diff] [blame] | 44 | print 'Switching from bundle to unbundled dylib (issue 14743002).' |
Michael Achenbach | d76f98f | 2018-02-16 22:40:01 | [diff] [blame^] | 45 | if host_os() in ('win', 'mac'): |
[email protected] | 03d73c0d | 2013-12-16 21:48:08 | [diff] [blame] | 46 | print ('Improper dependency for create_nmf.py broke in r240802, ' |
47 | 'fixed in r240860.') | ||||
Michael Achenbach | d76f98f | 2018-02-16 22:40:01 | [diff] [blame^] | 48 | if host_os() == 'win': |
scottmg | b77dd49 | 2016-12-08 05:58:07 | [diff] [blame] | 49 | print 'Switch to VS2015 Update 3, 14393 SDK' |
[email protected] | ec069f7 | 2013-08-21 02:44:58 | [diff] [blame] | 50 | print 'Need to clobber everything due to an IDL change in r154579 (blink)' |
[email protected] | 267e9a14 | 2014-06-06 11:25:13 | [diff] [blame] | 51 | print 'Need to clobber everything due to gen file moves in r175513 (Blink)' |
Michael Achenbach | d76f98f | 2018-02-16 22:40:01 | [diff] [blame^] | 52 | print 'Clobber to get rid of obselete test plugin after r248358' |
53 | print 'Clobber to rebuild GN files for V8' | ||||
blundell | 70fb54767 | 2015-01-19 17:18:33 | [diff] [blame] | 54 | print 'Clobber to get rid of stale generated mojom.h files' |
[email protected] | 9b38589 | 2014-07-02 23:11:11 | [diff] [blame] | 55 | print 'Need to clobber everything due to build_nexe change in nacl r13424' |
[email protected] | 74e1931 | 2014-08-01 22:08:49 | [diff] [blame] | 56 | print '[chromium-dev] PSA: clobber build needed for IDR_INSPECTOR_* compil...' |
[email protected] | c1161806 | 2014-08-05 23:21:53 | [diff] [blame] | 57 | print 'blink_resources.grd changed: crbug.com/400860' |
Nico Weber | 9f49a7a | 2014-09-02 23:42:42 | [diff] [blame] | 58 | print 'ninja dependency cycle: crbug.com/408192' |
petrcermak | 7652da6d | 2014-11-06 02:17:57 | [diff] [blame] | 59 | print 'Clobber to fix missing NaCl gyp dependencies (crbug.com/427427).' |
dcheng | f883604 | 2014-11-26 05:04:55 | [diff] [blame] | 60 | print 'Another clobber for missing NaCl gyp deps (crbug.com/427427).' |
Daniel Cheng | d1a85ae | 2014-12-23 22:54:10 | [diff] [blame] | 61 | print 'Clobber to fix GN not picking up increased ID range (crbug.com/444902)' |
ncbray | 4453c50a | 2015-02-18 20:10:55 | [diff] [blame] | 62 | print 'Remove NaCl toolchains from the output dir (crbug.com/456902)' |
Michael Achenbach | d76f98f | 2018-02-16 22:40:01 | [diff] [blame^] | 63 | if host_os() == 'win': |
luqui | 7434b00 | 2015-07-14 20:27:55 | [diff] [blame] | 64 | print 'Clobber to delete stale generated files (crbug.com/510086)' |
Michael Achenbach | d76f98f | 2018-02-16 22:40:01 | [diff] [blame^] | 65 | if host_os() == 'mac': |
luqui | c3c801e | 2015-09-02 00:19:54 | [diff] [blame] | 66 | print 'Clobber to get rid of evil libsqlite3.dylib (crbug.com/526208)' |
Michael Achenbach | d76f98f | 2018-02-16 22:40:01 | [diff] [blame^] | 67 | if host_os() == 'mac': |
bpastene | 9b4f062 | 2016-06-16 19:26:08 | [diff] [blame] | 68 | print 'Clobber to remove libsystem.dylib. See crbug.com/620075' |
Michael Achenbach | d76f98f | 2018-02-16 22:40:01 | [diff] [blame^] | 69 | if host_os() == 'mac': |
Philip Jägenstedt | 117c52b0 | 2017-01-11 09:25:44 | [diff] [blame] | 70 | print 'Clobber to get past mojo gen build error (crbug.com/679607)' |
Michael Achenbach | d76f98f | 2018-02-16 22:40:01 | [diff] [blame^] | 71 | if host_os() == 'win': |
brettw | f78cc27 | 2017-03-24 16:36:42 | [diff] [blame] | 72 | print 'Clobber Windows to fix strange PCH-not-rebuilt errors.' |
Andrii Shyshkalov | a84d39a | 2017-06-23 09:58:48 | [diff] [blame] | 73 | print 'CLobber all to fix GN breakage (crbug.com/736215)' |
[email protected] | ec069f7 | 2013-08-21 02:44:58 | [diff] [blame] | 74 | |
75 | def main(): | ||||
[email protected] | 9372bec | 2014-08-14 14:03:30 | [diff] [blame] | 76 | print_landmines() |
[email protected] | ec069f7 | 2013-08-21 02:44:58 | [diff] [blame] | 77 | return 0 |
78 | |||||
79 | |||||
80 | if __name__ == '__main__': | ||||
81 | sys.exit(main()) |