Thankfully, the Android Development Tools will take care of this for us, and when you run your application from Eclipse, the Android plug in will automatically take care of signing the app with a debug certificate.
However, if you have been developing Android apps for more than a year, you may have run into the following problem.
Error generating final archive: Debug Certificate expired on...
This may seem like a complicated error message at first, especially if you were unaware that you had been signing all of your Android apps with a debug certificate in the first place.
|Example of the debug certificate expired error in Eclipse|
But have no fear! It is a simple problem to fix. Eclipse may not know how to handle an expired certificate, but it knows how to handle a missing debug certificate.
Go to Window->Preferences->Android->Build to find the location of the current Android Debug Certificate. Find this location and delete the file.
|The Android Build options menu|
Now go the project menu, and select clean. Clean all of your projects, and then they should build without any problems.
Now your projects should build without any problems. The debug certificate is generally good for a year, so you shouldn't run into this problem too often.
For more information about app signing, you can see the official android documentation http://developer.android.com/guide/publishing/app-signing.html#setup