Ubuntu 12.04 - Install Android Tools (ADB, Fastboot, ...)Created on 22 Feb 2013, updated on 14 Aug 2013, by Nicolas Bernaerts // <![CDATA[ function toc_toggle_visible(ob) { var ul = ob.parentNode.parentNode.getElementsByTagName("ul")[0]; var d = ul.style.display == "none"; ul.style.display = d ? "" : "none"; ob.innerHTML = d ? "Hide" : "Show"; return false; } // ]]> Contents[Hide]Setup ADB Udev RuleInstall Android tools OnlyInstall Android SDKInstall Oracle Java 7Install ia32-libsInstall Android SDKAllow ADB trusted connexionInstall QtADBIf you own an Android Smartphone, you will need sooner or later to use some specific Android tools like adb or fastboot.If you need these tools, two options are now available under Ubuntu 12.04 :Install the whole Android SDK which bring these tools among may other thingsInstall some specific android-tools packages that bring only these toolsThis article will explain the simple steps needed to install Android tools, including latest Android SDK on a Ubuntu Precise 12.04 workstation.Both options have been tested to Root a Google Nexus S and to Root a Google Nexus 7.1. Setup ADB Udev RuleBefore accessing your android device in adb mode, you need to :set the device to use USB Debugdeclare a corresponding Udev rule on your Ubuntu boxAfter setting the device in USB Debug mode and connecting it to a USB port, throw the command :# lsusb...Bus 002 Device 059: ID 18d1:4e42 Google Inc.This is the result for a Google Nexus 7 connected in MTP mode with USB Debug on. It gives the Manufacturer and Model ID.Now that we have these data, we can create the udev rules in /etc/udev/rules.d/99-android.rules.# sudo gedit /etc/udev/rules.d/99-android.rules/etc/udev/rules.d/99-android.rules# Google Nexus 7 16 GbSUBSYSTEM=="usb", ATTR{idVendor}=="18d1", ATTR{idProduct}=="4e42", MODE="0666", OWNER="your-login" # MTP mode with USB debug onyour-login should be your Ubuntu session login.We can now restart udev for the new rules to become operationnal.# sudo service udev restart2. Install Android tools OnlyIf you don't plan to do some development on your android device, you don't need to install the complete SDK.One android-tools package is now available on Ubuntu quantal.Thanks to Web8upd site this package has been ported to Ubuntu precise and is available as a PPA.So, to install the tools, you just need to declare the PPA and install the package :# sudo add-apt-repository ppa:nilarimogard/webupd8# sudo apt-get update# sudo apt-get install android-tools-adb android-tools-fastbootThe tools are now available in command line.3. Install Android SDK3.1. Install Oracle Java 7To install the complete Android SDK, first step is to install latest Oracle Java 7 runtime environment.We also have to previously uninstall OpenJDK, as it is provided out of the box with Ubuntu Precise.Oracle Java is not available in the official Ubuntu repositories anymore because that's not allowed by the new Java license.We will get the help of WebUpd8 PPA to install it.The package in the PPA automatically downloads (and installs) Oracle Java JDK 7 from its official website and installs it on the computer (it works like the flashplugin-installer).# sudo apt-get purge openjdk*# sudo add-apt-repository ppa:webupd8team/java & sudo apt-get update# sudo apt-get install oracle-java7-installer3.2. Install ia32-libsAndroid SDK still needs the 32bits compatibility packages to run.So, if you are running an AMD64 distribution, you need to