Sai Geetha started off as a Java Developer and moved on to work as a Solution Architect and an Enterprise Architect. However, as a hobby she continues to don the hats of a Java Developer as well as an Android Developer. She loves to share what she learns with the larger community. In her interest to share her knowledge, she blogs Android tutorials at and her other technical musings at Sai Geetha is a DZone MVB and is not an employee of DZone and has posted 18 posts at DZone. You can read more from them at their website. View Full User Profile

Basic steps for upgrading Android source code from SDK 1.5 to 2.1 using Eclipse IDE

  • submit to reddit
This is a step by step guide to upgrade one’s source code that was developed for an earlier version of android SDK, as is to work on a new version of SDK installed on your development environment

1. You are using Eclipse IDE - Ganymede
2. You have installed SDK 2.1 on your machine
3. You have upgraded ADT to 0.96 on Eclipse IDE
4. You have pointed the Eclipse IDE to the new SDK 2.1
5. You have changed the default JDK compiler version on Eclipse to 1.6
6. You have created an Android Virtual Device (AVD) that uses the SDK 2.1 / Google API

NOTE: Upgrading SDK and Eclipse installations itself is provided in detail at &

For each project that you have in your eclipse workspace that was written for the earlier version of SDK, you need to do the following for basic upgrade (this does not include the upgrade of APIs that have be deprecated):

Step-by-step guide
1. Right click the project and go to Project Properties -> Android
2. You wil see tha right pane showing the ‘Project Build Target’
3. In this pane you will see either or both: ‘Android 2.1’ & ‘Google APIs’ depending on what you chose to install when upgrading your ADT to 0.96
4. Select Google ‘Android 2.1’ or ‘Google API” whichever is required by your earlier project (note you might have used only Android 1.5 for most projects. You would need Google API only for those projects that use google maps)
5. Then, go to the ‘Project’ menu and click on ‘clean’. Note, this is an optional step. You may have to do this if you get the error ‘Conversion to Dalvik format failed with error 1’.
6. Then, build the project by going to ‘Project’ -> ‘build’
7. You are done. You can now run the earlier Android application using the new SDK 2.1
Published at DZone with permission of Sai Geetha M N, author and DZone MVB. (source)

(Note: Opinions expressed in this article and its replies are the opinions of their respective authors and not those of DZone, Inc.)


Gagan Peter replied on Sat, 2012/04/14 - 4:50am

the blog helped me update from 2.0.1 to 2.1...
thank you...

Comment viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.