Android_adb command not found

Source: Internet
Author: User

Build ubuntu11.10 Android Environment

1. Install Android SDK

Download the android SDK and select Linux (i386) (applicable to both 32-bit and 64-bit platforms)

Wget http://dl.google.com/android/android-sdk_r16-linux.tgz
Tar xvfz android-sdk_r16-linux.tgz

2. Add Environment Variables

Add the/opt/Android-SDK-Linux/tools directory and the/opt/Android-SDK-Linux/platform-tools directory to the PATH variable.

Gedit/etc/profile or VI ~ /. Bashrc or gedit ~ /. Bashrc

Export android_home =/opt/Android-SDK-Linux (replace with your SDK path)
Export Path = $ android_home/tools: $ android_home/platform-tools: $ path

$ Source ~ /. Bashrc

Execute the following command in the command line:
~ $ ADB kill-server (killing the ADB process)
$ Sudo ADB devices (restart ADB)

If the following error occurs: sudo: ADB: Command not found.
Solution:
~ $ Sudo-s # Switch to root through Sudo-S
~ $ Type ADB # Use Type ADB to check which command ADB uses
$ CD/usr/bin # enter the/usr/bin directory
~ $ Rm-rf adb (delete the original ADB)
~ $ Sudo ln-S/home/XXX/Android-SDK-Linux/platform-tools/ADB # sudo ln-s your ADB solution path
$ Type ADB # In this case, the command line displays ADB as/usr/bin/ADB

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.