Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(3025)

Unified Diff: build/android/install_emulator_deps.py

Issue 23513022: android: Point EMULATOR_SDK_ROOT to a location inside the repository. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Same patch, rebased on top of r223028 Created 7 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « build/android/avd.py ('k') | build/android/pylib/constants.py » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: build/android/install_emulator_deps.py
diff --git a/build/android/install_emulator_deps.py b/build/android/install_emulator_deps.py
index 0f40e9dad553b2f329a44dbd64a51809930fd1c0..f4677e658acc449ceaed7cbe201b7df1d302967a 100755
--- a/build/android/install_emulator_deps.py
+++ b/build/android/install_emulator_deps.py
@@ -34,10 +34,9 @@ def CheckSDK():
"""Check if SDK is already installed.
Returns:
- True if android_tools directory exists in current directory.
+ True if the third_party/android_tools/sdk directory exists.
"""
- return os.path.exists(os.path.join(constants.EMULATOR_SDK_ROOT,
- 'android_tools'))
+ return os.path.exists(constants.ANDROID_SDK_ROOT)
def CheckARMv7Image():
@@ -47,20 +46,21 @@ def CheckARMv7Image():
True if the armeabi-v7a directory is present inside the Android SDK
checkout directory.
"""
- return os.path.exists(os.path.join(constants.EMULATOR_SDK_ROOT,
- 'android_tools', 'sdk', 'system-images',
- API_TARGET, 'armeabi-v7a'))
+ return os.path.exists(os.path.join(constants.ANDROID_SDK_ROOT,
+ 'system-images',
+ API_TARGET,
+ 'armeabi-v7a'))
def CheckX86Image():
"""Check if Android system images have been installed.
Returns:
- True if android_tools/sdk/system-images directory exists.
+ True if the X86 system images exist in
+ android_tools/sdk/system-images/<API TARGET>/x86.
"""
- return os.path.exists(os.path.join(constants.EMULATOR_SDK_ROOT,
- 'android_tools', 'sdk', 'system-images',
- API_TARGET, 'x86'))
+ return os.path.exists(os.path.join(constants.ANDROID_SDK_ROOT,
+ 'system-images', API_TARGET, 'x86'))
def CheckKVM():
@@ -104,8 +104,8 @@ def GetARMv7Image():
rc = cmd_helper.RunCmd(['unzip', '-o', '/tmp/armv7_img.zip', '-d', '/tmp/'])
if rc:
raise Exception('ERROR: Could not download/unzip image zip.')
- sys_imgs = os.path.join(constants.EMULATOR_SDK_ROOT, 'android_tools', 'sdk',
- 'system-images', API_TARGET, 'armeabi-v7a')
+ sys_imgs = os.path.join(constants.ANDROID_SDK_ROOT, 'system-images',
+ API_TARGET, 'armeabi-v7a')
shutil.move('/tmp/armeabi-v7a', sys_imgs)
finally:
os.unlink('/tmp/armv7_img.zip')
@@ -119,8 +119,8 @@ def GetX86Image():
rc = cmd_helper.RunCmd(['unzip', '-o', '/tmp/x86_img.zip', '-d', '/tmp/'])
if rc:
raise Exception('ERROR: Could not download/unzip image zip.')
- sys_imgs = os.path.join(constants.EMULATOR_SDK_ROOT, 'android_tools', 'sdk',
- 'system-images', API_TARGET, 'x86')
+ sys_imgs = os.path.join(constants.ANDROID_SDK_ROOT, 'system-images',
+ API_TARGET, 'x86')
shutil.move('/tmp/x86', sys_imgs)
finally:
os.unlink('/tmp/x86_img.zip')
« no previous file with comments | « build/android/avd.py ('k') | build/android/pylib/constants.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698