diff options
author | Torne (Richard Coles) <torne@google.com> | 2014-05-15 12:16:31 +0100 |
---|---|---|
committer | Torne (Richard Coles) <torne@google.com> | 2014-05-15 12:16:31 +0100 |
commit | 0de6073388f4e2780db8536178b129cd8f6ab386 (patch) | |
tree | f22df67d2450c33e245fa27d50f001b403434315 /build | |
parent | 237b4e8281feb4bb44a23557a97fcbbd55133d68 (diff) | |
download | chromium_org-0de6073388f4e2780db8536178b129cd8f6ab386.tar.gz |
Merge from Chromium at DEPS revision 269467
This commit was generated by merge_to_master.py.
Change-Id: Id6c03d44b5ad8b098017a943eb9ec8d804dfed99
Diffstat (limited to 'build')
-rwxr-xr-x | build/android/buildbot/bb_device_steps.py | 39 | ||||
-rwxr-xr-x | build/android/buildbot/bb_run_bot.py | 5 | ||||
-rwxr-xr-x | build/android/provision_devices.py | 25 | ||||
-rw-r--r-- | build/android/pylib/device/device_utils.py | 35 | ||||
-rw-r--r-- | build/common.gypi | 16 | ||||
-rw-r--r-- | build/linux/system.gyp | 6 | ||||
-rw-r--r-- | build/util/LASTCHANGE | 2 | ||||
-rw-r--r-- | build/util/LASTCHANGE.blink | 2 |
8 files changed, 73 insertions, 57 deletions
diff --git a/build/android/buildbot/bb_device_steps.py b/build/android/buildbot/bb_device_steps.py index d95529888c..7ca0007d78 100755 --- a/build/android/buildbot/bb_device_steps.py +++ b/build/android/buildbot/bb_device_steps.py @@ -7,7 +7,6 @@ import collections import glob import hashlib import json -import multiprocessing import os import random import re @@ -27,10 +26,6 @@ from pylib.gtest import gtest_config CHROME_SRC_DIR = bb_utils.CHROME_SRC DIR_BUILD_ROOT = os.path.dirname(CHROME_SRC_DIR) CHROME_OUT_DIR = bb_utils.CHROME_OUT_DIR -sys.path.append(os.path.join( - CHROME_SRC_DIR, 'third_party', 'android_testrunner')) -import errors - SLAVE_SCRIPTS_DIR = os.path.join(bb_utils.BB_BUILD_DIR, 'scripts', 'slave') LOGCAT_DIR = os.path.join(bb_utils.CHROME_OUT_DIR, 'logcat') @@ -101,37 +96,6 @@ def _GetRevision(options): return revision -# multiprocessing map_async requires a top-level function for pickle library. -def RebootDeviceSafe(device): - """Reboot a device, wait for it to start, and squelch timeout exceptions.""" - try: - device_utils.DeviceUtils(device).old_interface.Reboot(True) - except errors.DeviceUnresponsiveError as e: - return e - - -def RebootDevices(): - """Reboot all attached and online devices.""" - # Early return here to avoid presubmit dependence on adb, - # which might not exist in this checkout. - if bb_utils.TESTING: - return - devices = android_commands.GetAttachedDevices() - print 'Rebooting: %s' % devices - if devices: - pool = multiprocessing.Pool(len(devices)) - results = pool.map_async(RebootDeviceSafe, devices).get(99999) - - for device, result in zip(devices, results): - if result: - print '%s failed to startup.' % device - - if any(results): - bb_annotations.PrintWarning() - else: - print 'Reboots complete.' - - def RunTestSuites(options, suites): """Manages an invocation of test_runner.py for gtests. @@ -434,9 +398,6 @@ def ProvisionDevices(options): # Restart adb to work around bugs, sleep to wait for usb discovery. device_utils.DeviceUtils(None).old_interface.RestartAdbServer() RunCmd(['sleep', '1']) - - if not options.no_reboot: - RebootDevices() provision_cmd = ['build/android/provision_devices.py', '-t', options.target] if options.auto_reconnect: provision_cmd.append('--auto-reconnect') diff --git a/build/android/buildbot/bb_run_bot.py b/build/android/buildbot/bb_run_bot.py index 1ecf7f08a9..6644bf7942 100755 --- a/build/android/buildbot/bb_run_bot.py +++ b/build/android/buildbot/bb_run_bot.py @@ -118,8 +118,7 @@ def GetBotStepMap(): std_host_tests = ['check_webview_licenses', 'findbugs'] std_build_steps = ['compile', 'zip_build'] std_test_steps = ['extract_build'] - std_tests = ['ui', 'unit'] - fyi_tests = std_tests + ['mojo'] + std_tests = ['ui', 'unit', 'mojo'] telemetry_tests = ['telemetry_perf_unittests'] flakiness_server = ( '--flakiness-server=%s' % constants.UPSTREAM_FLAKINESS_SERVER) @@ -160,7 +159,7 @@ def GetBotStepMap(): H(compile_step + std_host_tests, target_arch='x86')), B('fyi-builder-rel', H(std_build_steps, experimental)), B('fyi-tests', H(std_test_steps), - T(fyi_tests, ['--experimental', flakiness_server, + T(std_tests, ['--experimental', flakiness_server, '--coverage-bucket', CHROMIUM_COVERAGE_BUCKET])), B('fyi-component-builder-tests-dbg', H(compile_step, extra_gyp='component=shared_library'), diff --git a/build/android/provision_devices.py b/build/android/provision_devices.py index 1faa4d22a8..83c02a2a60 100755 --- a/build/android/provision_devices.py +++ b/build/android/provision_devices.py @@ -95,8 +95,8 @@ def WipeDeviceData(device): After wiping data on a device that has been authorized, adb can still communicate with the device, but after reboot the device will need to be re-authorized because the adb keys file is stored in /data/misc/adb/. - Thus, before reboot the adb_keys file is rewritten so the device does not need - to be re-authorized. + Thus, adb_keys file is rewritten so the device does not need to be + re-authorized. Arguments: device: the device to wipe @@ -105,15 +105,17 @@ def WipeDeviceData(device): constants.ADB_KEYS_FILE) if device_authorized: adb_keys = device.old_interface.RunShellCommandWithSU( - 'cat %s' % constants.ADB_KEYS_FILE)[0] + 'cat %s' % constants.ADB_KEYS_FILE) device.old_interface.RunShellCommandWithSU('wipe data') if device_authorized: path_list = constants.ADB_KEYS_FILE.split('/') dir_path = '/'.join(path_list[:len(path_list)-1]) device.old_interface.RunShellCommandWithSU('mkdir -p %s' % dir_path) - adb_keys = device.old_interface.RunShellCommand( - 'echo %s > %s' % (adb_keys, constants.ADB_KEYS_FILE)) - device.old_interface.Reboot() + device.old_interface.RunShellCommand('echo %s > %s' % + (adb_keys[0], constants.ADB_KEYS_FILE)) + for adb_key in adb_keys[1:]: + device.old_interface.RunShellCommand( + 'echo %s >> %s' % (adb_key, constants.ADB_KEYS_FILE)) def ProvisionDevices(options): @@ -152,6 +154,8 @@ def main(argv): logging.basicConfig(level=logging.INFO) parser = optparse.OptionParser() + parser.add_option('-w', '--wipe', action='store_true', + help='Wipe device data from all attached devices.') parser.add_option('-d', '--device', help='The serial number of the device to be provisioned') parser.add_option('-t', '--target', default='Debug', help='The build target') @@ -165,7 +169,14 @@ def main(argv): print >> sys.stderr, 'Unused args %s' % args return 1 - ProvisionDevices(options) + if options.wipe: + devices = android_commands.GetAttachedDevices() + for device_serial in devices: + device = device_utils.DeviceUtils(device_serial) + WipeDeviceData(device) + device_utils.RebootDevices() + else: + ProvisionDevices(options) if __name__ == '__main__': diff --git a/build/android/pylib/device/device_utils.py b/build/android/pylib/device/device_utils.py index c8a5c3a481..93e364eb42 100644 --- a/build/android/pylib/device/device_utils.py +++ b/build/android/pylib/device/device_utils.py @@ -8,14 +8,49 @@ Provides a variety of device interactions based on adb. Eventually, this will be based on adb_wrapper. """ +import multiprocessing +import os +import sys import pylib.android_commands from pylib.device import adb_wrapper +CHROME_SRC_DIR = os.path.abspath( + os.path.join(os.path.dirname(__file__), '..', '..', '..', '..')) +sys.path.append(os.path.join( + CHROME_SRC_DIR, 'third_party', 'android_testrunner')) +import errors def GetAVDs(): return pylib.android_commands.GetAVDs() +# multiprocessing map_async requires a top-level function for pickle library. +def RebootDeviceSafe(device): + """Reboot a device, wait for it to start, and squelch timeout exceptions.""" + try: + DeviceUtils(device).old_interface.Reboot(True) + except errors.DeviceUnresponsiveError as e: + return e + + +def RebootDevices(): + """Reboot all attached and online devices.""" + devices = pylib.android_commands.GetAttachedDevices() + print 'Rebooting: %s' % devices + if devices: + pool = multiprocessing.Pool(len(devices)) + results = pool.map_async(RebootDeviceSafe, devices).get(99999) + + for device, result in zip(devices, results): + if result: + print '%s failed to startup.' % device + + if any(results): + print 'RebootDevices() Warning: %s' % results + else: + print 'Reboots complete.' + + class DeviceUtils(object): def __init__(self, device): diff --git a/build/common.gypi b/build/common.gypi index def3eaf76e..2154fadb36 100644 --- a/build/common.gypi +++ b/build/common.gypi @@ -558,6 +558,9 @@ # Enable the Syzygy optimization step. 'syzygy_optimize%': 0, + # Enable hole punching for the protected video. + 'video_hole%': 0, + 'conditions': [ # A flag for POSIX platforms ['OS=="win"', { @@ -676,6 +679,7 @@ # Set to 1 once we have a notification system for Android. # http://crbug.com/115320 'notifications%': 0, + 'video_hole%': 1, }], # Android OS includes support for proprietary codecs regardless of @@ -1078,6 +1082,7 @@ 'proprietary_codecs%': '<(proprietary_codecs)', 'use_goma%': '<(use_goma)', 'gomadir%': '<(gomadir)', + 'video_hole%': '<(video_hole)', # Use system protobuf instead of bundled one. 'use_system_protobuf%': 0, @@ -1361,9 +1366,6 @@ # Force disable libstdc++ debug mode. 'disable_glibcxx_debug%': 0, - # Set to 1 to compile with the hole punching for the protected video. - 'video_hole%': 0, - # Set to 1 to compile with MSE support for MPEG2 TS 'enable_mpeg2ts_stream_parser%': 0, @@ -2313,6 +2315,14 @@ ], }, }], + ['clang==1 and OS!="win"', { + # This is here so that all files get recompiled after a clang roll and + # when turning clang on or off. + # (defines are passed via the command line, and build systems rebuild + # things when their commandline changes). Nothing should ever read this + # define. + 'defines': ['CR_CLANG_REVISION=<!(<(DEPTH)/tools/clang/scripts/update.sh --print-revision)'], + }], ['enable_rlz==1', { 'defines': ['ENABLE_RLZ'], }], diff --git a/build/linux/system.gyp b/build/linux/system.gyp index dddf86a4eb..4a3fa3204f 100644 --- a/build/linux/system.gyp +++ b/build/linux/system.gyp @@ -22,9 +22,9 @@ 'linux_link_libbrlapi%': 0, }, 'conditions': [ - [ 'chromeos==0', { - # Hide GTK and related dependencies for Chrome OS, so they won't get - # added back to Chrome OS. Don't try to use GTK on Chrome OS. + [ 'chromeos==0 and use_ozone==0', { + # Hide GTK and related dependencies for Chrome OS and Ozone, so they won't get + # added back to Chrome OS and Ozone. Don't try to use GTK on Chrome OS and Ozone. 'targets': [ { 'target_name': 'gdk', diff --git a/build/util/LASTCHANGE b/build/util/LASTCHANGE index f21b849826..3c08367e0a 100644 --- a/build/util/LASTCHANGE +++ b/build/util/LASTCHANGE @@ -1 +1 @@ -LASTCHANGE=269336 +LASTCHANGE=269467 diff --git a/build/util/LASTCHANGE.blink b/build/util/LASTCHANGE.blink index b18a46f0ab..7f5d6bd091 100644 --- a/build/util/LASTCHANGE.blink +++ b/build/util/LASTCHANGE.blink @@ -1 +1 @@ -LASTCHANGE=173743 +LASTCHANGE=173750 |