How to setup Android Cordova/Phonegap Environment for eclipse on Ubuntu

In order to start setup we need to check the following requirements:

  • Required JDK 1.6 or above and Runtime environment.
  • Required Eclipse 3.7.2 (Indigo) or greater(3.8).
  • Required ADT Plug in, to add the ADT plugin to Eclipse:

Start Eclipse, then select Help > Install New Software.

Click Add, in the top-right corner.

In the Add Repository dialog that appears, enter "ADT plugin" for the Name and the following URL for the Location:

    https://dl-ssl.google.com/android/eclipse/

Note: The Android Developer Tools update site requires a secure connection. Make sure the update site URL you enter starts with HTTPS.

Click OK.

In the Available Software dialog, select the check box next to Developer Tools and click Next.

In the next window, you'll see a list of the tools to be downloaded. Click Next.

Read and accept the license agreements, then click Finish.

If you get a security warning saying that the authenticity or validity of the software can't be established, click OK.

When the installation completes, restart Eclipse.

Configure the ADT Plugin

Once Eclipse restarts, you must specify the location of your Android SDK directory:

In the "Welcome to Android Development" window that appears, select Use existing SDKs.

Browse and select the location of the Android SDK directory you recently downloaded and unpacked.

Click Next.

Your Eclipse IDE is now set up to develop Android apps, but you need to add the latest SDK platform tools and an Android platform to your environment. To get these packages for your SDK, continue to Adding Platforms and Packages.

Now click Android SDK Manager by going to window from menu

In packages section under Android 4.4.2(API 19)

Select SDK platform and system image.

Under Extras

Configure Phonegap plugin (optional)

Start Eclipse, then select Help > Install New Software.

Click Add, in the top-right corner.

In the Add Repository dialog that appears, enter "Phonegap plugin" for the Name and the following URL for the Location:

  http://svn.codespot.com/a/eclipselabs.org/mobile-web-development-with-phonegap/tags/r1.2/download

In the Available Software dialog, select the checkbox next to MDS AppLaud  and click Next.

In the next window, you'll see a list of the tools to be downloaded. Click Next.

Read and accept the license agreements, then click Finish.

Now your development environment is ready

Import your existing project by selecting File > Import

In the Import dialog that appears, select  Android > Existing Android Code Into Workspace and click Next

In the next dialog that appears, browse.. your project location and select the project click Finish.

Now compile and run your project on emulator

Right click on you project folder navigate to Run As > Android Application

If every thing goes fine you can export .apk file

Right click on you project folder navigate to Android Tools > Export Signed Application Package and follow the instructions.

0/5