| OLD | NEW |
| 1 # Copyright 2013 The Chromium Authors. All rights reserved. | 1 # Copyright 2013 The Chromium Authors. All rights reserved. |
| 2 # Use of this source code is governed by a BSD-style license that can be | 2 # Use of this source code is governed by a BSD-style license that can be |
| 3 # found in the LICENSE file. | 3 # found in the LICENSE file. |
| 4 | 4 |
| 5 import pipes | 5 import pipes |
| 6 | 6 |
| 7 from slave.recipe_config import config_item_context, ConfigGroup | 7 from slave.recipe_config import config_item_context, ConfigGroup |
| 8 from slave.recipe_config import Dict, Single, Static, Set, BadConf | 8 from slave.recipe_config import Dict, Single, Static, Set, BadConf |
| 9 from slave.recipe_config_types import Path | 9 from slave.recipe_config_types import Path |
| 10 | 10 |
| (...skipping 443 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 454 | 454 |
| 455 def _android_common(c): | 455 def _android_common(c): |
| 456 gyp_defs = c.gyp_env.GYP_DEFINES | 456 gyp_defs = c.gyp_env.GYP_DEFINES |
| 457 gyp_defs['fastbuild'] = 1 | 457 gyp_defs['fastbuild'] = 1 |
| 458 gyp_defs['OS'] = c.TARGET_PLATFORM | 458 gyp_defs['OS'] = c.TARGET_PLATFORM |
| 459 | 459 |
| 460 @config_ctx(includes=['ninja', 'shared_library', 'jsonclang']) | 460 @config_ctx(includes=['ninja', 'shared_library', 'jsonclang']) |
| 461 def codesearch(c): | 461 def codesearch(c): |
| 462 gyp_defs = c.gyp_env.GYP_DEFINES | 462 gyp_defs = c.gyp_env.GYP_DEFINES |
| 463 gyp_defs['fastbuild'] = 1 | 463 gyp_defs['fastbuild'] = 1 |
| 464 |
| 465 @config_ctx(includes=['ninja', 'static_library']) |
| 466 def chrome_pgo_base(c): |
| 467 c.gyp_env.GYP_DEFINES['buildtype'] = 'Official' |
| 468 c.gyp_env.GYP_DEFINES['optimize'] = 'max' |
| 469 c.gyp_env.GYP_DEFINES['use_goma'] = 0 |
| 470 fastbuild(c, invert=True) |
| 471 c.compile_py.default_targets = ['chrome'] |
| 472 |
| 473 #### 'Full' configurations |
| 474 @config_ctx(includes=['chrome_pgo_base']) |
| 475 def chrome_pgo_instrument(c): |
| 476 c.gyp_env.GYP_DEFINES['chrome_pgo_phase'] = 1 |
| 477 |
| 478 @config_ctx(includes=['chrome_pgo_base']) |
| 479 def chrome_pgo_optimize(c): |
| 480 c.gyp_env.GYP_DEFINES['chrome_pgo_phase'] = 2 |
| OLD | NEW |