Linux.com

Android Development

Link to this post 11 Dec 10

I finally got some time to set up one of my machines for the Android development environment, and I'm a bit confused. When I started reading up a few weeks ago, I was under the impression that I could use OpenJDK as the Java component, but, when I got to the installation requirements I see this:

Supported Development Environments
Eclipse IDE

Eclipse 3.4 (Ganymede) or greater
Eclipse JDT plugin (included in most Eclipse IDE packages)
If you need to install or update Eclipse, you can download it from http://www.eclipse.org/downloads/.
Several types of Eclipse packages are available for each platform. For developing Android applications, we recommend that you install one of these packages:
Eclipse IDE for Java Developers
Eclipse Classic (versions 3.5.1 and higher)
Eclipse IDE for Java EE Developers
JDK 5 or JDK 6 (JRE alone is not sufficient)
Android Development Tools plugin (recommended)
Not compatible with Gnu Compiler for Java (gcj)

The last 3 lines seem to me to say that one needs Oracle/Sun Java JDK. Can anyone confirm this for me? I was hoping to stay Open Source.

Link to this post 12 Dec 10

Thanks Matt going to try that as soon as I get home.

Link to this post 13 Dec 10

I also suggest this one (http://developer.android.com/guide/developing/eclipse-adt.html)

When I usually develop something with a tool I search something from the web as an alternative to manufacturer/producer source documentation; believe me or not Google did an impressive job with their docs, you can find a lot of different sources but official documentation is really clear and verbose, take a look at it.

To answer your question here's what I'm using in my Ubuntu laptop:

ben@andrea:/$ aptitude search jdk
p default-jdk - Standard Java or Java compatible Developme
v default-jdk-builddep -
p default-jdk-doc - Standard Java or Java compatible Developme
p gcj-4.4-jdk - gcj and classpath development tools for Ja
p gcj-4.5-jdk - gcj and classpath development tools for Ja
p gcj-jdk - gcj and classpath development tools for Ja
p openjdk-6-dbg - Java runtime based on OpenJDK (debugging s
p openjdk-6-demo - Java runtime based on OpenJDK (demos and e
p openjdk-6-doc - OpenJDK Development Kit (JDK) documentatio
p openjdk-6-jdk - OpenJDK Development Kit (JDK)
i A openjdk-6-jre - OpenJDK Java runtime, using Hotspot JIT
i A openjdk-6-jre-headless - OpenJDK Java runtime, using Hotspot JIT (h
i A openjdk-6-jre-lib - OpenJDK Java runtime (architecture indepen
v openjdk-6-jre-shark -
p openjdk-6-jre-zero - Alternative JVM for OpenJDK, using Zero/Sh
p openjdk-6-source - OpenJDK Development Kit (JDK) source files

As you can see I'm using openjdk, I've installed it directly from repository but I've manually downloaded Eclipse from eclipse.org site, no Ubuntu/Debian repository involved with it. I'm using Eclipse for 5/6 years and I've always avoided to install it from any distribution repository, that's because I'd like to update it manually from eclipse site and have more features/modules available.
Let me know about your tests if you need help with it

Cheers
Ben

Link to this post 21 Dec 10

BTW - Since I'm still new to android-sdk, I don't know if this is news or not, but, from reading a few how-to's, it seems like the directions have changed. Android-sdk no longer downloads with adb, one must cd into the android-sdk-linux_86 folder in terminal and execute "tools/android update sdk" in order to download adb and other parts of the android-sdk.

So, from step three of the original link I gave:

3.) Change Directory into the "platform-tools" directory, then copy the "adb" application to your Ubuntu /usr/bin directory (sudo privs needed)
#From the extracted "android-sdk-linux_86" directory:
cd platform-tools
sudo cp adb /usr/bin/adb

it must be changed to:

3.) Change Directory into the "platform-tools" directory, then copy the "adb" application to your Ubuntu /usr/bin directory (sudo privs needed)
#From the extracted "android-sdk-linux_86" directory:
tools/android update sdk
cd platform-tools
sudo cp adb /usr/bin/adb

Link to this post 12 Jan 11

@Goineasy9
Are you able to compile your first hello world program now ?

Who we are ?

The Linux Foundation is a non-profit consortium dedicated to the growth of Linux.

More About the foundation...

Frequent Questions

Join / Linux Training / Board