Adobe AIR and Mobile Compiling

Aside from normal compiling, we can also compile to AIR (Adobe Integrated Runtime) and to mobile platforms like Android and iOS.

Let’s start off with compiling for AIR. AIR gives you the ability to create “Flash outside of the browser” applications or desktop applications. The cool thing about AIR is that if you create your application once, with AS3, you can use the same codebase to export to SWF, the desktop, Android, and iOS, with only some minor adjustments to the application descriptor file.

Note

If you want to start developing with AIR, you need the AIR SDK. The latest public release at the time of this writing is the AIR 2.7 SDK, which can be found at http://www.adobe.com/products/air/sdk/.

This SDK also includes the ADL (AIR Debug Launcher) and ADT (AIR Developer Tool) command-line tools. We will be using this SDK in our examples.

After you have downloaded the AIR SDK, it is time to overlay it with the Flex SDK we downloaded earlier. This is a relatively painless process if you know what to do. Be sure to make a backup of your Flex SDK folder before starting. Better safe than sorry!

Copy the downloaded SDK file to the location where you extracted the Flex SDK. I have a folder on the root of my machine called SDK where I place all my SDKs.

On Windows, just right-click the zip file (the AIR SDK) in the Flex SDK folder and select Extract All or use any decompression tool of your choice.

Mac OS X is a bit different. When you extract the SDK here, it’s ...

Get Automating ActionScript Projects with Eclipse and Ant now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.