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 collections | 5 import collections |
6 import datetime | 6 import datetime |
7 import math | 7 import math |
8 import re | 8 import re |
9 | 9 |
10 from infra.libs.infra_types import freeze | 10 from infra.libs.infra_types import freeze |
(...skipping 327 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
338 if self.c.nacl.NACL_SDK_ROOT: | 338 if self.c.nacl.NACL_SDK_ROOT: |
339 env['NACL_SDK_ROOT'] = self.c.nacl.NACL_SDK_ROOT | 339 env['NACL_SDK_ROOT'] = self.c.nacl.NACL_SDK_ROOT |
340 args = [] | 340 args = [] |
341 if self.c.compile_py.compile_extra_args: | 341 if self.c.compile_py.compile_extra_args: |
342 args.extend(self.c.compile_py.compile_extra_args) | 342 args.extend(self.c.compile_py.compile_extra_args) |
343 self.m.chromium.compile(args, env=env, **kwargs) | 343 self.m.chromium.compile(args, env=env, **kwargs) |
344 | 344 |
345 # TODO(machenbach): This should move to a dynamorio module as soon as one | 345 # TODO(machenbach): This should move to a dynamorio module as soon as one |
346 # exists. | 346 # exists. |
347 def dr_compile(self): | 347 def dr_compile(self): |
348 self.m.path.makedirs( | 348 self.m.file.makedirs( |
349 'Create Build Dir', | 349 'Create Build Dir', |
350 self.m.path['slave_build'].join('dynamorio', 'build')) | 350 self.m.path['slave_build'].join('dynamorio', 'build')) |
351 self.m.step( | 351 self.m.step( |
352 'Configure Release x64 DynamoRIO', | 352 'Configure Release x64 DynamoRIO', |
353 ['cmake', '..', '-DDEBUG=OFF'], | 353 ['cmake', '..', '-DDEBUG=OFF'], |
354 cwd=self.m.path['slave_build'].join('dynamorio', 'build'), | 354 cwd=self.m.path['slave_build'].join('dynamorio', 'build'), |
355 ) | 355 ) |
356 self.m.step( | 356 self.m.step( |
357 'Compile Release x64 DynamoRIO', | 357 'Compile Release x64 DynamoRIO', |
358 ['make', '-j5'], | 358 ['make', '-j5'], |
359 cwd=self.m.path['slave_build'].join('dynamorio', 'build'), | 359 cwd=self.m.path['slave_build'].join('dynamorio', 'build'), |
360 ) | 360 ) |
361 | 361 |
362 @property | 362 @property |
363 def run_dynamorio(self): | 363 def run_dynamorio(self): |
364 return self.m.gclient.c.solutions[-1].name == 'dynamorio' | 364 return self.m.gclient.c.solutions[-1].name == 'dynamorio' |
365 | 365 |
366 def upload_build(self): | 366 def upload_build(self): |
367 self.m.archive.zip_and_upload_build( | 367 self.m.archive.zip_and_upload_build( |
368 'package build', | 368 'package build', |
369 self.m.chromium.c.build_config_fs, | 369 self.m.chromium.c.build_config_fs, |
370 self.GS_ARCHIVES[self.bot_config['build_gs_archive']], | 370 self.GS_ARCHIVES[self.bot_config['build_gs_archive']], |
371 src_dir='v8') | 371 src_dir='v8') |
372 | 372 |
373 def download_build(self): | 373 def download_build(self): |
374 self.m.path.rmtree( | 374 self.m.file.rmtree( |
375 'build directory', | 375 'build directory', |
376 self.m.chromium.c.build_dir.join(self.m.chromium.c.build_config_fs)) | 376 self.m.chromium.c.build_dir.join(self.m.chromium.c.build_config_fs)) |
377 | 377 |
378 self.m.archive.download_and_unzip_build( | 378 self.m.archive.download_and_unzip_build( |
379 'extract build', | 379 'extract build', |
380 self.m.chromium.c.build_config_fs, | 380 self.m.chromium.c.build_config_fs, |
381 self.GS_ARCHIVES[self.bot_config['build_gs_archive']], | 381 self.GS_ARCHIVES[self.bot_config['build_gs_archive']], |
382 src_dir='v8') | 382 src_dir='v8') |
383 | 383 |
384 | 384 |
(...skipping 494 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
879 triggers = self.bot_config.get('triggers') | 879 triggers = self.bot_config.get('triggers') |
880 if triggers: | 880 if triggers: |
881 self.m.trigger(*[{ | 881 self.m.trigger(*[{ |
882 'builder_name': builder_name, | 882 'builder_name': builder_name, |
883 'properties': { | 883 'properties': { |
884 'revision': self.revision, | 884 'revision': self.revision, |
885 'parent_got_revision': self.revision, | 885 'parent_got_revision': self.revision, |
886 'parent_got_revision_cp': self.revision_cp, | 886 'parent_got_revision_cp': self.revision_cp, |
887 }, | 887 }, |
888 } for builder_name in triggers]) | 888 } for builder_name in triggers]) |
OLD | NEW |