Changes

Jump to: navigation, search
no edit summary
Up until this point in the book we have been building application projects in a mode suitable for testing and debugging. Building an application package for release to customers via the Google Play store, on the other hand, requires that some additional steps be taken. The first requirement is that the application be compiled in release mode instead of debug mode. Secondly, the application must be signed with a private key that uniquely identifies you as the application’s developer. Finally, the application package must be aligned. This is simply a process by which some data files in the application package are formatted with a certain byte alignment to improve performance.
Whilst each of these tasks can be performed outside of the Eclipse ADT environment, the tasks can more easily be performed using the Export Wizard as outlined in the remainder of this chapter. Note that Eclipse assumes that the JDK tools are in the PATH environment of your system as outlined in Setting up an Android Development Environment.
== Accessing the Export Wizard ==
* The number of years for which the key is to be valid (Google recommends a duration in excess of 27 years).
In addition, information must be provided for at least one of the remaining fields into at least one of the remaining fields (for example your first and last name or organization name).
== Creating the Application APK File ==
The next task to be performed is to instruct Eclipse to build the application APK package file in release mode and then sign it with the newly created private key. At this point the Destination and key/certificate checks screen should be displayed. Using the Browse…button, navigate to a suitable folder into which the application APK file should be created. Once a path and file name have been specified, click on Finish to generate the APK and sign it with your private key.
During this process, output similar to that outlined below will appear within the Console panel:
On completion of the generation process, the keystore file and APK file will have been generated into the designated locations of the file system. At this point the application is ready to be submitted to the Google Play store.
 The private key generated as part of this process should be used when signing and releasing future application and, as such, should be kept in a safe place and securely backed up.
The final step in the process of bringing an Android application to market involves submitting it to the Google Play Developer Console. Once submitted, the application will be available for download from the Google Play App Store.
* '''Title''' – The title of the application.
* '''Description''' – Up to 4000 words describing the application.
* '''Screenshots''' – Up to 8 screenshots of your application running (a minimum of two is required). Google recommends submitted screenshots of the application running on a 7” or 10” tablet.
* '''Language''' – The language of the application (the default is US English).

Navigation menu