Compiling a project to an Android release version .apk
file is the final step before distributing an application over the Android Market or some other channel. There are many methods of doing this depending upon what tool is being used. In this recipe, we will use the AIR Developer Tool (ADT) command line utility to compile and package our application.
To compile an .apk
from a mobile AIR project using the ADT command line tools, we will take the following steps:
1. For this example, we will assume the following:
Certificate: android.p12
Desired APK:
mobileAIR.apk
AIR Descriptor:
mobileAIR\src\mobileAIR-app.xml
SWF File:
mobileAIR\src\mobileAIR.swf
2. Open a command prompt or terminal (depending upon the operating system) and type in the command string to generate our certificate. In this case, we will set the target type to
.apk
for a release build. We could also set this to apk-debug for a debug build, or apk-emulator for...