| 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, List, Single, Static, Set, BadConf | 8 from slave.recipe_config import Dict, List, Single, Static, Set, BadConf |
| 9 from slave.recipe_config_types import Path | 9 from slave.recipe_config_types import Path |
| 10 | 10 |
| (...skipping 53 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 64 project_generator = ConfigGroup( | 64 project_generator = ConfigGroup( |
| 65 tool = Single(basestring, empty_val='gyp'), | 65 tool = Single(basestring, empty_val='gyp'), |
| 66 args = Set(basestring), | 66 args = Set(basestring), |
| 67 ), | 67 ), |
| 68 build_dir = Single(Path), | 68 build_dir = Single(Path), |
| 69 cros_sdk_args = List(basestring), | 69 cros_sdk_args = List(basestring), |
| 70 runtests = ConfigGroup( | 70 runtests = ConfigGroup( |
| 71 memory_tool = Single(basestring, required=False), | 71 memory_tool = Single(basestring, required=False), |
| 72 memory_tests_runner = Single(Path), | 72 memory_tests_runner = Single(Path), |
| 73 enable_lsan = Single(bool, empty_val=False, required=False), | 73 enable_lsan = Single(bool, empty_val=False, required=False), |
| 74 lsan_suppressions_file = Single(Path), | |
| 75 test_args = List(basestring), | 74 test_args = List(basestring), |
| 76 run_asan_test = Single(bool, required=False), | 75 run_asan_test = Single(bool, required=False), |
| 77 swarming_extra_args = List(basestring), | 76 swarming_extra_args = List(basestring), |
| 78 swarming_tags = Set(basestring), | 77 swarming_tags = Set(basestring), |
| 79 ), | 78 ), |
| 80 | 79 |
| 81 # Some platforms do not have a 1:1 correlation of BUILD_CONFIG to what is | 80 # Some platforms do not have a 1:1 correlation of BUILD_CONFIG to what is |
| 82 # passed as --target on the command line. | 81 # passed as --target on the command line. |
| 83 build_config_fs = Single(basestring), | 82 build_config_fs = Single(basestring), |
| 84 | 83 |
| (...skipping 305 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 390 if c.TARGET_PLATFORM in ['mac', 'win']: | 389 if c.TARGET_PLATFORM in ['mac', 'win']: |
| 391 # Set fastbuild=0 and prevent other configs from changing it. | 390 # Set fastbuild=0 and prevent other configs from changing it. |
| 392 fastbuild(c, invert=True, optional=False) | 391 fastbuild(c, invert=True, optional=False) |
| 393 | 392 |
| 394 c.gyp_env.GYP_DEFINES['asan'] = 1 | 393 c.gyp_env.GYP_DEFINES['asan'] = 1 |
| 395 c.gyp_env.GYP_DEFINES['lsan'] = 1 | 394 c.gyp_env.GYP_DEFINES['lsan'] = 1 |
| 396 | 395 |
| 397 @config_ctx(deps=['compiler']) | 396 @config_ctx(deps=['compiler']) |
| 398 def lsan(c): | 397 def lsan(c): |
| 399 c.runtests.enable_lsan = True | 398 c.runtests.enable_lsan = True |
| 400 c.runtests.lsan_suppressions_file = Path('[CHECKOUT]', 'tools', 'lsan', | |
| 401 'suppressions.txt') | |
| 402 c.runtests.swarming_extra_args += ['--lsan=1'] | 399 c.runtests.swarming_extra_args += ['--lsan=1'] |
| 403 c.runtests.swarming_tags |= {'lsan:1'} | 400 c.runtests.swarming_tags |= {'lsan:1'} |
| 404 | 401 |
| 405 # TODO(infra,earthdok,glider): Make this a gyp variable. This is also not a | 402 # TODO(infra,earthdok,glider): Make this a gyp variable. This is also not a |
| 406 # good name as only v8 builds release symbolized with -O2 while | 403 # good name as only v8 builds release symbolized with -O2 while |
| 407 # chromium.lkgr uses -O1. | 404 # chromium.lkgr uses -O1. |
| 408 @config_ctx() | 405 @config_ctx() |
| 409 def asan_symbolized(c): | 406 def asan_symbolized(c): |
| 410 c.gyp_env.GYP_DEFINES['release_extra_cflags'] = ( | 407 c.gyp_env.GYP_DEFINES['release_extra_cflags'] = ( |
| 411 '-gline-tables-only -O2 -fno-inline-functions -fno-inline') | 408 '-gline-tables-only -O2 -fno-inline-functions -fno-inline') |
| (...skipping 335 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 747 def chromium_perf_fyi(c): | 744 def chromium_perf_fyi(c): |
| 748 c.compile_py.clobber = False | 745 c.compile_py.clobber = False |
| 749 if c.HOST_PLATFORM == 'win': | 746 if c.HOST_PLATFORM == 'win': |
| 750 c.compile_py.compiler = None | 747 c.compile_py.compiler = None |
| 751 c.compile_py.goma_dir = None | 748 c.compile_py.goma_dir = None |
| 752 c.gyp_env.GYP_DEFINES['use_goma'] = 0 | 749 c.gyp_env.GYP_DEFINES['use_goma'] = 0 |
| 753 | 750 |
| 754 @config_ctx() | 751 @config_ctx() |
| 755 def chromium_deterministic_build(c): | 752 def chromium_deterministic_build(c): |
| 756 c.gyp_env.GYP_DEFINES['dont_embed_build_metadata'] = 1 | 753 c.gyp_env.GYP_DEFINES['dont_embed_build_metadata'] = 1 |
| OLD | NEW |