I just got a brand new Ubuntu machine and I am trying to setup Android SDK. I am pretty new to Unix so pardon me if I did a silly mistake.
I followed the instructions given here, all the way up to adding the 'Rule' file. Now if I try adb devices
in the terminal, it gives me 'No command 'adb' found' error and asks if I made a spelling mistake.
@USER:~/android-sdk-linux/platform-tools$ ls
NOTICE.txt adb api fastboot source.properties systrace
@USER:~/android-sdk-linux/platform-tools$ adb devices
No command 'adb' found, did you mean:
Command 'cdb' from package 'tinycdb' (main)
Command 'gdb' from package 'gdb' (main)
Command 'dab' from package 'bsdgames' (universe)
Command 'zdb' from package 'zfs-fuse' (universe)
Command 'kdb' from package 'elektra-bin' (universe)
Command 'tdb' from package 'tads2-dev' (multiverse)
Command 'pdb' from package 'python' (main)
Command 'jdb' from package 'openjdk-6-jdk' (main)
Command 'jdb' from package 'openjdk-7-jdk' (universe)
Command 'ab' from package 'apache2-utils' (main)
Command 'ad' from package 'netatalk' (universe)
adb: command not found
I searched through a couple of questions on StackOverflow and some suggest I use apt-get install ia32-libs
command to get some 32-bit libraries. However, I am on a 64-bit machine so not sure whether I should go for that or not.
Another strange issue I noticed is, even if I navigate to the platform-tools
folder and execute adb devices
command, I get the same error. So, I might be missing something else here rather than incorrectly setting the PATH entry.
I tried both the ADB BUNDLE (.zip file) and SDK tools (.tgz file) from the download page and completed all the steps mentioned above but got same error.
I am on Ubuntu 12.04 LTS.
If the ADB command is not found, most likely you need to install the Android SDK Platform-Tools package to make it available in the command prompt. Also, the phone should be in USB debugging mode.
If you are getting adb.exe: no devices/emulators found error it means that the ADB daemon is unable to detect your device. It might be due to the following reasons. Your Android phone or tablet is not connected to the computer. You haven't turned on USB debugging from the Developer options on your device.
adb is in android-sdks/tools directory. You simply type this command: adb logcat .
You are in the right directory but the current directory is not in your shell's command search path.
Try
./adb
Also search Google for how to set $PATH variable in bash
Type the following into your terminal (from your help.ubuntu.com URL) - it will temporarily add the android tool directories into your PATH for that shell/terminal
export PATH=${PATH}:~/android-sdk-linux/tools
export PATH=${PATH}:~/android-sdk-linux/platform-tools
You should now be able to run adb (without being in the right dir and without using ./adb)
If you add those commands into your .bashrc and start a new terminal/shell you should find those changes are now permanent.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With