| OLD | NEW |
| 1 # Copyright 2015 The Chromium Authors. All rights reserved. | 1 # Copyright 2015 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 # TODO: remove redundant DEPS. | 5 # TODO: remove redundant DEPS. |
| 6 DEPS = [ | 6 DEPS = [ |
| 7 'file', | 7 'file', |
| 8 'depot_tools/infra_paths', | |
| 9 'recipe_engine/path', | 8 'recipe_engine/path', |
| 10 'recipe_engine/properties', | 9 'recipe_engine/properties', |
| 11 'repo', | 10 'repo', |
| 12 'recipe_engine/step', | 11 'recipe_engine/step', |
| 13 ] | 12 ] |
| 14 | 13 |
| 15 _TARGET_DEVICE_MAP = { | 14 _TARGET_DEVICE_MAP = { |
| 16 'volantis': { | 15 'volantis': { |
| 17 'bitness': 64, | 16 'bitness': 64, |
| 18 'make_jobs': 2, | 17 'make_jobs': 2, |
| (...skipping 30 matching lines...) Expand all Loading... |
| 49 api.repo.sync() | 48 api.repo.sync() |
| 50 | 49 |
| 51 def full_checkout(api): | 50 def full_checkout(api): |
| 52 api.repo.init('https://android.googlesource.com/platform/manifest', | 51 api.repo.init('https://android.googlesource.com/platform/manifest', |
| 53 '-b', 'master') | 52 '-b', 'master') |
| 54 api.repo.sync() | 53 api.repo.sync() |
| 55 | 54 |
| 56 def clobber(api): | 55 def clobber(api): |
| 57 # buildbot sets 'clobber' to the empty string which is falsey, check with 'in' | 56 # buildbot sets 'clobber' to the empty string which is falsey, check with 'in' |
| 58 if 'clobber' in api.properties: | 57 if 'clobber' in api.properties: |
| 59 api.file.rmtree('clobber', api.infra_paths['slave_build'].join('out')) | 58 api.file.rmtree('clobber', api.path['slave_build'].join('out')) |
| 60 | 59 |
| 61 def setup_host_x86(api, debug, bitness, concurrent_collector=False): | 60 def setup_host_x86(api, debug, bitness, concurrent_collector=False): |
| 62 with api.step.defer_results(): | 61 with api.step.defer_results(): |
| 63 checkout(api) | 62 checkout(api) |
| 64 clobber(api) | 63 clobber(api) |
| 65 | 64 |
| 66 build_top_dir = api.infra_paths['slave_build'] | 65 build_top_dir = api.path['slave_build'] |
| 67 art_tools = api.infra_paths['slave_build'].join('art', 'tools') | 66 art_tools = api.path['slave_build'].join('art', 'tools') |
| 68 env = { 'TARGET_PRODUCT': 'sdk', | 67 env = { 'TARGET_PRODUCT': 'sdk', |
| 69 'TARGET_BUILD_VARIANT': 'eng', | 68 'TARGET_BUILD_VARIANT': 'eng', |
| 70 'TARGET_BUILD_TYPE': 'release', | 69 'TARGET_BUILD_TYPE': 'release', |
| 71 'ANDROID_BUILD_TOP': build_top_dir, | 70 'ANDROID_BUILD_TOP': build_top_dir, |
| 72 'LEGACY_USE_JAVA7': 'true', | 71 'LEGACY_USE_JAVA7': 'true', |
| 73 'JACK_SERVER': 'false', | 72 'JACK_SERVER': 'false', |
| 74 'JACK_REPOSITORY': str(build_top_dir.join('prebuilts', 'sdk', | 73 'JACK_REPOSITORY': str(build_top_dir.join('prebuilts', 'sdk', |
| 75 'tools', 'jacks')), | 74 'tools', 'jacks')), |
| 76 'PATH': str(build_top_dir.join('out', 'host', 'linux-x86', 'bin')) + | 75 'PATH': str(build_top_dir.join('out', 'host', 'linux-x86', 'bin')) + |
| 77 api.path.pathsep + '%(PATH)s', | 76 api.path.pathsep + '%(PATH)s', |
| (...skipping 49 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 127 '--variant=X%d' % bitness] | 126 '--variant=X%d' % bitness] |
| 128 if debug: | 127 if debug: |
| 129 jdwp_command.append('--debug') | 128 jdwp_command.append('--debug') |
| 130 api.step('test jdwp', jdwp_command, env=env) | 129 api.step('test jdwp', jdwp_command, env=env) |
| 131 | 130 |
| 132 def setup_target(api, | 131 def setup_target(api, |
| 133 serial, | 132 serial, |
| 134 debug, | 133 debug, |
| 135 device, | 134 device, |
| 136 concurrent_collector=False): | 135 concurrent_collector=False): |
| 137 build_top_dir = api.infra_paths['slave_build'] | 136 build_top_dir = api.path['slave_build'] |
| 138 art_tools = api.infra_paths['slave_build'].join('art', 'tools') | 137 art_tools = api.path['slave_build'].join('art', 'tools') |
| 139 android_root = '/data/local/tmp/system' | 138 android_root = '/data/local/tmp/system' |
| 140 | 139 |
| 141 env = {'TARGET_BUILD_VARIANT': 'eng', | 140 env = {'TARGET_BUILD_VARIANT': 'eng', |
| 142 'TARGET_BUILD_TYPE': 'release', | 141 'TARGET_BUILD_TYPE': 'release', |
| 143 'ANDROID_SERIAL': serial, | 142 'ANDROID_SERIAL': serial, |
| 144 'ANDROID_BUILD_TOP': build_top_dir, | 143 'ANDROID_BUILD_TOP': build_top_dir, |
| 145 'PATH': str(build_top_dir.join('out', 'host', 'linux-x86', 'bin')) + | 144 'PATH': str(build_top_dir.join('out', 'host', 'linux-x86', 'bin')) + |
| 146 api.path.pathsep + '%(PATH)s', | 145 api.path.pathsep + '%(PATH)s', |
| 147 'LEGACY_USE_JAVA7': 'true', | 146 'LEGACY_USE_JAVA7': 'true', |
| 148 'JACK_SERVER': 'false', | 147 'JACK_SERVER': 'false', |
| (...skipping 325 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 474 # ) | 473 # ) |
| 475 # ) | 474 # ) |
| 476 # yield ( | 475 # yield ( |
| 477 # api.test('invalid buildername') + | 476 # api.test('invalid buildername') + |
| 478 # api.properties( | 477 # api.properties( |
| 479 # mastername='client.art', | 478 # mastername='client.art', |
| 480 # buildername='builder_does_not_exist', | 479 # buildername='builder_does_not_exist', |
| 481 # slavename='TestSlave', | 480 # slavename='TestSlave', |
| 482 # ) | 481 # ) |
| 483 # ) | 482 # ) |
| OLD | NEW |