Android app development is not difficult if you know how to code in Java. You can develop the apps using various frameworks out there or simply use android sdk tools with eclipse. Though frameworks online are restricted to the web apps, If you wish to develop app for the native system, you have to go with the android SDK instead of all those HTML5 and other respective frameworks out there.
In this tutorial we’ll see how to setup development environment on ubuntu linux. Instruction applies to almost every debian or say ubuntu child distros and if you follow the steps you will be up and running just fine.
Install Java Runtime Environment
In order to run eclipse or other android tools on ubuntu or your linux distro you need to have JRE installed. By default ubuntu 12.04 doesn’t contain any JRE in it. You have to download the package before running android sdk manager and eclipse.
apt-get install openjdk-7-jre-headless
This package will install java runtime on your system. Once this is installed you can go ahead and use eclipse or any other IDE with your android SDK tools.
I am assuming that you are going to use the eclipse on your ubuntu linux. You can use Sublimte Text or any other IDE along with android SDK tools. That will also work but with eclipse you get more options for the editing and managing the projects. Debugging and management of the app becomes easy with IDE like eclipse.
There are two ways to get eclipse on ubuntu linux. You can use software center to install eclipse. It will install slightly older but stable version of eclipse on your system. For example, the software center has eclipse 3.7.2 for ubuntu 12.04.
You can install eclipse classic latest version (4.2 at the time of writing this post) from the eclipse download page.
Android SDK Tools
You need to download android sdk from the official Android developer website. You need to download the SDK in zip or tar.gz archive and then just have to extract it.
Now go to the tools folder inside the “android-tools-sdk” extracted folder. You will find one bash script called “android”. Just open the terminal and go to this folder and type.
This will open android sdk tools manager. This window gives you option to download the SDK. You have the choice to download old SDK and new SDK for your development.
Just select the options which are required for you. Minimum required are already marked. You can also select the older SDK like say 2.3 which is used on most of the popular phones.
Extra SDK like billing, analytics and drivers do come in handy. So also check those extra SDK if you are going to use them in your app development.
Install Eclipse ADT Plugin
Open eclipse and click on help “install new software”. Add new source :
Click OK and let eclipse process the download. It takes sometime and after that it asks you to verify the software. It will ask you to verify and then it will restart the eclipse.
Once restart, eclipse will ask you to show the SDK path to work with.Once that is done you are all set to code.
Android Virtual Device
You did the code and now it is time for the demo. In such case you need to have virtual device as an emulator. You can add the virtual device settings like 20MB SD, LCD screen, MIPS system image etc. I have used these settings and ran the demo code.
That’s it. We have setup the android development environment on our ubuntu linux. In next tutorial we will take a look at how to create new android app.