Android SDK and Eclipse ADT on Fedora 16/15, CentOS/RHEL 6

Eclipse Android LogoThis is guide howto install Android SDK Tools r16 and Eclipse ADT (Android Development Tools) Plugin on Fedora 16, Fedora 15, Fedora 14, Fedora 13, CentOS 6.2/6.1/6 and Red Hat (RHEL) 6.2/6.1/6.

This Guide Contents

1. Preparing Your Development Computer and Install Required softwares

1.1 Install Sun/Oracle Java 7 JDK/JRE

1.2 Install Eclipse SDK 3.7 (Indigo)

2. Install Andoid SDK

2.1 Change root user

2.2 Download and Install Android SDK

Note: Latest SDK r16 (Android 2.3 Gingerbread and 3.x Honeycomb) emulator is currently working only with Glibc 2.7 or greater, so that’s why CentOS 5.7 and Red Hat (RHEL) 5.7 needs a newer version of Glibc to run Android SDK tools. This is possible to get working with manually build GNU C Library (glibc) 2.7 or later on CentOS 5.7 or Red Hat (RHEL) 5.7, but this might cause much problems and that’s why here is not now guidance for that.

Errors on CentOS 5.7 and Red Hat (RHEL) 5.7 looks following:

2.2 Extract Android SDK

2.3 Move Android SDK to right location

2.3 Add Write Permissions to /opt/android-sdk

2.4 Add Android SDK into PATH environment variable

Add following lines to /etc/profile or $HOME/.bash_profile

2.5 64-bit Systems needs following 32-bit system packages

3. Install ADT Plugin for Eclipse

3.1 Open Install New Software window (Help -> Install New Software…)

Eclipse SDK 3.6 Install New Software

3.2 Add ADT Plugin repository

Name: ADT
Location: https://dl-ssl.google.com/android/eclipse/

3.3 Select Android DDMS and Android Development Tools

Install Android Development Tools ADT on Eclipse

Note If you get something like following error:

The operation cannot be completed. See the details.
Cannot complete the install because one or more required items could not be found.
Software being installed: Android Development Tools 0.9.7.v201005071157-36220 (com.android.ide.eclipse.adt.feature.group 0.9.7.v201005071157-36220)
Missing requirement: Android Development Tools 0.9.7.v201005071157-36220 (com.android.ide.eclipse.adt.feature.group 0.9.7.v201005071157-36220) requires ‘org.eclipse.gef 0.0.0′ but it could not be found

Then simply add Eclipse Indigo repository:

Name: Indigo
Location: http://download.eclipse.org/releases/indigo

And try Install Android Development Tools again.

3.3 Accept ADT Licenses

Eclipse Accept Android Licenses

3.4 Install ADT and restart Eclipse

Eclipse SDK Installing Android Development Tools

4. Configure Eclipse and Manage Android SDKs and Virtual Devices (AVD)

4.1 Add Android SDK path to Eclipse settings

Open menu Window -> Preferences
Eclipse Preferences Android SDK Location

4.2 Start Android SDK and AVD Manager from Menu

Start Android SDK and AVD Manager

4.3 Install All Needed SDKs

Android SDK and AVD Manager Install SDKs

Android SDK and AVD Manager Choose Packages to Install

Installing Android SDKs

4.4 Add needed AVDs Android Virtual Devices

Select Virtual Device -> New…
Create new Android Virtual Device AVD

4.5 Test Android Virtual Device

Select Device and click Start…
Start AVD

Starting device (this may take long time)
Android Test Device

Basic device started
Started Android Test Device

5. Create Simple Android Test Project

5.1 Create New Android Application

Click File -> New -> Project…
Select Android Project

Add project information

Eclipse Create New Android Project

5.2 Add source code for testing Android

Add and save following source code

5.3 Run Android application

Click Run -> Run as -> Android Application

Test Android Application running

Simple Android Test Application

Share this post

101 Comments

  1. if they could make a tutorial to install android SDK and NetBeans 7.2 centos 6

    Reply
  2. in 2.4 How can do it I’m new in this

    Reply
    • Hi raed,

      Open /etc/profile or $HOME/.bash_profile file using text editor, example VI or nano. Then just paste needed rows and save file.

      Reply
  3. Hey,

    FIRST THANK YOU FOR YOUR GREAT WORK HERE!!!!

    Now, my problem:

    During some days of working with fedora 17 (last updates) and eclipse + adt and jdk7
    i have a freeze problem.

    I v tried some things like start as root user set the jvm memory
    from 512 to 1024 via start propertys of eclipse and so on.
    Now i
    ve seen that the CPU usage of the java process goes very nearly to 100%.
    Eclipse freeze and I have to restart eclipse. The OS and GNOME works.

    Has someone the same problems? Or some Ideas what to do?

    PS: dmesg and other logs show no error or warnings.

    Thanks Thorty!

    Hardware:
    Intel Core 2 Extreme QX9300 (2,53 GHz)
    4GB RAM
    Geforce 9700M GT, 512 MB
    (NVIDIA Driver installed)

    Reply
    • I have a solution! Im so happy and its soooooo easy! After some coding and google Ive found out that it has something to do with the Clipboard Function (Ctrl+C). You just have to navigate to Preferences - Keys. Search for the Shortcut Strg+Insert and Change this into Strg+C.
      I
      dont reallyBut now, Eclipse works very well.

      Thanks, Thorty

      Reply

Trackbacks/Pingbacks

  1. android SDK r08 on CentOS 5.5 « Friendrons Blog - [...] http://www.if-not-true-then-false.com/2010/android-sdk-and-eclipse-adt-on-fedora-centos-red-hat-rhel... [...]

Submit a Comment

Your email address will not be published. Required fields are marked *

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code class="" title="" data-url=""> <del datetime=""> <em> <i> <q cite=""> <strike> <strong> <pre class="" title="" data-url=""> <span class="" title="" data-url="">