How To Install Android Platform Tools
Virtually of the states volition never need to install the Android SDK. The reason why is correct in the name — Software Development Kit. It's built for people writing Android apps who need tools to piece of work with Android from a reckoner.
But those tools can also be handy for folks wanting to do some more advanced stuff. Stuff like manually updating software or rooting their telephone. Fastboot and ADB are vital if you're into "hacking" at the Android software. And Google provides it free for anybody.
What to cull?
There are ii means to get a working set of Android tools on your figurer. The piece of cake mode is just to install Android Studio. Everything needed to run and use the Android command line tools is office of Android Studio, likewise as a manner to keep the tools updated. While it'due south designed for folks who want a complete development environment and includes a code editor, Android emulator, and compiler, you tin can use just the command line tools and never open the remainder.
If you're not afraid to become your feet wet, you can install simply the SDK components outside of Android Studio. Installing them is piece of cake (they're within a zip file), but setting up your computer to use them isn't a straightforward process.
Manually installing the Android SDK
Download the SDK direct from Google by clicking hither. Roll down a bit and find the section marked "Go but the control line tools" and save information technology somewhere easy to get to, like your desktop. We'll exist extracting it to a improve location in the side by side step.
The file you downloaded is compressed. Y'all'll need to be familiar with compressed files — and how to extract them — to go any further. If you're not, stop here and spend the time to larn near them.
Excerpt your compressed file into the following location:
- Windows: The root of your C: drive
- Os 10: Your abode binder
- Linux: Your abode binder
Rename the extracted folder to "Android". This volition make the rest of this guide, and your fourth dimension with the SDK, much easier.
Prerequisites
You'll demand a working version of Java to run the SDK components. For most things, you'll be doing with the SDK, both Open up Java and Sun Java from Oracle (yes, that Oracle) volition work.
- On a Mac, it'southward pretty piece of cake because yous'll already have it installed unless you uninstalled it. If you did, install information technology again — yous should know how to practice that if you knew how to uninstall it.
- On Windows, head to the Oracle website and download the correct version (32- or 64-chip) for your computer. Again, if this gives yous any problem, stop what y'all're doing and learn a bit more about your computer. If you lot can't install Java, maybe yous're not however prepare to utilise the Android SDK.
- On a Linux reckoner, you'll also demand to install Java. You can observe x86 and x64 binaries for Sun Coffee from Oracle at their website. OpenJDK also works for almost things you'll need to practise with the SDK. (OpenJDK is now bundled with Android Studio which includes the SDK besides equally a development environment) and you lot'll find complete instructions to go it installed at the OpenJDK website. If you need more assistance or desire to utilize a packet managing director to install Sun Java, yous'll need to refer to the documentation for your particular distro.
Linux users will also have to make sure they have some 32-bit libraries installed if they are running a 64-bit version of the operating system. If you're using Ubuntu or another Debian variant, install ncurses5 and stdc++6 through your terminal:
sudo apt-go install lib32ncurses5 lib32stdc++half dozen If you're using a different flavor of Linux, observe the correct packages for ncurses5 and stdc++6 and install them.
Extract the file you lot downloaded above into a folder named Android on the root of your C drive (Windows) or into your Home folder (Mac, Linux). You might notice a few things are missing if yous've ever downloaded the command line tools earlier as the tools and platform-tools folders are missing. That'south OK; nosotros're about to get them using the included SDK manager.
Open the bin folder in the extracted download and find the SDK managing director executable file. Information technology may expect like a final or trounce command, only information technology volition open up a GUI as long as you lot accept Coffee installed correctly.
In the SDK manager, you'll choose to install Android SDK Tools and Android SDK Platform-Tools. If you're using Windows, you'll as well desire to install the Google USB Driver, and if you plan on edifice AOSP from the source, y'all may want to install the Android SDK Build-Tools.
Cull the correct files and proceed through the procedure (information technology will show you a license agreement you should read), and both tools folders will be installed. But you're not quite finished!
The tools will be installed into the application data folder. On Windows, it'south in Windows\users\YourUserName\AppData\Local\Android, and on a Mac or Linux, it's in .Android (discover the dot!) in your home folder. Create a symbolic link (information for Windows users hither) for both tools folders in the Android folder you created before. This volition help become them into your PATH and make life a lot easier.
Setting your PATH
The PATH variable in your computer's operating system tells it where to look when yous want to run a command from a terminal or the command line. For example, to run the ADB control, you either demand to type and provide the complete path — ie, the binder ADB is really in, inside the SDK folder — or take the location set in the PATH variable itself. It's a bit disruptive, only the practiced news is that doing it is easier than explaining it.
For these directions to work equally written, you will accept to have extracted and renamed the SDK download folder equally mentioned higher up, and to the correct location for this tutorial.
On Windows
Unless you're still using an older version of Windows, y'all no longer tin set the PATH in the autoexec.bat file or autoexec.nt file. You'll demand to update the system Surroundings Variable settings instead. Here's how information technology's done on a Windows ten automobile:
- Hit the Start cardinal on your Keyboard.
- Outset typing the words Environment Variables.
- Every bit yous blazon, you'll run into the choice to Edit the system environment variables. Cull it.
- In the Environment Variables window, select the PATH line item in the User variables for (your user proper noun) department, then click the Edit button.
Add the total path to the Android SDK tools and Android SDK platform-tools folders in the edit box, separated by a semi-colon. It should await something like this:
C:\Android\tools;C:\Android\platform-tools For older versions of Windows, refer to the documentation that came with your computer for assistance on setting the PATH. And, over again: If y'all've installed your SDK somewhere other than \Android, you'll need to adjust appropriately.
On a Mac
You tin set your PATH variable on a machine running Bone X in your bash profile. Doing so is easy, and is all washed in one file.
In your Home folder is a file named .bash_profile. Open information technology with whatever text editor. Never touch the .bashrc or .bash_profile files you might observe in the /etc. directory!
You lot may meet a bare file, or it may be full of other information. All nosotros need to do is add a couple of lines to the elevation of the file:
export PATH="$HOME/Android/tools:$PATH" export PATH="$Abode/Android/platform-tools:$PATH" (Did nosotros mention that if your SDK is in another location, you'll need to adjust things accordingly? Practiced.)
Save the file and reboot your computer and then that the new PATH is sourced properly.
On Linux
Setting the PATH on a Linux computer is virtually the same every bit on a Mac, you but edit a different file.
Using your favorite text editor, open up the ~/.bashrc file. It volition probably exist and take multiple entries. If yous get an error that the file does not exist, merely create a new file and save information technology as ~/.bashrc when finished.
You'll desire to add the following two lines to the END of the .bashrc file:
consign PATH="$Abode/Android/tools:$PATH" export PATH="$Dwelling house/Android/platform-tools:$PATH" Save the file and close the terminal window. Open a new instance of the concluding and type this command:
source ~/.bashrc Your session will reference the changes you made, and the SDK volition be in your PATH.
Wrapping information technology up
Yous should now have a working set of Android command-line tools and exist able to do things like wink the latest factory images or manually update your phone with a zip file. And considering you lot did information technology yourself, you take what you need to set up it when things become wrong.
Adept luck, and have fun!
Have you listened to this week's Android Central Podcast?
Every week, the Android Central Podcast brings yous the latest tech news, analysis and hot takes, with familiar co-hosts and special guests.
- Subscribe in Pocket Casts: Audio
- Subscribe in Spotify: Audio
- Subscribe in iTunes: Audio
Jerry is an amateur woodworker and struggling shade tree mechanic. There's cipher he tin't take apart, but many things he can't reassemble. Yous'll detect him writing and speaking his loud opinion on Android Key and occasionally on Twitter.
Source: https://www.androidcentral.com/installing-android-sdk-windows-mac-and-linux-tutorial
Posted by: benderhiplace.blogspot.com

0 Response to "How To Install Android Platform Tools"
Post a Comment